30 #ifndef OOMPH_TAXISYM_POROELASTICITY_ELEMENTS_HEADER 31 #define OOMPH_TAXISYM_POROELASTICITY_ELEMENTS_HEADER 35 #include <oomph-lib-config.h> 39 #include "../generic/Telements.h" 52 template<
unsigned ORDER>
93 return Initial_Nvalue[n];
116 unsigned node_number=Q_edge_conv[edge];
123 s[0]=flux_interpolation_point[0];
126 s[0]=1.0-flux_interpolation_point[0];
129 s[0]=flux_interpolation_point[0];
137 return Face_index_of_edge_flux[j];
144 #ifdef RANGE_CHECKING 147 std::ostringstream error_message;
148 error_message <<
"Range Error: j " << j
149 <<
" is not in the range (0,1)";
151 OOMPH_CURRENT_FUNCTION,
152 OOMPH_EXCEPTION_LOCATION);
162 #ifdef RANGE_CHECKING 165 std::ostringstream error_message;
166 error_message <<
"Range Error: j " << j
167 <<
" is not in the range (0," 170 OOMPH_CURRENT_FUNCTION,
171 OOMPH_EXCEPTION_LOCATION);
180 #ifdef RANGE_CHECKING 183 std::ostringstream error_message;
184 error_message <<
"Range Error: j " << j
185 <<
" is not in the range (0," 188 OOMPH_CURRENT_FUNCTION,
189 OOMPH_EXCEPTION_LOCATION);
223 #ifdef RANGE_CHECKING 226 std::ostringstream error_message;
227 error_message <<
"Range Error: j " << j
228 <<
" is not in the range (0," 231 OOMPH_CURRENT_FUNCTION,
232 OOMPH_EXCEPTION_LOCATION);
235 return j%(ORDER+1)+2;
241 #ifdef RANGE_CHECKING 244 std::ostringstream error_message;
245 error_message <<
"Range Error: j " << j
246 <<
" is not in the range (0," 249 OOMPH_CURRENT_FUNCTION,
250 OOMPH_EXCEPTION_LOCATION);
253 return Q_edge_conv[j/(ORDER+1)];
260 return node_pt(Q_edge_conv[edge]);
266 #ifdef RANGE_CHECKING 269 std::ostringstream error_message;
270 error_message <<
"Range Error: j " << j
271 <<
" is not in the range (0," 274 OOMPH_CURRENT_FUNCTION,
275 OOMPH_EXCEPTION_LOCATION);
283 double q_edge(
const unsigned &
t,
const unsigned &j)
const 285 #ifdef RANGE_CHECKING 288 std::ostringstream error_message;
289 error_message <<
"Range Error: j " << j
290 <<
" is not in the range (0," 293 OOMPH_CURRENT_FUNCTION,
294 OOMPH_EXCEPTION_LOCATION);
303 #ifdef RANGE_CHECKING 306 std::ostringstream error_message;
307 error_message <<
"Range Error: j " << j
308 <<
" is not in the range (0," 311 OOMPH_CURRENT_FUNCTION,
312 OOMPH_EXCEPTION_LOCATION);
322 #ifdef RANGE_CHECKING 325 std::ostringstream error_message;
326 error_message <<
"Range Error: j " << j
327 <<
" is not in the range (0," 330 OOMPH_CURRENT_FUNCTION,
331 OOMPH_EXCEPTION_LOCATION);
352 void set_q_edge(
const unsigned &
t,
const unsigned &j,
const double& value)
379 Shape &q_basis)
const;
383 Shape &div_q_basis_ds)
const;
392 const unsigned &j)
const 394 #ifdef RANGE_CHECKING 397 std::ostringstream error_message;
398 error_message <<
"Range Error: edge " << edge
399 <<
" is not in the range (0,2)";
401 OOMPH_CURRENT_FUNCTION,
402 OOMPH_EXCEPTION_LOCATION);
406 std::ostringstream error_message;
407 error_message <<
"Range Error: j " << j
408 <<
" is not in the range (0," 411 OOMPH_CURRENT_FUNCTION,
412 OOMPH_EXCEPTION_LOCATION);
417 Flux_interpolation_point[j];
427 #ifdef RANGE_CHECKING 430 std::ostringstream error_message;
431 error_message <<
"Range Error: edge " << edge
432 <<
" is not in the range (0,2)";
434 OOMPH_CURRENT_FUNCTION,
435 OOMPH_EXCEPTION_LOCATION);
439 std::ostringstream error_message;
440 error_message <<
"Range Error: j " << j
441 <<
" is not in the range (0," 444 OOMPH_CURRENT_FUNCTION,
445 OOMPH_EXCEPTION_LOCATION);
456 unsigned node_number=Q_edge_conv[edge];
466 s_flux_interpolation[0]=1.0-flux_interpolation_point[0];
467 s_flux_interpolation[1]=flux_interpolation_point[0];
470 s_flux_interpolation[0]=0.0;
471 s_flux_interpolation[1]=1.0-flux_interpolation_point[0];
474 s_flux_interpolation[0]=flux_interpolation_point[0];
475 s_flux_interpolation[1]=0.0;
486 #ifdef RANGE_CHECKING 489 std::ostringstream error_message;
490 error_message <<
"Range Error: j " << j
491 <<
" is not in the range (0," 494 OOMPH_CURRENT_FUNCTION,
495 OOMPH_EXCEPTION_LOCATION);
505 #ifdef RANGE_CHECKING 508 std::ostringstream error_message;
509 error_message <<
"Range Error: j " << j
510 <<
" is not in the range (0," 513 OOMPH_CURRENT_FUNCTION,
514 OOMPH_EXCEPTION_LOCATION);
523 #ifdef RANGE_CHECKING 526 std::ostringstream error_message;
527 error_message <<
"Range Error: j " << j
528 <<
" is not in the range (0," 531 OOMPH_CURRENT_FUNCTION,
532 OOMPH_EXCEPTION_LOCATION);
543 Shape &p_basis)
const;
548 #ifdef RANGE_CHECKING 551 std::ostringstream error_message;
552 error_message <<
"Range Error: j " << j
553 <<
" is not in the range (0," 556 OOMPH_CURRENT_FUNCTION,
557 OOMPH_EXCEPTION_LOCATION);
587 for(
unsigned i=0;
i<3;
i++)
594 length[
i]=std::sqrt(std::pow(y1-y0,2)+std::pow(x1-x0,2));
599 const double ref_length[3]={std::sqrt(2.0),1,1};
606 const unsigned n_index2 = basis.
nindex2();
607 for(
unsigned i=0;
i<n_index2;
i++)
609 for(
unsigned l=0;l<n_q_basis_edge;l++)
611 basis(l,
i)*=(length[l/(ORDER+1)]/ref_length[l/(ORDER+1)]);
636 void output(std::ostream &outfile,
const unsigned &Nplot)
671 Shape &div_q_basis_ds,
672 Shape &div_q_test_ds)
const 674 const unsigned n_q_basis = this->
nq_basis();
676 Shape q_basis_local(n_q_basis,2);
692 div_q_test_ds=div_q_basis_ds;
710 Shape &div_q_basis_ds,
711 Shape &div_q_test_ds)
const 719 du_basis_dx,du_test_dx,
722 div_q_basis_ds,div_q_test_ds);
void set_p_value(const unsigned &j, const double &value)
Set the jth pressure value.
void pin_q_internal_value(const unsigned &j, const double &q)
Pin the jth internal q value and set it to specified value.
unsigned nindex2() const
Return the range of index 2 of the shape function object.
double value(const unsigned &i) const
Return i-th stored value. This function is not virtual so that it can be inlined. This means that if ...
static const unsigned Face_index_of_edge_flux[]
Face index associated with edge flux degree of freedom.
static const double Flux_interpolation_point[]
The points along each edge where the fluxes are taken to be.
double q_internal(const unsigned &j) const
Return the values of the internal degree of freedom.
const unsigned Initial_Nvalue[6]
The number of values stored at each node.
Vector< double > edge_flux_interpolation_point(const unsigned &edge, const unsigned &j) const
Returns the local coordinate of the jth flux_interpolation point along specified edge.
FaceGeometry()
Constructor: Call constructor of base.
Node * vertex_node_pt(const unsigned &j) const
Pointer to the j-th vertex node in the element.
Nodes are derived from Data, but, in addition, have a definite (Eulerian) position in a space of a gi...
unsigned required_nvalue(const unsigned &n) const
Number of values required at node n.
const short & sign_edge(const unsigned &n) const
Accessor for the unit normal sign of edge n (const version)
short & sign_edge(const unsigned &n)
Accessor for the unit normal sign of edge n.
void output(std::ostream &outfile)
Output with default number of plot points.
unsigned nrecovery_order()
Recovery order for Z2 error estimator.
FaceGeometry()
Constructor: Call constructor of base class.
void pin(const unsigned &i)
Pin the i-th stored variable.
unsigned nq_basis_internal() const
Return the number of internal basis functions for flux q.
unsigned Q_internal_data_index
The internal data index where the internal q degrees of freedom are stored.
unsigned nq_basis_edge() const
Return the number of edge basis functions for flux q.
void pin_q_edge_value(const unsigned &j, const double &value)
Pin the j-th edge (flux) degree of freedom and set it to specified value.
void set_q_edge(const unsigned &j, const double &value)
Set the values of the j-th edge (flux) degree of freedom.
void set_q_internal(const unsigned &j, const double &value)
Set the values of the j-th internal degree of freedom.
double & x(const unsigned &i)
Return the i-th nodal coordinate.
int q_internal_local_eqn(const unsigned &j) const
Return the equation number of the j-th internal degree of freedom.
virtual double interpolated_x(const Vector< double > &s, const unsigned &i) const
Return FE interpolated coordinate x[i] at local coordinate s.
unsigned u_index_axisym_poroelasticity(const unsigned &j) const
Return the nodal index of the j-th solid displacement unknown [0: r; 1: z].
Integral *const & integral_pt() const
Return the pointer to the integration scheme (const version)
double p_value(const unsigned &j) const
Return the jth pressure value.
TAxisymmetricPoroelasticityElement()
Constructor.
void output(std::ostream &outfile, const unsigned &Nplot)
Output FE representation of soln: x,y,u1,u2,div_q,p at Nplot^DIM plot points.
virtual double knot(const unsigned &i, const unsigned &j) const =0
Return local coordinate s[j] of i-th integration point.
void set_value(const unsigned &i, const double &value_)
Set the i-th stored data value to specified value. The only reason that we require an explicit set fu...
Data *& internal_data_pt(const unsigned &i)
Return a pointer to i-th internal data object.
A class that represents a collection of data; each Data object may contain many different individual ...
double q_edge(const unsigned &j) const
Return the values of the j-th edge (flux) degree of freedom.
const unsigned Q_edge_conv[3]
unsigned face_index_of_q_edge_basis_fct(const unsigned &j) const
Return the face index associated with j-th edge flux degree of freedom.
double shape_basis_test_local_at_knot(const unsigned &ipt, Shape &psi, DShape &dpsi, Shape &u_basis, Shape &u_test, DShape &du_basis_dx, DShape &du_test_dx, Shape &q_basis, Shape &q_test, Shape &p_basis, Shape &p_test, Shape &div_q_basis_ds, Shape &div_q_test_ds) const
Returns the geometric basis, and the u, p and divergence basis functions and test functions at integr...
void edge_flux_interpolation_point_global(const unsigned &edge, const unsigned &j, Vector< double > &x) const
Compute the global coordinates of the jth flux_interpolation point along specified edge...
double transform_basis(const Vector< double > &s, const Shape &q_basis_local, Shape &psi, DShape &dpsi, Shape &q_basis) const
Performs a div-conserving transformation of the vector basis functions from the reference element to ...
Vector< Data * > q_edge_data_pt() const
Return vector of pointers to the Data objects that store the edge flux values.
Node *& node_pt(const unsigned &n)
Return a pointer to the local node n.
void set_q_internal(const unsigned &t, const unsigned &j, const double &value)
Set the values of the j-th internal degree of freedom at time history level t.
unsigned q_internal_index() const
Return the index of the internal data where the q_internal degrees of freedom are stored...
~TAxisymmetricPoroelasticityElement()
Destructor.
double q_edge(const unsigned &t, const unsigned &j) const
Return the values of the j-th edge (flux) degree of freedom at time history level t...
Node * edge_flux_node_pt(const unsigned &edge)
Get pointer to node that stores the edge flux dofs for specified edge.
double nodal_value(const unsigned &n, const unsigned &i) const
Return the i-th value stored at local node n. Produces suitably interpolated values for hanging nodes...
int p_local_eqn(const unsigned &j) const
Return the equation number of the j-th pressure degree of freedom.
Data * p_data_pt() const
Return pointer to the Data object that stores the pressure values.
void get_p_basis(const Vector< double > &s, Shape &p_basis) const
Return the pressure basis.
std::vector< short > Sign_edge
Unit normal signs associated with each edge to ensure inter-element continuity of the flux...
unsigned P_internal_data_index
The internal data index where the p degrees of freedom are stored.
void face_local_coordinate_of_flux_interpolation_point(const unsigned &edge, const unsigned &n, Vector< double > &s) const
Compute the face element coordinates of the nth flux interpolation point along specified edge...
Data * q_internal_data_pt() const
Return pointer to the Data object that stores the internal flux values.
unsigned np_basis() const
Return the total number of pressure basis functions.
void pin_p_value(const unsigned &j, const double &p)
Pin the jth pressure value and set to specified value.
double shape_basis_test_local(const Vector< double > &s, Shape &psi, DShape &dpsi, Shape &u_basis, Shape &u_test, DShape &du_basis_dx, DShape &du_test_dx, Shape &q_basis, Shape &q_test, Shape &p_basis, Shape &p_test, Shape &div_q_basis_ds, Shape &div_q_test_ds) const
Returns the geometric basis, and the u, p and divergence basis functions and test functions at local ...
int q_edge_local_eqn(const unsigned &j) const
Return the equation number of the j-th edge (flux) degree of freedom.
void set_q_edge(const unsigned &t, const unsigned &j, const double &value)
Set the values of the j-th edge (flux) degree of freedom at time history level t. ...
Class implementing the generic maths of the axisym poroelasticity equations: axisym linear elasticity...
unsigned nedge_flux_interpolation_point() const
Returns the number of flux_interpolation points along each edge of the element.
void scale_basis(Shape &basis) const
Scale the edge basis to allow arbitrary edge mappings.
unsigned face_index_of_edge(const unsigned &j) const
Return the face index associated with specified edge.
unsigned q_edge_index(const unsigned &j) const
Return the nodal index at which the jth edge unknown is stored.
unsigned q_edge_node_number(const unsigned &j) const
Return the number of the node where the jth edge unknown is stored.
void get_div_q_basis_local(const Vector< double > &s, Shape &div_q_basis_ds) const
Returns the local form of the q basis and dbasis/ds at local coordinate s.
unsigned nvertex_node() const
Number of vertex nodes in the element.
void output(std::ostream &outfile)
Output with default number of plot points.
virtual unsigned nq_basis() const
Return the total number of computational basis functions for q.
void get_q_basis_local(const Vector< double > &s, Shape &q_basis) const
Returns the local form of the q basis at local coordinate s.
double q_internal(const unsigned &t, const unsigned &j) const
Return the value of the j-th internal degree of freedom at time history level t.
int nodal_local_eqn(const unsigned &n, const unsigned &i) const
Return the local equation number corresponding to the i-th value at the n-th local node...
int internal_local_eqn(const unsigned &i, const unsigned &j) const
Return the local equation number corresponding to the j-th value stored at the i-th internal data...