oomph::TElementShape< 1, 2 > Class Reference

#include <Telements.h>

Public Member Functions

void local_coordinate_of_node (const unsigned &j, Vector< double > &s) const
 Return local coordinates of node j. More...
 
void shape (const Vector< double > &s, Shape &psi) const
 Shape function for specific TElement<1,2> More...
 
void dshape_local (const Vector< double > &s, Shape &psi, DShape &dpsids) const
 Derivatives of shape functions for specific TElement<2,2> More...
 
void d2shape_local (const Vector< double > &s, Shape &psi, DShape &dpsids, DShape &d2psids) const
 

Detailed Description

////////////////////////////////////////////////////////////////////// TElementShape inline functions: //////////////////////////////////////////////////////////////////////

Member Function Documentation

◆ d2shape_local()

void oomph::TElementShape< 1, 2 >::d2shape_local ( const Vector< double > &  s,
Shape psi,
DShape dpsids,
DShape d2psids 
) const
inline

Second derivatives of shape functions for specific TElement<1,2>: d2psids(i,0) = \( \partial^2 \psi_j / \partial s_0^2 \)

299  {
300  this->dshape_local(s, psi, dpsids);
301 
302  d2psids(0, 0) = 0.0;
303  d2psids(1, 0) = 0.0;
304  }
void dshape_local(const Vector< double > &s, Shape &psi, DShape &dpsids) const
Derivatives of shape functions for specific TElement<2,2>
Definition: Telements.h:281

References s.

◆ dshape_local()

void oomph::TElementShape< 1, 2 >::dshape_local ( const Vector< double > &  s,
Shape psi,
DShape dpsids 
) const
inline

Derivatives of shape functions for specific TElement<2,2>

282  {
283  this->shape(s, psi);
284 
285  // Derivatives
286  dpsids(0, 0) = -1.0;
287  dpsids(1, 0) = 1.0;
288  }
void shape(const Vector< double > &s, Shape &psi) const
Shape function for specific TElement<1,2>
Definition: Telements.h:271

References oomph::OneDimLagrange::shape().

◆ local_coordinate_of_node()

void oomph::TElementShape< 1, 2 >::local_coordinate_of_node ( const unsigned j,
Vector< double > &  s 
) const
inline

Return local coordinates of node j.

243  {
244  s.resize(1);
245  switch (j)
246  {
247  case 0:
248  s[0] = 0.0;
249  break;
250 
251  case 1:
252  s[0] = 1.0;
253  break;
254 
255  default:
256  std::ostringstream error_message;
257  error_message
258  << "Element only has two nodes; called with node number " << j
259  << std::endl;
260 
261  throw OomphLibError(error_message.str(),
264  }
265  }
RealScalar s
Definition: level1_cplx_impl.h:130
#define OOMPH_EXCEPTION_LOCATION
Definition: oomph_definitions.h:61
#define OOMPH_CURRENT_FUNCTION
Definition: oomph_definitions.h:86
std::ptrdiff_t j
Definition: tut_arithmetic_redux_minmax.cpp:2

References j, OOMPH_CURRENT_FUNCTION, OOMPH_EXCEPTION_LOCATION, and s.

◆ shape()

void oomph::TElementShape< 1, 2 >::shape ( const Vector< double > &  s,
Shape psi 
) const
inline

Shape function for specific TElement<1,2>

272  {
273  psi[0] = 1.0 - s[0];
274  psi[1] = s[0];
275  }

References s.


The documentation for this class was generated from the following file: