oomph::AxisymmetricPoroelasticityEquations Class Referenceabstract

#include <axisym_poroelasticity_elements.h>

+ Inheritance diagram for oomph::AxisymmetricPoroelasticityEquations:

Public Types

typedef void(* SourceFctPt) (const double &time, const Vector< double > &x, Vector< double > &f)
 Source function pointer typedef. More...
 
typedef void(* MassSourceFctPt) (const double &time, const Vector< double > &x, double &f)
 Mass source function pointer typedef. More...
 
- Public Types inherited from oomph::FiniteElement
typedef void(* SteadyExactSolutionFctPt) (const Vector< double > &, Vector< double > &)
 
typedef void(* UnsteadyExactSolutionFctPt) (const double &, const Vector< double > &, Vector< double > &)
 

Public Member Functions

 AxisymmetricPoroelasticityEquations ()
 Constructor. More...
 
const doubleyoungs_modulus () const
 
double *& youngs_modulus_pt ()
 
const doublenu () const
 Access function for Poisson's ratio. More...
 
double *& nu_pt ()
 Access function for pointer to Poisson's ratio. More...
 
const doublelambda_sq () const
 Access function for timescale ratio (nondim density) More...
 
double *& lambda_sq_pt ()
 Access function for pointer to timescale ratio (nondim density) More...
 
const doubledensity_ratio () const
 Access function for the density ratio (fluid to solid) More...
 
double *& density_ratio_pt ()
 Access function for pointer to the density ratio (fluid to solid) More...
 
const doublepermeability () const
 Access function for the nondim permeability. More...
 
double *& permeability_pt ()
 Access function for pointer to the nondim permeability. More...
 
const doublepermeability_ratio () const
 
double *& permeability_ratio_pt ()
 
const doublealpha () const
 Access function for alpha, the Biot parameter. More...
 
double *& alpha_pt ()
 Access function for pointer to alpha, the Biot parameter. More...
 
const doubleporosity () const
 Access function for the porosity. More...
 
double *& porosity_pt ()
 Access function for pointer to the porosity. More...
 
SourceFctPtsolid_body_force_fct_pt ()
 Access function: Pointer to solid body force function. More...
 
SourceFctPt solid_body_force_fct_pt () const
 Access function: Pointer to solid body force function (const version) More...
 
SourceFctPtfluid_body_force_fct_pt ()
 Access function: Pointer to fluid force function. More...
 
SourceFctPt fluid_body_force_fct_pt () const
 Access function: Pointer to fluid force function (const version) More...
 
MassSourceFctPtmass_source_fct_pt ()
 Access function: Pointer to mass source function. More...
 
MassSourceFctPt mass_source_fct_pt () const
 Access function: Pointer to mass source function (const version) More...
 
void solid_body_force (const double &time, const Vector< double > &x, Vector< double > &b) const
 
void fluid_body_force (const double &time, const Vector< double > &x, Vector< double > &b) const
 
void mass_source (const double &time, const Vector< double > &x, double &b) const
 
virtual unsigned required_nvalue (const unsigned &n) const =0
 Number of values required at node n. More...
 
virtual unsigned u_index_axisym_poroelasticity (const unsigned &j) const =0
 Return the nodal index of the j-th solid displacement unknown. More...
 
virtual int q_edge_local_eqn (const unsigned &j) const =0
 Return the equation number of the j-th edge (flux) degree of freedom. More...
 
virtual int q_internal_local_eqn (const unsigned &j) const =0
 Return the equation number of the j-th internal degree of freedom. More...
 
virtual Vector< Data * > q_edge_data_pt () const =0
 
virtual Dataq_internal_data_pt () const =0
 Return pointer to the Data object that stores the internal flux values. More...
 
virtual unsigned q_edge_index (const unsigned &j) const =0
 Return the nodal index at which the jth edge unknown is stored. More...
 
virtual unsigned q_internal_index () const =0
 
virtual unsigned q_edge_node_number (const unsigned &j) const =0
 Return the number of the node where the jth edge unknown is stored. More...
 
virtual double q_edge (const unsigned &j) const =0
 Return the values of the j-th edge (flux) degree of freedom. More...
 
virtual double q_edge (const unsigned &t, const unsigned &j) const =0
 
virtual unsigned face_index_of_q_edge_basis_fct (const unsigned &j) const =0
 Return the face index associated with j-th edge flux degree of freedom. More...
 
virtual unsigned face_index_of_edge (const unsigned &j) const =0
 Return the face index associated with specified edge. More...
 
virtual void face_local_coordinate_of_flux_interpolation_point (const unsigned &edge, const unsigned &n, Vector< double > &s) const =0
 
virtual double q_internal (const unsigned &j) const =0
 Return the values of the j-th internal degree of freedom. More...
 
virtual double q_internal (const unsigned &t, const unsigned &j) const =0
 
virtual void set_q_edge (const unsigned &j, const double &value)=0
 Set the values of the j-th edge (flux) degree of freedom. More...
 
virtual void set_q_internal (const unsigned &j, const double &value)=0
 Set the values of the j-th internal degree of freedom. More...
 
virtual void set_q_edge (const unsigned &t, const unsigned &j, const double &value)=0
 
virtual void set_q_internal (const unsigned &t, const unsigned &j, const double &value)=0
 
virtual unsigned nq_basis () const
 Return the total number of computational basis functions for q. More...
 
virtual unsigned nq_basis_edge () const =0
 Return the number of edge basis functions for q. More...
 
virtual unsigned nq_basis_internal () const =0
 Return the number of internal basis functions for q. More...
 
virtual void get_q_basis_local (const Vector< double > &s, Shape &q_basis) const =0
 Comute the local form of the q basis at local coordinate s. More...
 
virtual void get_div_q_basis_local (const Vector< double > &s, Shape &div_q_basis_ds) const =0
 
void get_q_basis (const Vector< double > &s, Shape &q_basis) const
 Compute the transformed basis at local coordinate s. More...
 
virtual unsigned nedge_flux_interpolation_point () const =0
 
virtual Vector< doubleedge_flux_interpolation_point (const unsigned &edge, const unsigned &j) const =0
 
virtual void edge_flux_interpolation_point_global (const unsigned &edge, const unsigned &j, Vector< double > &x) const =0
 
virtual void pin_q_internal_value (const unsigned &j, const double &value)=0
 Pin the jth internal q value and set it to specified value. More...
 
virtual void pin_q_edge_value (const unsigned &j, const double &value)=0
 Pin the j-th edge (flux) degree of freedom and set it to specified value. More...
 
virtual int p_local_eqn (const unsigned &j) const =0
 Return the equation number of the j-th pressure degree of freedom. More...
 
virtual double p_value (const unsigned &j) const =0
 Return the jth pressure value. More...
 
virtual unsigned np_basis () const =0
 Return the total number of pressure basis functions. More...
 
virtual void get_p_basis (const Vector< double > &s, Shape &p_basis) const =0
 Compute the pressure basis. More...
 
virtual void pin_p_value (const unsigned &j, const double &p)=0
 Pin the jth pressure value and set it to p. More...
 
virtual void set_p_value (const unsigned &j, const double &value)=0
 Set the jth pressure value. More...
 
virtual Datap_data_pt () const =0
 Return pointer to the Data object that stores the pressure values. More...
 
virtual void scale_basis (Shape &basis) const =0
 Scale the edge basis to allow arbitrary edge mappings. More...
 
double transform_basis (const Vector< double > &s, const Shape &q_basis_local, Shape &psi, DShape &dpsi, Shape &q_basis) const
 
double transform_basis (const Vector< double > &s, const Shape &q_basis_local, Shape &psi, Shape &q_basis) const
 
void fill_in_contribution_to_residuals (Vector< double > &residuals)
 Fill in contribution to residuals for the Darcy equations. More...
 
void fill_in_contribution_to_jacobian (Vector< double > &residuals, DenseMatrix< double > &jacobian)
 Fill in the Jacobian matrix for the Newton method. More...
 
double interpolated_div_du_dt (const Vector< double > &s, Vector< double > &div_dudt_components) const
 
double interpolated_div_u (const Vector< double > &s, Vector< double > &div_u_components) const
 
void interpolated_u (const Vector< double > &s, Vector< double > &disp) const
 Calculate the FE representation of u. More...
 
double interpolated_u (const Vector< double > &s, const unsigned &i) const
 Calculate the FE representation of the i-th component of u. More...
 
double interpolated_u (const unsigned &t, const Vector< double > &s, const unsigned &i) const
 
void interpolated_du_dt (const Vector< double > &s, Vector< double > &du_dt) const
 Calculate the FE representation of du_dt. More...
 
void interpolated_q (const Vector< double > &s, Vector< double > &q) const
 Calculate the FE representation of q. More...
 
void interpolated_q (const unsigned &t, const Vector< double > &s, Vector< double > &q) const
 
double interpolated_q (const Vector< double > &s, const unsigned i) const
 Calculate the FE representation of the i-th component of q. More...
 
double interpolated_q (const unsigned &t, const Vector< double > &s, const unsigned i) const
 
void interpolated_div_q (const Vector< double > &s, double &div_q) const
 Calculate the FE representation of div u. More...
 
double interpolated_div_q (const Vector< double > &s) const
 Calculate the FE representation of div q and return it. More...
 
void interpolated_p (const Vector< double > &s, double &p) const
 Calculate the FE representation of p. More...
 
double interpolated_p (const Vector< double > &s) const
 Calculate the FE representation of p and return it. More...
 
double du_dt (const unsigned &n, const unsigned &i) const
 du/dt at local node n More...
 
double d2u_dt2 (const unsigned &n, const unsigned &i) const
 d^2u/dt^2 at local node n More...
 
double dq_edge_dt (const unsigned &n) const
 dq_edge/dt for the n-th edge degree of freedom More...
 
double dq_internal_dt (const unsigned &n) const
 dq_internal/dt for the n-th internal degree of freedom More...
 
void set_q_internal_timestepper (TimeStepper *const time_stepper_pt)
 Set the timestepper of the q internal data object. More...
 
bool darcy_is_switched_off ()
 Is Darcy flow switched off? More...
 
void switch_off_darcy ()
 Switch off Darcy flow. More...
 
unsigned self_test ()
 Self test. More...
 
unsigned nscalar_paraview () const
 
void scalar_value_paraview (std::ofstream &file_out, const unsigned &i, const unsigned &nplot) const
 
std::string scalar_name_paraview (const unsigned &i) const
 
void point_output_data (const Vector< double > &s, Vector< double > &data)
 
void output (std::ostream &outfile)
 Output with default number of plot points. More...
 
void output (std::ostream &outfile, const unsigned &nplot)
 
void output_with_projected_flux (std::ostream &outfile, const unsigned &nplot, const Vector< double > unit_normal)
 
void output_fct (std::ostream &outfile, const unsigned &nplot, FiniteElement::SteadyExactSolutionFctPt exact_soln_pt)
 
void output_fct (std::ostream &outfile, const unsigned &nplot, const double &time, FiniteElement::UnsteadyExactSolutionFctPt exact_soln_pt)
 
void compute_error (std::ostream &outfile, FiniteElement::SteadyExactSolutionFctPt exact_soln_pt, Vector< double > &error, Vector< double > &norm)
 
void compute_error (std::ostream &outfile, FiniteElement::UnsteadyExactSolutionFctPt exact_soln_pt, const double &time, Vector< double > &error, Vector< double > &norm)
 
unsigned num_Z2_flux_terms ()
 Number off flux terms for Z2 error estimator (use Darcy flux) More...
 
void get_Z2_flux (const Vector< double > &s, Vector< double > &flux)
 Z2 flux (use Darcy flux) More...
 
- Public Member Functions inherited from oomph::FiniteElement
void set_dimension (const unsigned &dim)
 
void set_nodal_dimension (const unsigned &nodal_dim)
 
void set_nnodal_position_type (const unsigned &nposition_type)
 Set the number of types required to interpolate the coordinate. More...
 
void set_n_node (const unsigned &n)
 
int nodal_local_eqn (const unsigned &n, const unsigned &i) const
 
double dJ_eulerian_at_knot (const unsigned &ipt, Shape &psi, DenseMatrix< double > &djacobian_dX) const
 
 FiniteElement ()
 Constructor. More...
 
virtual ~FiniteElement ()
 
 FiniteElement (const FiniteElement &)=delete
 Broken copy constructor. More...
 
virtual bool local_coord_is_valid (const Vector< double > &s)
 Broken assignment operator. More...
 
virtual void move_local_coord_back_into_element (Vector< double > &s) const
 
void get_centre_of_gravity_and_max_radius_in_terms_of_zeta (Vector< double > &cog, double &max_radius) const
 
virtual void local_coordinate_of_node (const unsigned &j, Vector< double > &s) const
 
virtual void local_fraction_of_node (const unsigned &j, Vector< double > &s_fraction)
 
virtual double local_one_d_fraction_of_node (const unsigned &n1d, const unsigned &i)
 
virtual void set_macro_elem_pt (MacroElement *macro_elem_pt)
 
MacroElementmacro_elem_pt ()
 Access function to pointer to macro element. More...
 
void get_x (const Vector< double > &s, Vector< double > &x) const
 
void get_x (const unsigned &t, const Vector< double > &s, Vector< double > &x)
 
virtual void get_x_from_macro_element (const Vector< double > &s, Vector< double > &x) const
 
virtual void get_x_from_macro_element (const unsigned &t, const Vector< double > &s, Vector< double > &x)
 
virtual void set_integration_scheme (Integral *const &integral_pt)
 Set the spatial integration scheme. More...
 
Integral *const & integral_pt () const
 Return the pointer to the integration scheme (const version) More...
 
virtual void shape (const Vector< double > &s, Shape &psi) const =0
 
virtual void shape_at_knot (const unsigned &ipt, Shape &psi) const
 
virtual void dshape_local (const Vector< double > &s, Shape &psi, DShape &dpsids) const
 
virtual void dshape_local_at_knot (const unsigned &ipt, Shape &psi, DShape &dpsids) const
 
virtual void d2shape_local (const Vector< double > &s, Shape &psi, DShape &dpsids, DShape &d2psids) const
 
virtual void d2shape_local_at_knot (const unsigned &ipt, Shape &psi, DShape &dpsids, DShape &d2psids) const
 
virtual double J_eulerian (const Vector< double > &s) const
 
virtual double J_eulerian_at_knot (const unsigned &ipt) const
 
void check_J_eulerian_at_knots (bool &passed) const
 
void check_jacobian (const double &jacobian) const
 
double dshape_eulerian (const Vector< double > &s, Shape &psi, DShape &dpsidx) const
 
virtual double dshape_eulerian_at_knot (const unsigned &ipt, Shape &psi, DShape &dpsidx) const
 
virtual double dshape_eulerian_at_knot (const unsigned &ipt, Shape &psi, DShape &dpsi, DenseMatrix< double > &djacobian_dX, RankFourTensor< double > &d_dpsidx_dX) const
 
double d2shape_eulerian (const Vector< double > &s, Shape &psi, DShape &dpsidx, DShape &d2psidx) const
 
virtual double d2shape_eulerian_at_knot (const unsigned &ipt, Shape &psi, DShape &dpsidx, DShape &d2psidx) const
 
virtual void assign_nodal_local_eqn_numbers (const bool &store_local_dof_pt)
 
virtual void describe_local_dofs (std::ostream &out, const std::string &current_string) const
 
virtual void describe_nodal_local_dofs (std::ostream &out, const std::string &current_string) const
 
virtual void assign_all_generic_local_eqn_numbers (const bool &store_local_dof_pt)
 
Node *& node_pt (const unsigned &n)
 Return a pointer to the local node n. More...
 
Node *const & node_pt (const unsigned &n) const
 Return a pointer to the local node n (const version) More...
 
unsigned nnode () const
 Return the number of nodes. More...
 
virtual unsigned nnode_1d () const
 
double raw_nodal_position (const unsigned &n, const unsigned &i) const
 
double raw_nodal_position (const unsigned &t, const unsigned &n, const unsigned &i) const
 
double raw_dnodal_position_dt (const unsigned &n, const unsigned &i) const
 
double raw_dnodal_position_dt (const unsigned &n, const unsigned &j, const unsigned &i) const
 
double raw_nodal_position_gen (const unsigned &n, const unsigned &k, const unsigned &i) const
 
double raw_nodal_position_gen (const unsigned &t, const unsigned &n, const unsigned &k, const unsigned &i) const
 
double raw_dnodal_position_gen_dt (const unsigned &n, const unsigned &k, const unsigned &i) const
 
double raw_dnodal_position_gen_dt (const unsigned &j, const unsigned &n, const unsigned &k, const unsigned &i) const
 
double nodal_position (const unsigned &n, const unsigned &i) const
 
double nodal_position (const unsigned &t, const unsigned &n, const unsigned &i) const
 
double dnodal_position_dt (const unsigned &n, const unsigned &i) const
 Return the i-th component of nodal velocity: dx/dt at local node n. More...
 
double dnodal_position_dt (const unsigned &n, const unsigned &j, const unsigned &i) const
 
double nodal_position_gen (const unsigned &n, const unsigned &k, const unsigned &i) const
 
double nodal_position_gen (const unsigned &t, const unsigned &n, const unsigned &k, const unsigned &i) const
 
double dnodal_position_gen_dt (const unsigned &n, const unsigned &k, const unsigned &i) const
 
double dnodal_position_gen_dt (const unsigned &j, const unsigned &n, const unsigned &k, const unsigned &i) const
 
virtual void get_dresidual_dnodal_coordinates (RankThreeTensor< double > &dresidual_dnodal_coordinates)
 
virtual void disable_ALE ()
 
virtual void enable_ALE ()
 
unsigned nnodal_position_type () const
 
bool has_hanging_nodes () const
 
unsigned nodal_dimension () const
 Return the required Eulerian dimension of the nodes in this element. More...
 
virtual Nodeconstruct_node (const unsigned &n)
 
virtual Nodeconstruct_node (const unsigned &n, TimeStepper *const &time_stepper_pt)
 
virtual Nodeconstruct_boundary_node (const unsigned &n)
 
virtual Nodeconstruct_boundary_node (const unsigned &n, TimeStepper *const &time_stepper_pt)
 
int get_node_number (Node *const &node_pt) const
 
virtual Nodeget_node_at_local_coordinate (const Vector< double > &s) const
 
double raw_nodal_value (const unsigned &n, const unsigned &i) const
 
double raw_nodal_value (const unsigned &t, const unsigned &n, const unsigned &i) const
 
double nodal_value (const unsigned &n, const unsigned &i) const
 
double nodal_value (const unsigned &t, const unsigned &n, const unsigned &i) const
 
unsigned dim () const
 
virtual ElementGeometry::ElementGeometry element_geometry () const
 Return the geometry type of the element (either Q or T usually). More...
 
virtual double interpolated_x (const Vector< double > &s, const unsigned &i) const
 Return FE interpolated coordinate x[i] at local coordinate s. More...
 
virtual double interpolated_x (const unsigned &t, const Vector< double > &s, const unsigned &i) const
 
virtual void interpolated_x (const Vector< double > &s, Vector< double > &x) const
 Return FE interpolated position x[] at local coordinate s as Vector. More...
 
virtual void interpolated_x (const unsigned &t, const Vector< double > &s, Vector< double > &x) const
 
virtual double interpolated_dxdt (const Vector< double > &s, const unsigned &i, const unsigned &t)
 
virtual void interpolated_dxdt (const Vector< double > &s, const unsigned &t, Vector< double > &dxdt)
 
unsigned ngeom_data () const
 
Datageom_data_pt (const unsigned &j)
 
void position (const Vector< double > &zeta, Vector< double > &r) const
 
void position (const unsigned &t, const Vector< double > &zeta, Vector< double > &r) const
 
void dposition_dt (const Vector< double > &zeta, const unsigned &t, Vector< double > &drdt)
 
virtual double zeta_nodal (const unsigned &n, const unsigned &k, const unsigned &i) const
 
void interpolated_zeta (const Vector< double > &s, Vector< double > &zeta) const
 
void locate_zeta (const Vector< double > &zeta, GeomObject *&geom_object_pt, Vector< double > &s, const bool &use_coordinate_as_initial_guess=false)
 
virtual void node_update ()
 
virtual void identify_field_data_for_interactions (std::set< std::pair< Data *, unsigned >> &paired_field_data)
 
virtual void identify_geometric_data (std::set< Data * > &geometric_data_pt)
 
virtual double s_min () const
 Min value of local coordinate. More...
 
virtual double s_max () const
 Max. value of local coordinate. More...
 
double size () const
 
virtual double compute_physical_size () const
 
void point_output (std::ostream &outfile, const Vector< double > &s)
 
virtual unsigned nplot_points_paraview (const unsigned &nplot) const
 
virtual unsigned nsub_elements_paraview (const unsigned &nplot) const
 
void output_paraview (std::ofstream &file_out, const unsigned &nplot) const
 
virtual void write_paraview_output_offset_information (std::ofstream &file_out, const unsigned &nplot, unsigned &counter) const
 
virtual void write_paraview_type (std::ofstream &file_out, const unsigned &nplot) const
 
virtual void write_paraview_offsets (std::ofstream &file_out, const unsigned &nplot, unsigned &offset_sum) const
 
virtual void scalar_value_fct_paraview (std::ofstream &file_out, const unsigned &i, const unsigned &nplot, FiniteElement::SteadyExactSolutionFctPt exact_soln_pt) const
 
virtual void scalar_value_fct_paraview (std::ofstream &file_out, const unsigned &i, const unsigned &nplot, const double &time, FiniteElement::UnsteadyExactSolutionFctPt exact_soln_pt) const
 
virtual void output (const unsigned &t, std::ostream &outfile, const unsigned &n_plot) const
 
virtual void output (FILE *file_pt)
 
virtual void output (FILE *file_pt, const unsigned &n_plot)
 
virtual void output_fct (std::ostream &outfile, const unsigned &n_plot, const double &time, const SolutionFunctorBase &exact_soln) const
 Output a time-dependent exact solution over the element. More...
 
virtual void get_s_plot (const unsigned &i, const unsigned &nplot, Vector< double > &s, const bool &shifted_to_interior=false) const
 
virtual std::string tecplot_zone_string (const unsigned &nplot) const
 
virtual void write_tecplot_zone_footer (std::ostream &outfile, const unsigned &nplot) const
 
virtual void write_tecplot_zone_footer (FILE *file_pt, const unsigned &nplot) const
 
virtual unsigned nplot_points (const unsigned &nplot) const
 
virtual void compute_error (FiniteElement::SteadyExactSolutionFctPt exact_soln_pt, double &error, double &norm)
 Calculate the norm of the error and that of the exact solution. More...
 
virtual void compute_error (FiniteElement::UnsteadyExactSolutionFctPt exact_soln_pt, const double &time, double &error, double &norm)
 Calculate the norm of the error and that of the exact solution. More...
 
virtual void compute_error (FiniteElement::SteadyExactSolutionFctPt exact_soln_pt, Vector< double > &error, Vector< double > &norm)
 
virtual void compute_error (FiniteElement::UnsteadyExactSolutionFctPt exact_soln_pt, const double &time, Vector< double > &error, Vector< double > &norm)
 
virtual void compute_error (std::ostream &outfile, FiniteElement::SteadyExactSolutionFctPt exact_soln_pt, double &error, double &norm)
 
virtual void compute_error (std::ostream &outfile, FiniteElement::UnsteadyExactSolutionFctPt exact_soln_pt, const double &time, double &error, double &norm)
 
virtual void compute_abs_error (std::ostream &outfile, FiniteElement::SteadyExactSolutionFctPt exact_soln_pt, double &error)
 
void integrate_fct (FiniteElement::SteadyExactSolutionFctPt integrand_fct_pt, Vector< double > &integral)
 Integrate Vector-valued function over element. More...
 
void integrate_fct (FiniteElement::UnsteadyExactSolutionFctPt integrand_fct_pt, const double &time, Vector< double > &integral)
 Integrate Vector-valued time-dep function over element. More...
 
virtual void build_face_element (const int &face_index, FaceElement *face_element_pt)
 
virtual unsigned get_bulk_node_number (const int &face_index, const unsigned &i) const
 
virtual int face_outer_unit_normal_sign (const int &face_index) const
 Get the sign of the outer unit normal on the face given by face_index. More...
 
virtual unsigned nnode_on_face () const
 
void face_node_number_error_check (const unsigned &i) const
 Range check for face node numbers. More...
 
virtual CoordinateMappingFctPt face_to_bulk_coordinate_fct_pt (const int &face_index) const
 
virtual BulkCoordinateDerivativesFctPt bulk_coordinate_derivatives_fct_pt (const int &face_index) const
 
- Public Member Functions inherited from oomph::GeneralisedElement
 GeneralisedElement ()
 Constructor: Initialise all pointers and all values to zero. More...
 
virtual ~GeneralisedElement ()
 Virtual destructor to clean up any memory allocated by the object. More...
 
 GeneralisedElement (const GeneralisedElement &)=delete
 Broken copy constructor. More...
 
void operator= (const GeneralisedElement &)=delete
 Broken assignment operator. More...
 
Data *& internal_data_pt (const unsigned &i)
 Return a pointer to i-th internal data object. More...
 
Data *const & internal_data_pt (const unsigned &i) const
 Return a pointer to i-th internal data object (const version) More...
 
Data *& external_data_pt (const unsigned &i)
 Return a pointer to i-th external data object. More...
 
Data *const & external_data_pt (const unsigned &i) const
 Return a pointer to i-th external data object (const version) More...
 
unsigned long eqn_number (const unsigned &ieqn_local) const
 
int local_eqn_number (const unsigned long &ieqn_global) const
 
unsigned add_external_data (Data *const &data_pt, const bool &fd=true)
 
bool external_data_fd (const unsigned &i) const
 
void exclude_external_data_fd (const unsigned &i)
 
void include_external_data_fd (const unsigned &i)
 
void flush_external_data ()
 Flush all external data. More...
 
void flush_external_data (Data *const &data_pt)
 Flush the object addressed by data_pt from the external data array. More...
 
unsigned ninternal_data () const
 Return the number of internal data objects. More...
 
unsigned nexternal_data () const
 Return the number of external data objects. More...
 
unsigned ndof () const
 Return the number of equations/dofs in the element. More...
 
void dof_vector (const unsigned &t, Vector< double > &dof)
 Return the vector of dof values at time level t. More...
 
void dof_pt_vector (Vector< double * > &dof_pt)
 Return the vector of pointers to dof values. More...
 
void set_internal_data_time_stepper (const unsigned &i, TimeStepper *const &time_stepper_pt, const bool &preserve_existing_data)
 
void assign_internal_eqn_numbers (unsigned long &global_number, Vector< double * > &Dof_pt)
 
void describe_dofs (std::ostream &out, const std::string &current_string) const
 
void add_internal_value_pt_to_map (std::map< unsigned, double * > &map_of_value_pt)
 
virtual void assign_local_eqn_numbers (const bool &store_local_dof_pt)
 
virtual void complete_setup_of_dependencies ()
 
virtual void get_residuals (Vector< double > &residuals)
 
virtual void get_jacobian (Vector< double > &residuals, DenseMatrix< double > &jacobian)
 
virtual void get_mass_matrix (Vector< double > &residuals, DenseMatrix< double > &mass_matrix)
 
virtual void get_jacobian_and_mass_matrix (Vector< double > &residuals, DenseMatrix< double > &jacobian, DenseMatrix< double > &mass_matrix)
 
virtual void get_dresiduals_dparameter (double *const &parameter_pt, Vector< double > &dres_dparam)
 
virtual void get_djacobian_dparameter (double *const &parameter_pt, Vector< double > &dres_dparam, DenseMatrix< double > &djac_dparam)
 
virtual void get_djacobian_and_dmass_matrix_dparameter (double *const &parameter_pt, Vector< double > &dres_dparam, DenseMatrix< double > &djac_dparam, DenseMatrix< double > &dmass_matrix_dparam)
 
virtual void get_hessian_vector_products (Vector< double > const &Y, DenseMatrix< double > const &C, DenseMatrix< double > &product)
 
virtual void get_inner_products (Vector< std::pair< unsigned, unsigned >> const &history_index, Vector< double > &inner_product)
 
virtual void get_inner_product_vectors (Vector< unsigned > const &history_index, Vector< Vector< double >> &inner_product_vector)
 
virtual void compute_norm (Vector< double > &norm)
 
virtual void compute_norm (double &norm)
 
virtual unsigned ndof_types () const
 
virtual void get_dof_numbers_for_unknowns (std::list< std::pair< unsigned long, unsigned >> &dof_lookup_list) const
 
- Public Member Functions inherited from oomph::GeomObject
 GeomObject ()
 Default constructor. More...
 
 GeomObject (const unsigned &ndim)
 
 GeomObject (const unsigned &nlagrangian, const unsigned &ndim)
 
 GeomObject (const unsigned &nlagrangian, const unsigned &ndim, TimeStepper *time_stepper_pt)
 
 GeomObject (const GeomObject &dummy)=delete
 Broken copy constructor. More...
 
void operator= (const GeomObject &)=delete
 Broken assignment operator. More...
 
virtual ~GeomObject ()
 (Empty) destructor More...
 
unsigned nlagrangian () const
 Access function to # of Lagrangian coordinates. More...
 
unsigned ndim () const
 Access function to # of Eulerian coordinates. More...
 
void set_nlagrangian_and_ndim (const unsigned &n_lagrangian, const unsigned &n_dim)
 Set # of Lagrangian and Eulerian coordinates. More...
 
TimeStepper *& time_stepper_pt ()
 
TimeSteppertime_stepper_pt () const
 
virtual void position (const double &t, const Vector< double > &zeta, Vector< double > &r) const
 
virtual void dposition (const Vector< double > &zeta, DenseMatrix< double > &drdzeta) const
 
virtual void d2position (const Vector< double > &zeta, RankThreeTensor< double > &ddrdzeta) const
 
virtual void d2position (const Vector< double > &zeta, Vector< double > &r, DenseMatrix< double > &drdzeta, RankThreeTensor< double > &ddrdzeta) const
 
- Public Member Functions inherited from oomph::ElementWithZ2ErrorEstimator
 ElementWithZ2ErrorEstimator ()
 Default empty constructor. More...
 
 ElementWithZ2ErrorEstimator (const ElementWithZ2ErrorEstimator &)=delete
 Broken copy constructor. More...
 
void operator= (const ElementWithZ2ErrorEstimator &)=delete
 Broken assignment operator. More...
 
virtual unsigned ncompound_fluxes ()
 
virtual void compute_exact_Z2_error (std::ostream &outfile, FiniteElement::SteadyExactSolutionFctPt exact_flux_pt, double &error, double &norm)
 
virtual void get_Z2_compound_flux_indices (Vector< unsigned > &flux_index)
 
virtual unsigned nvertex_node () const =0
 Number of vertex nodes in the element. More...
 
virtual Nodevertex_node_pt (const unsigned &j) const =0
 
virtual unsigned nrecovery_order ()=0
 Order of recovery shape functions. More...
 
virtual double geometric_jacobian (const Vector< double > &x)
 

Protected Member Functions

virtual 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 =0
 
virtual 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 =0
 
virtual void fill_in_generic_residual_contribution (Vector< double > &residuals, DenseMatrix< double > &jacobian, bool flag)
 Fill in residuals and, if flag==true, jacobian. More...
 
- Protected Member Functions inherited from oomph::FiniteElement
virtual void assemble_local_to_eulerian_jacobian (const DShape &dpsids, DenseMatrix< double > &jacobian) const
 
virtual void assemble_local_to_eulerian_jacobian2 (const DShape &d2psids, DenseMatrix< double > &jacobian2) const
 
virtual void assemble_eulerian_base_vectors (const DShape &dpsids, DenseMatrix< double > &interpolated_G) const
 
template<unsigned DIM>
double invert_jacobian (const DenseMatrix< double > &jacobian, DenseMatrix< double > &inverse_jacobian) const
 
virtual double invert_jacobian_mapping (const DenseMatrix< double > &jacobian, DenseMatrix< double > &inverse_jacobian) const
 
virtual double local_to_eulerian_mapping (const DShape &dpsids, DenseMatrix< double > &jacobian, DenseMatrix< double > &inverse_jacobian) const
 
double local_to_eulerian_mapping (const DShape &dpsids, DenseMatrix< double > &inverse_jacobian) const
 
virtual double local_to_eulerian_mapping_diagonal (const DShape &dpsids, DenseMatrix< double > &jacobian, DenseMatrix< double > &inverse_jacobian) const
 
virtual void dJ_eulerian_dnodal_coordinates (const DenseMatrix< double > &jacobian, const DShape &dpsids, DenseMatrix< double > &djacobian_dX) const
 
template<unsigned DIM>
void dJ_eulerian_dnodal_coordinates_templated_helper (const DenseMatrix< double > &jacobian, const DShape &dpsids, DenseMatrix< double > &djacobian_dX) const
 
virtual void d_dshape_eulerian_dnodal_coordinates (const double &det_jacobian, const DenseMatrix< double > &jacobian, const DenseMatrix< double > &djacobian_dX, const DenseMatrix< double > &inverse_jacobian, const DShape &dpsids, RankFourTensor< double > &d_dpsidx_dX) const
 
template<unsigned DIM>
void d_dshape_eulerian_dnodal_coordinates_templated_helper (const double &det_jacobian, const DenseMatrix< double > &jacobian, const DenseMatrix< double > &djacobian_dX, const DenseMatrix< double > &inverse_jacobian, const DShape &dpsids, RankFourTensor< double > &d_dpsidx_dX) const
 
virtual void transform_derivatives (const DenseMatrix< double > &inverse_jacobian, DShape &dbasis) const
 
void transform_derivatives_diagonal (const DenseMatrix< double > &inverse_jacobian, DShape &dbasis) const
 
virtual void transform_second_derivatives (const DenseMatrix< double > &jacobian, const DenseMatrix< double > &inverse_jacobian, const DenseMatrix< double > &jacobian2, DShape &dbasis, DShape &d2basis) const
 
template<unsigned DIM>
void transform_second_derivatives_template (const DenseMatrix< double > &jacobian, const DenseMatrix< double > &inverse_jacobian, const DenseMatrix< double > &jacobian2, DShape &dbasis, DShape &d2basis) const
 
template<unsigned DIM>
void transform_second_derivatives_diagonal (const DenseMatrix< double > &jacobian, const DenseMatrix< double > &inverse_jacobian, const DenseMatrix< double > &jacobian2, DShape &dbasis, DShape &d2basis) const
 
virtual void fill_in_jacobian_from_nodal_by_fd (Vector< double > &residuals, DenseMatrix< double > &jacobian)
 
void fill_in_jacobian_from_nodal_by_fd (DenseMatrix< double > &jacobian)
 
virtual void update_before_nodal_fd ()
 
virtual void reset_after_nodal_fd ()
 
virtual void update_in_nodal_fd (const unsigned &i)
 
virtual void reset_in_nodal_fd (const unsigned &i)
 
void fill_in_contribution_to_jacobian (Vector< double > &residuals, DenseMatrix< double > &jacobian)
 
template<>
double invert_jacobian (const DenseMatrix< double > &jacobian, DenseMatrix< double > &inverse_jacobian) const
 Zero-d specialisation of function to calculate inverse of jacobian mapping. More...
 
template<>
double invert_jacobian (const DenseMatrix< double > &jacobian, DenseMatrix< double > &inverse_jacobian) const
 One-d specialisation of function to calculate inverse of jacobian mapping. More...
 
template<>
double invert_jacobian (const DenseMatrix< double > &jacobian, DenseMatrix< double > &inverse_jacobian) const
 Two-d specialisation of function to calculate inverse of jacobian mapping. More...
 
template<>
double invert_jacobian (const DenseMatrix< double > &jacobian, DenseMatrix< double > &inverse_jacobian) const
 
template<>
void dJ_eulerian_dnodal_coordinates_templated_helper (const DenseMatrix< double > &jacobian, const DShape &dpsids, DenseMatrix< double > &djacobian_dX) const
 
template<>
void dJ_eulerian_dnodal_coordinates_templated_helper (const DenseMatrix< double > &jacobian, const DShape &dpsids, DenseMatrix< double > &djacobian_dX) const
 
template<>
void dJ_eulerian_dnodal_coordinates_templated_helper (const DenseMatrix< double > &jacobian, const DShape &dpsids, DenseMatrix< double > &djacobian_dX) const
 
template<>
void dJ_eulerian_dnodal_coordinates_templated_helper (const DenseMatrix< double > &jacobian, const DShape &dpsids, DenseMatrix< double > &djacobian_dX) const
 
template<>
void d_dshape_eulerian_dnodal_coordinates_templated_helper (const double &det_jacobian, const DenseMatrix< double > &jacobian, const DenseMatrix< double > &djacobian_dX, const DenseMatrix< double > &inverse_jacobian, const DShape &dpsids, RankFourTensor< double > &d_dpsidx_dX) const
 
template<>
void d_dshape_eulerian_dnodal_coordinates_templated_helper (const double &det_jacobian, const DenseMatrix< double > &jacobian, const DenseMatrix< double > &djacobian_dX, const DenseMatrix< double > &inverse_jacobian, const DShape &dpsids, RankFourTensor< double > &d_dpsidx_dX) const
 
template<>
void d_dshape_eulerian_dnodal_coordinates_templated_helper (const double &det_jacobian, const DenseMatrix< double > &jacobian, const DenseMatrix< double > &djacobian_dX, const DenseMatrix< double > &inverse_jacobian, const DShape &dpsids, RankFourTensor< double > &d_dpsidx_dX) const
 
template<>
void d_dshape_eulerian_dnodal_coordinates_templated_helper (const double &det_jacobian, const DenseMatrix< double > &jacobian, const DenseMatrix< double > &djacobian_dX, const DenseMatrix< double > &inverse_jacobian, const DShape &dpsids, RankFourTensor< double > &d_dpsidx_dX) const
 
template<>
void transform_second_derivatives_template (const DenseMatrix< double > &jacobian, const DenseMatrix< double > &inverse_jacobian, const DenseMatrix< double > &jacobian2, DShape &dbasis, DShape &d2basis) const
 
template<>
void transform_second_derivatives_template (const DenseMatrix< double > &jacobian, const DenseMatrix< double > &inverse_jacobian, const DenseMatrix< double > &jacobian2, DShape &dbasis, DShape &d2basis) const
 
template<>
void transform_second_derivatives_diagonal (const DenseMatrix< double > &jacobian, const DenseMatrix< double > &inverse_jacobian, const DenseMatrix< double > &jacobian2, DShape &dbasis, DShape &d2basis) const
 
template<>
void transform_second_derivatives_diagonal (const DenseMatrix< double > &jacobian, const DenseMatrix< double > &inverse_jacobian, const DenseMatrix< double > &jacobian2, DShape &dbasis, DShape &d2basis) const
 
- Protected Member Functions inherited from oomph::GeneralisedElement
unsigned add_internal_data (Data *const &data_pt, const bool &fd=true)
 
bool internal_data_fd (const unsigned &i) const
 
void exclude_internal_data_fd (const unsigned &i)
 
void include_internal_data_fd (const unsigned &i)
 
void clear_global_eqn_numbers ()
 
void add_global_eqn_numbers (std::deque< unsigned long > const &global_eqn_numbers, std::deque< double * > const &global_dof_pt)
 
virtual void assign_internal_and_external_local_eqn_numbers (const bool &store_local_dof_pt)
 
virtual void assign_additional_local_eqn_numbers ()
 
int internal_local_eqn (const unsigned &i, const unsigned &j) const
 
int external_local_eqn (const unsigned &i, const unsigned &j)
 
void fill_in_jacobian_from_internal_by_fd (Vector< double > &residuals, DenseMatrix< double > &jacobian, const bool &fd_all_data=false)
 
void fill_in_jacobian_from_internal_by_fd (DenseMatrix< double > &jacobian, const bool &fd_all_data=false)
 
void fill_in_jacobian_from_external_by_fd (Vector< double > &residuals, DenseMatrix< double > &jacobian, const bool &fd_all_data=false)
 
void fill_in_jacobian_from_external_by_fd (DenseMatrix< double > &jacobian, const bool &fd_all_data=false)
 
virtual void update_before_internal_fd ()
 
virtual void reset_after_internal_fd ()
 
virtual void update_in_internal_fd (const unsigned &i)
 
virtual void reset_in_internal_fd (const unsigned &i)
 
virtual void update_before_external_fd ()
 
virtual void reset_after_external_fd ()
 
virtual void update_in_external_fd (const unsigned &i)
 
virtual void reset_in_external_fd (const unsigned &i)
 
virtual void fill_in_contribution_to_mass_matrix (Vector< double > &residuals, DenseMatrix< double > &mass_matrix)
 
virtual void fill_in_contribution_to_jacobian_and_mass_matrix (Vector< double > &residuals, DenseMatrix< double > &jacobian, DenseMatrix< double > &mass_matrix)
 
virtual void fill_in_contribution_to_dresiduals_dparameter (double *const &parameter_pt, Vector< double > &dres_dparam)
 
virtual void fill_in_contribution_to_djacobian_dparameter (double *const &parameter_pt, Vector< double > &dres_dparam, DenseMatrix< double > &djac_dparam)
 
virtual void fill_in_contribution_to_djacobian_and_dmass_matrix_dparameter (double *const &parameter_pt, Vector< double > &dres_dparam, DenseMatrix< double > &djac_dparam, DenseMatrix< double > &dmass_matrix_dparam)
 
virtual void fill_in_contribution_to_hessian_vector_products (Vector< double > const &Y, DenseMatrix< double > const &C, DenseMatrix< double > &product)
 
virtual void fill_in_contribution_to_inner_products (Vector< std::pair< unsigned, unsigned >> const &history_index, Vector< double > &inner_product)
 
virtual void fill_in_contribution_to_inner_product_vectors (Vector< unsigned > const &history_index, Vector< Vector< double >> &inner_product_vector)
 

Private Attributes

SourceFctPt Solid_body_force_fct_pt
 Pointer to solid body force function. More...
 
SourceFctPt Fluid_body_force_fct_pt
 Pointer to fluid source function. More...
 
MassSourceFctPt Mass_source_fct_pt
 Pointer to the mass source function. More...
 
doubleYoungs_modulus_pt
 Pointer to the nondim Young's modulus. More...
 
doubleNu_pt
 Pointer to Poisson's ratio. More...
 
doubleLambda_sq_pt
 Timescale ratio (non-dim. density) More...
 
doubleDensity_ratio_pt
 Density ratio. More...
 
doublePermeability_pt
 permeability More...
 
doublePermeability_ratio_pt
 
doubleAlpha_pt
 Alpha – the biot parameter. More...
 
doublePorosity_pt
 Porosity. More...
 
bool Darcy_is_switched_off
 Boolean to record that darcy has been switched off. More...
 

Static Private Attributes

static double Default_youngs_modulus_value
 
static double Default_lambda_sq_value = 1.0
 Static default value for timescale ratio. More...
 
static double Default_density_ratio_value = 1.0
 Static default value for the density ratio. More...
 
static double Default_permeability_value = 1.0
 
static double Default_permeability_ratio_value
 
static double Default_alpha_value = 1.0
 Static default value for alpha, the biot parameter. More...
 
static double Default_porosity_value = 1.0
 Static default value for the porosity. More...
 

Additional Inherited Members

- Static Public Attributes inherited from oomph::FiniteElement
static double Tolerance_for_singular_jacobian = 1.0e-16
 Tolerance below which the jacobian is considered singular. More...
 
static bool Accept_negative_jacobian = false
 
static bool Suppress_output_while_checking_for_inverted_elements
 
- Static Public Attributes inherited from oomph::GeneralisedElement
static bool Suppress_warning_about_repeated_internal_data
 
static bool Suppress_warning_about_repeated_external_data = true
 
static double Default_fd_jacobian_step = 1.0e-8
 
- Protected Attributes inherited from oomph::FiniteElement
MacroElementMacro_elem_pt
 Pointer to the element's macro element (NULL by default) More...
 
- Protected Attributes inherited from oomph::GeomObject
unsigned NLagrangian
 Number of Lagrangian (intrinsic) coordinates. More...
 
unsigned Ndim
 Number of Eulerian coordinates. More...
 
TimeStepperGeom_object_time_stepper_pt
 
- Static Protected Attributes inherited from oomph::FiniteElement
static const unsigned Default_Initial_Nvalue = 0
 Default value for the number of values at a node. More...
 
static const double Node_location_tolerance = 1.0e-14
 
static const unsigned N2deriv [] = {0, 1, 3, 6}
 
- Static Protected Attributes inherited from oomph::GeneralisedElement
static DenseMatrix< doubleDummy_matrix
 
static std::deque< double * > Dof_pt_deque
 

Detailed Description

Class implementing the generic maths of the axisym poroelasticity equations: axisym linear elasticity coupled with axisym Darcy equations (using Raviart-Thomas elements with both edge and internal degrees of freedom) including inertia in both.

Member Typedef Documentation

◆ MassSourceFctPt

typedef void(* oomph::AxisymmetricPoroelasticityEquations::MassSourceFctPt) (const double &time, const Vector< double > &x, double &f)

Mass source function pointer typedef.

◆ SourceFctPt

typedef void(* oomph::AxisymmetricPoroelasticityEquations::SourceFctPt) (const double &time, const Vector< double > &x, Vector< double > &f)

Source function pointer typedef.

Constructor & Destructor Documentation

◆ AxisymmetricPoroelasticityEquations()

oomph::AxisymmetricPoroelasticityEquations::AxisymmetricPoroelasticityEquations ( )
inline

Constructor.

69  Nu_pt(0),
77  {
78  }
static double Default_lambda_sq_value
Static default value for timescale ratio.
Definition: axisym_poroelasticity_elements.h:1365
static double Default_youngs_modulus_value
Definition: axisym_poroelasticity_elements.h:1362
double * Lambda_sq_pt
Timescale ratio (non-dim. density)
Definition: axisym_poroelasticity_elements.h:1335
static double Default_porosity_value
Static default value for the porosity.
Definition: axisym_poroelasticity_elements.h:1383
double * Alpha_pt
Alpha – the biot parameter.
Definition: axisym_poroelasticity_elements.h:1348
double * Nu_pt
Pointer to Poisson's ratio.
Definition: axisym_poroelasticity_elements.h:1332
double * Porosity_pt
Porosity.
Definition: axisym_poroelasticity_elements.h:1351
SourceFctPt Fluid_body_force_fct_pt
Pointer to fluid source function.
Definition: axisym_poroelasticity_elements.h:1323
static double Default_permeability_value
Definition: axisym_poroelasticity_elements.h:1372
static double Default_permeability_ratio_value
Definition: axisym_poroelasticity_elements.h:1377
MassSourceFctPt Mass_source_fct_pt
Pointer to the mass source function.
Definition: axisym_poroelasticity_elements.h:1326
double * Permeability_pt
permeability
Definition: axisym_poroelasticity_elements.h:1341
double * Youngs_modulus_pt
Pointer to the nondim Young's modulus.
Definition: axisym_poroelasticity_elements.h:1329
static double Default_density_ratio_value
Static default value for the density ratio.
Definition: axisym_poroelasticity_elements.h:1368
bool Darcy_is_switched_off
Boolean to record that darcy has been switched off.
Definition: axisym_poroelasticity_elements.h:1354
SourceFctPt Solid_body_force_fct_pt
Pointer to solid body force function.
Definition: axisym_poroelasticity_elements.h:1320
static double Default_alpha_value
Static default value for alpha, the biot parameter.
Definition: axisym_poroelasticity_elements.h:1380
double * Permeability_ratio_pt
Definition: axisym_poroelasticity_elements.h:1345
double * Density_ratio_pt
Density ratio.
Definition: axisym_poroelasticity_elements.h:1338

Member Function Documentation

◆ alpha()

const double& oomph::AxisymmetricPoroelasticityEquations::alpha ( ) const
inline

Access function for alpha, the Biot parameter.

172  {
173  return *Alpha_pt;
174  }

References Alpha_pt.

Referenced by fill_in_generic_residual_contribution().

◆ alpha_pt()

double*& oomph::AxisymmetricPoroelasticityEquations::alpha_pt ( )
inline

Access function for pointer to alpha, the Biot parameter.

178  {
179  return Alpha_pt;
180  }

References Alpha_pt.

◆ compute_error() [1/2]

void oomph::AxisymmetricPoroelasticityEquations::compute_error ( std::ostream &  outfile,
FiniteElement::SteadyExactSolutionFctPt  exact_soln_pt,
Vector< double > &  error,
Vector< double > &  norm 
)
virtual

Compute the error between the FE solution and the exact solution using the H(div) norm for q and L^2 norm for p

Compute the error between the FE solution and the exact solution using the H(div) norm for q and L^2 norm for u and p

Reimplemented from oomph::FiniteElement.

313  {
314  for (unsigned i = 0; i < 3; i++)
315  {
316  error[i] = 0.0;
317  norm[i] = 0.0;
318  }
319 
320  // Vector of local coordinates
321  Vector<double> s(2);
322 
323  // Vector for coordinates
324  Vector<double> x(2);
325 
326  // Set the value of n_intpt
327  unsigned n_intpt = this->integral_pt()->nweight();
328 
329  outfile << "ZONE" << std::endl;
330 
331  // Exact solution Vector
332  Vector<double> exact_soln(13);
333 
334  // Loop over the integration points
335  for (unsigned ipt = 0; ipt < n_intpt; ipt++)
336  {
337  // Assign values of s
338  for (unsigned i = 0; i < 2; i++)
339  {
340  s[i] = this->integral_pt()->knot(ipt, i);
341  }
342 
343  // Get the integral weight
344  double w = this->integral_pt()->weight(ipt);
345 
346  // Get jacobian of mapping
347  double J = this->J_eulerian(s);
348 
349  // Premultiply the weights and the Jacobian
350  double W = w * J;
351 
352  // Get x position as Vector
353  this->interpolated_x(s, x);
354 
355  // Get exact solution at this point
356  (*exact_soln_pt)(x, exact_soln);
357 
358  // Displacement error
359  for (unsigned i = 0; i < 2; i++)
360  {
361  norm[0] += exact_soln[i] * exact_soln[i] * W;
362  // Error due to q_i
363  error[0] += (exact_soln[i] - this->interpolated_u(s, i)) *
364  (exact_soln[i] - this->interpolated_u(s, i)) * W;
365  }
366 
367  // Flux error
368  for (unsigned i = 0; i < 2; i++)
369  {
370  norm[1] += exact_soln[2 + i] * exact_soln[2 + i] * W;
371  // Error due to q_i
372  error[1] += (exact_soln[2 + i] - this->interpolated_q(s, i)) *
373  (exact_soln[2 + i] - this->interpolated_q(s, i)) * W;
374  }
375 
376  // Flux divergence error
377  norm[1] += exact_soln[2 * 2] * exact_soln[2 * 2] * W;
378  error[1] += (exact_soln[2 * 2] - interpolated_div_q(s)) *
379  (exact_soln[2 * 2] - interpolated_div_q(s)) * W;
380 
381  // Pressure error
382  norm[2] += exact_soln[2 * 2 + 1] * exact_soln[2 * 2 + 1] * W;
383  error[2] += (exact_soln[2 * 2 + 1] - this->interpolated_p(s)) *
384  (exact_soln[2 * 2 + 1] - this->interpolated_p(s)) * W;
385 
386  // Output x,y,[z]
387  for (unsigned i = 0; i < 2; i++)
388  {
389  outfile << x[i] << " ";
390  }
391 
392  // Output u_1_error,u_2_error,...
393  for (unsigned i = 0; i < 2; i++)
394  {
395  outfile << exact_soln[i] - this->interpolated_u(s, i) << " ";
396  }
397 
398  // Output q_1_error,q_2_error,...
399  for (unsigned i = 0; i < 2; i++)
400  {
401  outfile << exact_soln[2 + i] - this->interpolated_q(s, i) << " ";
402  }
403 
404  // Output p_error
405  outfile << exact_soln[2 * 2 + 1] - this->interpolated_p(s) << " ";
406 
407  outfile << std::endl;
408  }
409  }
int i
Definition: BiCGSTAB_step_by_step.cpp:9
JacobiRotation< float > J
Definition: Jacobi_makeJacobi.cpp:3
RowVector3d w
Definition: Matrix_resize_int.cpp:3
void interpolated_u(const Vector< double > &s, Vector< double > &disp) const
Calculate the FE representation of u.
Definition: axisym_poroelasticity_elements.h:576
void interpolated_q(const Vector< double > &s, Vector< double > &q) const
Calculate the FE representation of q.
Definition: axisym_poroelasticity_elements.h:689
void interpolated_div_q(const Vector< double > &s, double &div_q) const
Calculate the FE representation of div u.
Definition: axisym_poroelasticity_elements.h:782
void interpolated_p(const Vector< double > &s, double &p) const
Calculate the FE representation of p.
Definition: axisym_poroelasticity_elements.h:847
virtual double interpolated_x(const Vector< double > &s, const unsigned &i) const
Return FE interpolated coordinate x[i] at local coordinate s.
Definition: elements.cc:3962
Integral *const & integral_pt() const
Return the pointer to the integration scheme (const version)
Definition: elements.h:1963
virtual double J_eulerian(const Vector< double > &s) const
Definition: elements.cc:4103
virtual double knot(const unsigned &i, const unsigned &j) const =0
Return local coordinate s[j] of i-th integration point.
virtual unsigned nweight() const =0
Return the number of integration points of the scheme.
virtual double weight(const unsigned &i) const =0
Return weight of i-th integration point.
RealScalar s
Definition: level1_cplx_impl.h:130
void exact_soln(const double &time, const Vector< double > &x, Vector< double > &soln)
Definition: unstructured_two_d_curved.cc:301
int error
Definition: calibrate.py:297
@ W
Definition: quadtree.h:63
list x
Definition: plotDoE.py:28

References calibrate::error, ProblemParameters::exact_soln(), i, oomph::FiniteElement::integral_pt(), interpolated_div_q(), interpolated_p(), interpolated_q(), interpolated_u(), oomph::FiniteElement::interpolated_x(), J, oomph::FiniteElement::J_eulerian(), oomph::Integral::knot(), oomph::Integral::nweight(), s, w, oomph::QuadTreeNames::W, oomph::Integral::weight(), and plotDoE::x.

◆ compute_error() [2/2]

void oomph::AxisymmetricPoroelasticityEquations::compute_error ( std::ostream &  outfile,
FiniteElement::UnsteadyExactSolutionFctPt  exact_soln_pt,
const double time,
Vector< double > &  error,
Vector< double > &  norm 
)
virtual

Compute the error between the FE solution and the exact solution using the H(div) norm for q and L^2 norm for p. Unsteady version

Compute the error between the FE solution and the exact solution using the H(div) norm for u and L^2 norm for p. Unsteady version

Reimplemented from oomph::FiniteElement.

421  {
422  for (unsigned i = 0; i < 3; i++)
423  {
424  error[i] = 0.0;
425  norm[i] = 0.0;
426  }
427 
428  // Vector of local coordinates
429  Vector<double> s(2);
430 
431  // Vector for coordinates
432  Vector<double> x(2);
433 
434  // Set the value of n_intpt
435  unsigned n_intpt = this->integral_pt()->nweight();
436 
437  outfile << "ZONE" << std::endl;
438 
439  // Exact solution Vector
440  Vector<double> exact_soln(13);
441 
442  // Loop over the integration points
443  for (unsigned ipt = 0; ipt < n_intpt; ipt++)
444  {
445  // Assign values of s
446  for (unsigned i = 0; i < 2; i++)
447  {
448  s[i] = this->integral_pt()->knot(ipt, i);
449  }
450 
451  // Get the integral weight
452  double w = this->integral_pt()->weight(ipt);
453 
454  // Get jacobian of mapping
455  double J = this->J_eulerian(s);
456 
457  // Premultiply the weights and the Jacobian
458  double W = w * J;
459 
460  // Get x position as Vector
461  this->interpolated_x(s, x);
462 
463  // Get exact solution at this point
464  (*exact_soln_pt)(time, x, exact_soln);
465 
466  // Displacement error
467  for (unsigned i = 0; i < 2; i++)
468  {
469  norm[0] += exact_soln[i] * exact_soln[i] * W;
470  // Error due to q_i
471  error[0] += (exact_soln[i] - this->interpolated_u(s, i)) *
472  (exact_soln[i] - this->interpolated_u(s, i)) * W;
473  }
474 
475  // Flux error
476  for (unsigned i = 0; i < 2; i++)
477  {
478  norm[1] += exact_soln[2 + i] * exact_soln[2 + i] * W;
479  // Error due to q_i
480  error[1] += (exact_soln[2 + i] - this->interpolated_q(s, i)) *
481  (exact_soln[2 + i] - this->interpolated_q(s, i)) * W;
482  }
483 
484  // Flux divergence error
485  norm[1] += exact_soln[2 * 2] * exact_soln[2 * 2] * W;
486  error[1] += (exact_soln[2 * 2] - interpolated_div_q(s)) *
487  (exact_soln[2 * 2] - interpolated_div_q(s)) * W;
488 
489  // Pressure error
490  norm[2] += exact_soln[2 * 2 + 1] * exact_soln[2 * 2 + 1] * W;
491  error[2] += (exact_soln[2 * 2 + 1] - this->interpolated_p(s)) *
492  (exact_soln[2 * 2 + 1] - this->interpolated_p(s)) * W;
493 
494  // Output x,y,[z]
495  for (unsigned i = 0; i < 2; i++)
496  {
497  outfile << x[i] << " ";
498  }
499 
500  // Output u_1_error,u_2_error,...
501  for (unsigned i = 0; i < 2; i++)
502  {
503  outfile << exact_soln[i] - this->interpolated_u(s, i) << " ";
504  }
505 
506  // Output q_1_error,q_2_error,...
507  for (unsigned i = 0; i < 2; i++)
508  {
509  outfile << exact_soln[2 + i] - this->interpolated_q(s, i) << " ";
510  }
511 
512  // Output p_error
513  outfile << exact_soln[2 * 2 + 1] - this->interpolated_p(s) << " ";
514 
515  outfile << std::endl;
516  }
517  }

References calibrate::error, ProblemParameters::exact_soln(), i, oomph::FiniteElement::integral_pt(), interpolated_div_q(), interpolated_p(), interpolated_q(), interpolated_u(), oomph::FiniteElement::interpolated_x(), J, oomph::FiniteElement::J_eulerian(), oomph::Integral::knot(), oomph::Integral::nweight(), s, w, oomph::QuadTreeNames::W, oomph::Integral::weight(), and plotDoE::x.

◆ d2u_dt2()

double oomph::AxisymmetricPoroelasticityEquations::d2u_dt2 ( const unsigned n,
const unsigned i 
) const
inline

d^2u/dt^2 at local node n

913  {
914  // Get the timestepper
915  TimeStepper* time_stepper_pt = node_pt(n)->time_stepper_pt();
916 
917  // Storage for the derivative - initialise to 0
918  double d2u_dt2 = 0.0;
919 
920  // If we are doing an unsteady solve then calculate the derivative
921  if (!time_stepper_pt->is_steady())
922  {
923  // Get the nodal index
924  const unsigned u_nodal_index = u_index_axisym_poroelasticity(i);
925 
926  // Get the number of values required to represent history
927  const unsigned n_time = time_stepper_pt->ntstorage();
928 
929  // Loop over history values
930  for (unsigned t = 0; t < n_time; t++)
931  {
932  // Add the contribution to the derivative
933  d2u_dt2 +=
934  time_stepper_pt->weight(2, t) * nodal_value(t, n, u_nodal_index);
935  }
936  }
937 
938  return d2u_dt2;
939  }
const unsigned n
Definition: CG3DPackingUnitTest.cpp:11
virtual unsigned u_index_axisym_poroelasticity(const unsigned &j) const =0
Return the nodal index of the j-th solid displacement unknown.
double d2u_dt2(const unsigned &n, const unsigned &i) const
d^2u/dt^2 at local node n
Definition: axisym_poroelasticity_elements.h:912
TimeStepper *& time_stepper_pt()
Return the pointer to the timestepper.
Definition: nodes.h:238
Node *& node_pt(const unsigned &n)
Return a pointer to the local node n.
Definition: elements.h:2175
double nodal_value(const unsigned &n, const unsigned &i) const
Definition: elements.h:2593
TimeStepper *& time_stepper_pt()
Definition: geom_objects.h:192
unsigned ntstorage() const
Definition: timesteppers.h:601
virtual double weight(const unsigned &i, const unsigned &j) const
Access function for j-th weight for the i-th derivative.
Definition: timesteppers.h:594
bool is_steady() const
Definition: timesteppers.h:389
t
Definition: plotPSD.py:36

References i, oomph::TimeStepper::is_steady(), n, oomph::FiniteElement::nodal_value(), oomph::FiniteElement::node_pt(), oomph::TimeStepper::ntstorage(), plotPSD::t, oomph::GeomObject::time_stepper_pt(), oomph::Data::time_stepper_pt(), u_index_axisym_poroelasticity(), and oomph::TimeStepper::weight().

Referenced by fill_in_generic_residual_contribution().

◆ darcy_is_switched_off()

bool oomph::AxisymmetricPoroelasticityEquations::darcy_is_switched_off ( )
inline

Is Darcy flow switched off?

1009  {
1010  return Darcy_is_switched_off;
1011  }

References Darcy_is_switched_off.

◆ density_ratio()

const double& oomph::AxisymmetricPoroelasticityEquations::density_ratio ( ) const
inline

Access function for the density ratio (fluid to solid)

131  {
132  return *Density_ratio_pt;
133  }

References Density_ratio_pt.

Referenced by fill_in_generic_residual_contribution().

◆ density_ratio_pt()

double*& oomph::AxisymmetricPoroelasticityEquations::density_ratio_pt ( )
inline

Access function for pointer to the density ratio (fluid to solid)

137  {
138  return Density_ratio_pt;
139  }

References Density_ratio_pt.

◆ dq_edge_dt()

double oomph::AxisymmetricPoroelasticityEquations::dq_edge_dt ( const unsigned n) const
inline

dq_edge/dt for the n-th edge degree of freedom

943  {
944  unsigned node_num = q_edge_node_number(n);
945 
946  // get the timestepper
947  TimeStepper* time_stepper_pt = node_pt(node_num)->time_stepper_pt();
948 
949  // storage for the derivative - initialise to 0
950  double dq_dt = 0.0;
951 
952  // if we are doing an unsteady solve then calculate the derivative
953  if (!time_stepper_pt->is_steady())
954  {
955  // get the number of values required to represent history
956  const unsigned n_time = time_stepper_pt->ntstorage();
957 
958  // loop over history values
959  for (unsigned t = 0; t < n_time; t++)
960  {
961  // add the contribution to the derivative
962  dq_dt += time_stepper_pt->weight(1, t) * q_edge(t, n);
963  }
964  }
965 
966  return dq_dt;
967  }
virtual unsigned q_edge_node_number(const unsigned &j) const =0
Return the number of the node where the jth edge unknown is stored.
virtual double q_edge(const unsigned &j) const =0
Return the values of the j-th edge (flux) degree of freedom.

References oomph::TimeStepper::is_steady(), n, oomph::FiniteElement::node_pt(), oomph::TimeStepper::ntstorage(), q_edge(), q_edge_node_number(), plotPSD::t, oomph::GeomObject::time_stepper_pt(), oomph::Data::time_stepper_pt(), and oomph::TimeStepper::weight().

Referenced by fill_in_generic_residual_contribution().

◆ dq_internal_dt()

double oomph::AxisymmetricPoroelasticityEquations::dq_internal_dt ( const unsigned n) const
inline

dq_internal/dt for the n-th internal degree of freedom

971  {
972  // get the internal data index for q
973  unsigned internal_index = q_internal_index();
974 
975  // get the timestepper
976  TimeStepper* time_stepper_pt =
977  internal_data_pt(internal_index)->time_stepper_pt();
978 
979  // storage for the derivative - initialise to 0
980  double dq_dt = 0.0;
981 
982  // if we are doing an unsteady solve then calculate the derivative
983  if (!time_stepper_pt->is_steady())
984  {
985  // get the number of values required to represent history
986  const unsigned n_time = time_stepper_pt->ntstorage();
987 
988  // loop over history values
989  for (unsigned t = 0; t < n_time; t++)
990  {
991  // add the contribution to the derivative
992  dq_dt += time_stepper_pt->weight(1, t) * q_internal(t, n);
993  }
994  }
995 
996  return dq_dt;
997  }
virtual unsigned q_internal_index() const =0
virtual double q_internal(const unsigned &j) const =0
Return the values of the j-th internal degree of freedom.
Data *& internal_data_pt(const unsigned &i)
Return a pointer to i-th internal data object.
Definition: elements.h:622

References oomph::GeneralisedElement::internal_data_pt(), oomph::TimeStepper::is_steady(), n, oomph::TimeStepper::ntstorage(), q_internal(), q_internal_index(), plotPSD::t, oomph::GeomObject::time_stepper_pt(), oomph::Data::time_stepper_pt(), and oomph::TimeStepper::weight().

Referenced by fill_in_generic_residual_contribution().

◆ du_dt()

double oomph::AxisymmetricPoroelasticityEquations::du_dt ( const unsigned n,
const unsigned i 
) const
inline

du/dt at local node n

883  {
884  // Get the timestepper
885  TimeStepper* time_stepper_pt = node_pt(n)->time_stepper_pt();
886 
887  // Storage for the derivative - initialise to 0
888  double du_dt = 0.0;
889 
890  // If we are doing an unsteady solve then calculate the derivative
891  if (!time_stepper_pt->is_steady())
892  {
893  // Get the nodal index
894  const unsigned u_nodal_index = u_index_axisym_poroelasticity(i);
895 
896  // Get the number of values required to represent history
897  const unsigned n_time = time_stepper_pt->ntstorage();
898 
899  // Loop over history values
900  for (unsigned t = 0; t < n_time; t++)
901  {
902  // Add the contribution to the derivative
903  du_dt +=
904  time_stepper_pt->weight(1, t) * nodal_value(t, n, u_nodal_index);
905  }
906  }
907 
908  return du_dt;
909  }
double du_dt(const unsigned &n, const unsigned &i) const
du/dt at local node n
Definition: axisym_poroelasticity_elements.h:882

References i, oomph::TimeStepper::is_steady(), n, oomph::FiniteElement::nodal_value(), oomph::FiniteElement::node_pt(), oomph::TimeStepper::ntstorage(), plotPSD::t, oomph::GeomObject::time_stepper_pt(), oomph::Data::time_stepper_pt(), u_index_axisym_poroelasticity(), and oomph::TimeStepper::weight().

Referenced by fill_in_generic_residual_contribution(), interpolated_div_du_dt(), interpolated_du_dt(), output(), point_output_data(), and scalar_value_paraview().

◆ edge_flux_interpolation_point()

virtual Vector<double> oomph::AxisymmetricPoroelasticityEquations::edge_flux_interpolation_point ( const unsigned edge,
const unsigned j 
) const
pure virtual

Returns the local coordinate of the jth flux_interpolation point along the specified edge

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ edge_flux_interpolation_point_global()

virtual void oomph::AxisymmetricPoroelasticityEquations::edge_flux_interpolation_point_global ( const unsigned edge,
const unsigned j,
Vector< double > &  x 
) const
pure virtual

Compute the global coordinates of the jth flux_interpolation point along an edge

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ face_index_of_edge()

virtual unsigned oomph::AxisymmetricPoroelasticityEquations::face_index_of_edge ( const unsigned j) const
pure virtual

Return the face index associated with specified edge.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ face_index_of_q_edge_basis_fct()

virtual unsigned oomph::AxisymmetricPoroelasticityEquations::face_index_of_q_edge_basis_fct ( const unsigned j) const
pure virtual

Return the face index associated with j-th edge flux degree of freedom.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ face_local_coordinate_of_flux_interpolation_point()

virtual void oomph::AxisymmetricPoroelasticityEquations::face_local_coordinate_of_flux_interpolation_point ( const unsigned edge,
const unsigned n,
Vector< double > &  s 
) const
pure virtual

Compute the face element coordinates of the nth flux interpolation point along an edge

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ fill_in_contribution_to_jacobian()

void oomph::AxisymmetricPoroelasticityEquations::fill_in_contribution_to_jacobian ( Vector< double > &  residuals,
DenseMatrix< double > &  jacobian 
)
inlinevirtual

Fill in the Jacobian matrix for the Newton method.

Reimplemented from oomph::GeneralisedElement.

471  {
472  this->fill_in_generic_residual_contribution(residuals, jacobian, 1);
473  }
virtual void fill_in_generic_residual_contribution(Vector< double > &residuals, DenseMatrix< double > &jacobian, bool flag)
Fill in residuals and, if flag==true, jacobian.
Definition: axisym_poroelasticity_elements.cc:523

References fill_in_generic_residual_contribution().

◆ fill_in_contribution_to_residuals()

void oomph::AxisymmetricPoroelasticityEquations::fill_in_contribution_to_residuals ( Vector< double > &  residuals)
inlinevirtual

Fill in contribution to residuals for the Darcy equations.

Reimplemented from oomph::GeneralisedElement.

463  {
465  residuals, GeneralisedElement::Dummy_matrix, 0);
466  }
static DenseMatrix< double > Dummy_matrix
Definition: elements.h:227

References oomph::GeneralisedElement::Dummy_matrix, and fill_in_generic_residual_contribution().

◆ fill_in_generic_residual_contribution()

void oomph::AxisymmetricPoroelasticityEquations::fill_in_generic_residual_contribution ( Vector< double > &  residuals,
DenseMatrix< double > &  jacobian,
bool  flag 
)
protectedvirtual

Fill in residuals and, if flag==true, jacobian.

526  {
527  // Get the number of geometric nodes, total number of basis functions,
528  // and number of edges basis functions
529  const unsigned n_node = nnode();
530  const unsigned n_q_basis = nq_basis();
531  const unsigned n_q_basis_edge = nq_basis_edge();
532  const unsigned n_p_basis = np_basis();
533 
534  // Storage for the geometric and computational bases and the test functions
535  Shape psi(n_node), u_basis(n_node), u_test(n_node), q_basis(n_q_basis, 2),
536  q_test(n_q_basis, 2), p_basis(n_p_basis), p_test(n_p_basis),
537  div_q_basis_ds(n_q_basis), div_q_test_ds(n_q_basis);
538 
539  DShape dpsidx(n_node, 2), du_basis_dx(n_node, 2), du_test_dx(n_node, 2);
540 
541  // Get the number of integration points
542  unsigned n_intpt = integral_pt()->nweight();
543 
544  // Storage for the local coordinates
545  Vector<double> s(2);
546 
547  // Storage for the elasticity source function
548  Vector<double> f_solid(2);
549 
550  // Storage for the source function
551  Vector<double> f_fluid(2);
552 
553  // Storage for the mass source function
554  double mass_source_local = 0.0;
555 
556  // Get elastic parameters
557  double nu_local = this->nu();
558  double youngs_modulus_local = this->youngs_modulus();
559 
560  // Obtain Lame parameters from Young's modulus and Poisson's ratio
561  double lambda = youngs_modulus_local * nu_local / (1.0 + nu_local) /
562  (1.0 - 2.0 * nu_local);
563 
564  double mu = youngs_modulus_local / 2.0 / (1.0 + nu_local);
565 
566  // Storage for Lambda_sq
567  double lambda_sq = this->lambda_sq();
568 
569  // Get the value of permeability
570  double local_permeability = this->permeability();
571 
572  // Ratio of the material's permeability to the permeability used
573  // to non-dimensionalise the equations
574  double local_permeability_ratio = this->permeability_ratio();
575 
576  // Get the value of alpha
577  double alpha = this->alpha();
578 
579  // Get the value of the porosity
580  double porosity = this->porosity();
581 
582  // Get the density ratio
583  double density_ratio = this->density_ratio();
584 
585  // Precompute the ratio of fluid density to combined density
586  double rho_f_over_rho =
587  density_ratio / (1.0 + porosity * (density_ratio - 1.0));
588 
589  // Get continuous time from timestepper of first node
590  double time = node_pt(0)->time_stepper_pt()->time_pt()->time();
591 
592  // Local equation and unknown numbers
593  int local_eqn = 0, local_unknown = 0;
594 
595  // Loop over the integration points
596  for (unsigned ipt = 0; ipt < n_intpt; ipt++)
597  {
598  // Find the local coordinates at the integration point
599  for (unsigned i = 0; i < 2; i++)
600  {
601  s[i] = integral_pt()->knot(ipt, i);
602  }
603 
604  // Get the weight of the intetgration point
605  double w = integral_pt()->weight(ipt);
606 
607  // Call the basis functions and test functions and get the
608  // (geometric) jacobian of the current element
609  double J = shape_basis_test_local_at_knot(ipt,
610  psi,
611  dpsidx,
612  u_basis,
613  u_test,
614  du_basis_dx,
615  du_test_dx,
616  q_basis,
617  q_test,
618  p_basis,
619  p_test,
620  div_q_basis_ds,
621  div_q_test_ds);
622 
623  // Storage for interpolated values
624  Vector<double> interpolated_x(2, 0.0);
625  Vector<double> interpolated_u(2, 0.0);
626  DenseMatrix<double> interpolated_du_dx(2, 2, 0.0);
627  double interpolated_div_du_dt_dx = 0.0;
628  double interpolated_du_r_dt = 0.0;
629  Vector<double> interpolated_d2u_dt2(2, 0.0);
630  Vector<double> interpolated_q(2, 0.0);
631  double interpolated_div_q_ds = 0.0;
632  Vector<double> interpolated_dq_dt(2, 0.0);
633  double interpolated_p = 0.0;
634 
635  // loop over geometric basis functions to find interpolated x
636  for (unsigned l = 0; l < n_node; l++)
637  {
638  // Loop over the geometric basis functions
639  for (unsigned i = 0; i < 2; i++)
640  {
641  interpolated_x[i] += nodal_position(l, i) * psi(l);
642  interpolated_d2u_dt2[i] += this->d2u_dt2(l, i) * u_basis(l);
643 
644  // Get the nodal displacements
645  const double u_value =
647  interpolated_u[i] += u_value * u_basis(l);
648 
649  // Loop over derivative directions
650  for (unsigned j = 0; j < 2; j++)
651  {
652  interpolated_du_dx(i, j) += u_value * du_basis_dx(l, j);
653  }
654 
655  // divergence of the time derivative of the solid displacement
656  interpolated_div_du_dt_dx += this->du_dt(l, i) * du_basis_dx(l, i);
657  }
658 
659  // r-component of the solid velocity
660  interpolated_du_r_dt += du_dt(l, 0) * u_basis(l);
661  }
662 
663  // loop over the nodes and use the vector basis functions to find the
664  // interpolated flux and its time derivative
665  for (unsigned i = 0; i < 2; i++)
666  {
667  // Loop over the edge basis vectors
668  for (unsigned l = 0; l < n_q_basis_edge; l++)
669  {
670  interpolated_q[i] += q_edge(l) * q_basis(l, i);
671  interpolated_dq_dt[i] += dq_edge_dt(l) * q_basis(l, i);
672  }
673  // Loop over the internal basis vectors
674  for (unsigned l = n_q_basis_edge; l < n_q_basis; l++)
675  {
676  interpolated_q[i] += q_internal(l - n_q_basis_edge) * q_basis(l, i);
677  interpolated_dq_dt[i] +=
678  dq_internal_dt(l - n_q_basis_edge) * q_basis(l, i);
679  }
680  }
681 
682  // loop over the pressure basis and find the interpolated pressure
683  for (unsigned l = 0; l < n_p_basis; l++)
684  {
685  interpolated_p += p_value(l) * p_basis(l);
686  }
687 
688  // loop over the q edge divergence basis and the q internal divergence
689  // basis to find interpolated div q
690  for (unsigned l = 0; l < n_q_basis_edge; l++)
691  {
692  interpolated_div_q_ds += q_edge(l) * div_q_basis_ds(l);
693  }
694  for (unsigned l = n_q_basis_edge; l < n_q_basis; l++)
695  {
696  interpolated_div_q_ds +=
697  q_internal(l - n_q_basis_edge) * div_q_basis_ds(l);
698  }
699 
700  // Get the solid body force
701  this->solid_body_force(time, interpolated_x, f_solid);
702 
703  // Get the fluid nody force
704  this->fluid_body_force(time, interpolated_x, f_fluid);
705 
706  // Get the mass source function
707  this->mass_source(time, interpolated_x, mass_source_local);
708 
709  double r = interpolated_x[0];
710 
711  // Linear elasticity:
712  //-------------------
713 
714  double u_r = interpolated_u[0];
715  double du_r_dr = interpolated_du_dx(0, 0);
716  double du_r_dz = interpolated_du_dx(0, 1);
717  double du_z_dr = interpolated_du_dx(1, 0);
718  double du_z_dz = interpolated_du_dx(1, 1);
719 
720  // Storage for terms of Jacobian
721  double G_r = 0, G_z = 0;
722 
723  for (unsigned l = 0; l < n_node; l++)
724  {
725  for (unsigned a = 0; a < 2; a++)
726  {
727  local_eqn =
729 
730  if (local_eqn >= 0)
731  {
732  residuals[local_eqn] +=
733  (lambda_sq *
734  (interpolated_d2u_dt2[a] +
735  rho_f_over_rho * local_permeability * interpolated_dq_dt[a]) -
736  f_solid[a]) *
737  u_test(l) * r * w * J;
738 
739  // r-equation
740  if (a == 0)
741  {
742  residuals[local_eqn] +=
743  (mu * (2.0 * du_r_dr * du_test_dx(l, 0) +
744  du_test_dx(l, 1) * (du_r_dz + du_z_dr) +
745  2.0 * u_test(l) / pow(r, 2) * (u_r)) +
746  (lambda * (du_r_dr + u_r / r + du_z_dz) -
747  alpha * interpolated_p) *
748  (du_test_dx(l, 0) + u_test(l) / r)) *
749  r * w * J;
750  }
751  else if (a == 1)
752  {
753  residuals[local_eqn] +=
754  (mu * (du_test_dx(l, 0) * (du_r_dz + du_z_dr) +
755  2.0 * du_z_dz * du_test_dx(l, 1)) +
756  (lambda * (du_r_dr + u_r / r + du_z_dz) -
757  alpha * interpolated_p) *
758  du_test_dx(l, 1)) *
759  r * w * J;
760  }
761  // error: a should be 0 or 1
762  else
763  {
764  throw OomphLibError("a should equal 0 or 1",
767  }
768 
769  // Jacobian entries
770  if (flag)
771  {
772  // d(u_eqn_l,a)/d(U_l2,c)
773  for (unsigned l2 = 0; l2 < n_node; l2++)
774  {
775  if (a == 0)
776  {
777  G_r =
778  (mu * (2.0 * du_basis_dx(l2, 0) * du_test_dx(l, 0) +
779  du_test_dx(l, 1) * du_basis_dx(l2, 1) +
780  2 * u_test(l) / pow(r, 2) * u_basis(l2)) +
781  (lambda * (du_basis_dx(l2, 0) + u_basis(l2) / r)) *
782  (du_test_dx(l, 0) + u_test(l) / r) +
783  lambda_sq * node_pt(l2)->time_stepper_pt()->weight(2, 0) *
784  u_basis(l2) * u_test(l)) *
785  r * w * J;
786 
787  G_z = (mu * du_test_dx(l, 1) * du_basis_dx(l2, 0) +
788  lambda * du_basis_dx(l2, 1) *
789  (du_test_dx(l, 0) + u_test(l) / r)) *
790  r * w * J;
791  }
792  else if (a == 1)
793  {
794  G_r = (mu * du_test_dx(l, 0) * du_basis_dx(l2, 1) +
795  lambda * (du_basis_dx(l2, 0) + u_basis(l2) / r) *
796  du_test_dx(l, 1)) *
797  r * w * J;
798  G_z =
799  (mu * (du_test_dx(l, 0) * du_basis_dx(l2, 0) +
800  2.0 * du_basis_dx(l2, 1) * du_test_dx(l, 1)) +
801  lambda * du_basis_dx(l2, 1) * du_test_dx(l, 1) +
802  lambda_sq * node_pt(l2)->time_stepper_pt()->weight(2, 0) *
803  u_basis(l2) * u_test(l)) *
804  r * w * J;
805  }
806 
807  for (unsigned c = 0; c < 2; c++)
808  {
809  local_unknown =
811  if (local_unknown >= 0)
812  {
813  if (c == 0)
814  {
815  jacobian(local_eqn, local_unknown) += G_r;
816  }
817  else if (c == 1)
818  {
819  jacobian(local_eqn, local_unknown) += G_z;
820  }
821  }
822  }
823  }
824 
825  // d(u_eqn_l,a)/d(Q_l2)
826  for (unsigned l2 = 0; l2 < n_q_basis; l2++)
827  {
828  TimeStepper* timestepper_pt = 0;
829 
830  if (l2 < n_q_basis_edge)
831  {
832  local_unknown = q_edge_local_eqn(l2);
833  timestepper_pt =
835  }
836  else // n_q_basis_edge <= l < n_basis
837  {
838  local_unknown = q_internal_local_eqn(l2 - n_q_basis_edge);
839  timestepper_pt = this->internal_data_pt(q_internal_index())
840  ->time_stepper_pt();
841  }
842 
843  if (local_unknown >= 0)
844  {
845  jacobian(local_eqn, local_unknown) +=
846  lambda_sq * rho_f_over_rho * local_permeability *
847  timestepper_pt->weight(1, 0) * q_basis(l2, a) * u_test(l) *
848  r * w * J;
849  }
850  }
851 
852  // d(u_eqn_l,a)/d(P_l2)
853  for (unsigned l2 = 0; l2 < n_p_basis; l2++)
854  {
855  local_unknown = p_local_eqn(l2);
856  if (local_unknown >= 0)
857  {
858  if (a == 0)
859  {
860  jacobian(local_eqn, local_unknown) -=
861  alpha * p_basis(l2) * (du_test_dx(l, 0) + u_test(l) / r) *
862  r * w * J;
863  }
864  else if (a == 1)
865  {
866  jacobian(local_eqn, local_unknown) -=
867  alpha * p_basis(l2) * du_test_dx(l, 1) * r * w * J;
868  }
869  }
870  }
871  } // End of Jacobian entries
872  } // End of if not boundary condition
873  } // End of loop over dimensions
874  } // End of loop over u test functions
875 
876 
877  // Darcy:
878  //-------
879 
880  // Loop over the test functions
881  for (unsigned l = 0; l < n_q_basis; l++)
882  {
883  if (l < n_q_basis_edge)
884  {
885  local_eqn = q_edge_local_eqn(l);
886  }
887  else // n_q_basis_edge <= l < n_basis
888  {
889  local_eqn = q_internal_local_eqn(l - n_q_basis_edge);
890  }
891 
892  // If it's not a boundary condition
893  if (local_eqn >= 0)
894  {
895  for (unsigned i = 0; i < 2; i++)
896  {
897  residuals[local_eqn] +=
898  (rho_f_over_rho * lambda_sq *
899  (interpolated_d2u_dt2[i] +
900  (local_permeability / porosity) * interpolated_dq_dt[i]) +
901  interpolated_q[i] / local_permeability_ratio -
902  rho_f_over_rho * f_fluid[i]) *
903  q_test(l, i) * r * w * J;
904  }
905 
906  // deliberately no jacobian factor in this integral
907  residuals[local_eqn] -= interpolated_p * div_q_test_ds(l) * r * w;
908 
909  // deliberately no r factor in this integral
910  residuals[local_eqn] -= interpolated_p * q_test(l, 0) * w * J;
911 
912  // Jacobian entries
913  if (flag)
914  {
915  // d(q_eqn_l)/d(U_l2,c)
916  for (unsigned l2 = 0; l2 < n_node; l2++)
917  {
918  for (unsigned c = 0; c < 2; c++)
919  {
920  local_unknown =
922  if (local_unknown >= 0)
923  {
924  jacobian(local_eqn, local_unknown) +=
925  rho_f_over_rho * lambda_sq *
926  this->node_pt(l2)->time_stepper_pt()->weight(2, 0) *
927  u_basis(l2) * q_test(l, c) * r * w * J;
928  }
929  }
930  }
931 
932  // d(q_eqn_l)/d(Q_l2)
933  for (unsigned l2 = 0; l2 < n_q_basis; l2++)
934  {
935  TimeStepper* timestepper_pt = 0;
936 
937  if (l2 < n_q_basis_edge)
938  {
939  local_unknown = q_edge_local_eqn(l2);
940  timestepper_pt =
942  }
943  else // n_q_basis_edge <= l < n_basis
944  {
945  local_unknown = q_internal_local_eqn(l2 - n_q_basis_edge);
946  timestepper_pt =
948  }
949 
950  if (local_unknown >= 0)
951  {
952  for (unsigned c = 0; c < 2; c++)
953  {
954  jacobian(local_eqn, local_unknown) +=
955  q_basis(l2, c) * q_test(l, c) *
956  (1.0 / local_permeability_ratio +
957  rho_f_over_rho * lambda_sq * local_permeability *
958  timestepper_pt->weight(1, 0) / porosity) *
959  r * w * J;
960  }
961  }
962  }
963 
964  // d(q_eqn_l)/d(P_l2)
965  for (unsigned l2 = 0; l2 < n_p_basis; l2++)
966  {
967  local_unknown = p_local_eqn(l2);
968 
969  if (local_unknown >= 0)
970  {
971  jacobian(local_eqn, local_unknown) -=
972  p_basis(l2) * (div_q_test_ds(l) * r + q_test(l, 0) * J) * w;
973  }
974  }
975  } // End of Jacobian entries
976  } // End of if not boundary condition
977  } // End of loop over q test functions
978 
979  // loop over pressure test functions
980  for (unsigned l = 0; l < n_p_basis; l++)
981  {
982  // get the local equation number
983  local_eqn = p_local_eqn(l);
984 
985  // If it's not a boundary condition
986  if (local_eqn >= 0)
987  {
988  // solid divergence term
989  residuals[local_eqn] +=
990  alpha * interpolated_div_du_dt_dx * p_test(l) * r * w * J;
991  residuals[local_eqn] +=
992  alpha * interpolated_du_r_dt * p_test(l) * w * J;
993  // deliberately no jacobian factor in this integral
994  residuals[local_eqn] +=
995  local_permeability * interpolated_div_q_ds * p_test(l) * r * w;
996  // deliberately no r factor in this integral
997  residuals[local_eqn] +=
998  local_permeability * interpolated_q[0] * p_test(l) * w * J;
999  residuals[local_eqn] -= mass_source_local * p_test(l) * r * w * J;
1000 
1001  // Jacobian entries
1002  if (flag)
1003  {
1004  // d(p_eqn_l)/d(U_l2,c)
1005  for (unsigned l2 = 0; l2 < n_node; l2++)
1006  {
1007  for (unsigned c = 0; c < 2; c++)
1008  {
1009  local_unknown =
1011 
1012  if (local_unknown >= 0)
1013  {
1014  jacobian(local_eqn, local_unknown) +=
1015  alpha * this->node_pt(l2)->time_stepper_pt()->weight(1, 0) *
1016  du_basis_dx(l2, c) * p_test(l) * r * w * J;
1017 
1018  // Extra term due to cylindrical coordinate system
1019  if (c == 0)
1020  {
1021  jacobian(local_eqn, local_unknown) +=
1022  alpha *
1023  this->node_pt(l2)->time_stepper_pt()->weight(1, 0) *
1024  u_basis(l2) * p_test(l) * w * J;
1025  }
1026  }
1027  }
1028  }
1029 
1030  // d(p_eqn_l)/d(Q_l2)
1031  for (unsigned l2 = 0; l2 < n_q_basis; l2++)
1032  {
1033  if (l2 < n_q_basis_edge)
1034  {
1035  local_unknown = q_edge_local_eqn(l2);
1036  }
1037  else // n_q_basis_edge <= l < n_basis
1038  {
1039  local_unknown = q_internal_local_eqn(l2 - n_q_basis_edge);
1040  }
1041 
1042  if (local_unknown >= 0)
1043  {
1044  jacobian(local_eqn, local_unknown) +=
1045  (div_q_basis_ds(l2) * r + q_basis(l2, 0) * J) *
1046  local_permeability * p_test(l) * w;
1047  }
1048  }
1049  } // End of Jacobian entries
1050  } // End of if not boundary condition
1051  } // End of loop over p test functions
1052  } // End of loop over integration points
1053  }
cout<< "The eigenvalues of A are:"<< endl<< ces.eigenvalues()<< endl;cout<< "The matrix of eigenvectors, V, is:"<< endl<< ces.eigenvectors()<< endl<< endl;complex< float > lambda
Definition: ComplexEigenSolver_compute.cpp:9
void mass_source(const double &time, const Vector< double > &x, double &b) const
Definition: axisym_poroelasticity_elements.h:276
double dq_internal_dt(const unsigned &n) const
dq_internal/dt for the n-th internal degree of freedom
Definition: axisym_poroelasticity_elements.h:970
const double & porosity() const
Access function for the porosity.
Definition: axisym_poroelasticity_elements.h:183
virtual int q_edge_local_eqn(const unsigned &j) const =0
Return the equation number of the j-th edge (flux) degree of freedom.
const double & youngs_modulus() const
Definition: axisym_poroelasticity_elements.h:83
virtual int q_internal_local_eqn(const unsigned &j) const =0
Return the equation number of the j-th internal degree of freedom.
virtual 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 =0
const double & permeability_ratio() const
Definition: axisym_poroelasticity_elements.h:157
virtual unsigned np_basis() const =0
Return the total number of pressure basis functions.
virtual unsigned nq_basis() const
Return the total number of computational basis functions for q.
Definition: axisym_poroelasticity_elements.h:365
const double & density_ratio() const
Access function for the density ratio (fluid to solid)
Definition: axisym_poroelasticity_elements.h:130
const double & lambda_sq() const
Access function for timescale ratio (nondim density)
Definition: axisym_poroelasticity_elements.h:118
virtual unsigned nq_basis_edge() const =0
Return the number of edge basis functions for q.
virtual double p_value(const unsigned &j) const =0
Return the jth pressure value.
const double & permeability() const
Access function for the nondim permeability.
Definition: axisym_poroelasticity_elements.h:142
const double & alpha() const
Access function for alpha, the Biot parameter.
Definition: axisym_poroelasticity_elements.h:171
void fluid_body_force(const double &time, const Vector< double > &x, Vector< double > &b) const
Definition: axisym_poroelasticity_elements.h:254
void solid_body_force(const double &time, const Vector< double > &x, Vector< double > &b) const
Definition: axisym_poroelasticity_elements.h:232
const double & nu() const
Access function for Poisson's ratio.
Definition: axisym_poroelasticity_elements.h:96
double dq_edge_dt(const unsigned &n) const
dq_edge/dt for the n-th edge degree of freedom
Definition: axisym_poroelasticity_elements.h:942
virtual int p_local_eqn(const unsigned &j) const =0
Return the equation number of the j-th pressure degree of freedom.
int nodal_local_eqn(const unsigned &n, const unsigned &i) const
Definition: elements.h:1432
unsigned nnode() const
Return the number of nodes.
Definition: elements.h:2210
double nodal_position(const unsigned &n, const unsigned &i) const
Definition: elements.h:2317
double raw_nodal_value(const unsigned &n, const unsigned &i) const
Definition: elements.h:2576
Time *const & time_pt() const
Access function for the pointer to time (const version)
Definition: timesteppers.h:572
double & time()
Return the current value of the continuous time.
Definition: timesteppers.h:123
const Scalar * a
Definition: level2_cplx_impl.h:32
EIGEN_STRONG_INLINE EIGEN_DEVICE_FUNC bfloat16 pow(const bfloat16 &a, const bfloat16 &b)
Definition: BFloat16.h:625
std::complex< double > mu
Definition: time_harmonic_fourier_decomposed_linear_elasticity/cylinder/cylinder.cc:52
double u_r(const double &time, const Vector< double > &x)
Calculate the time dependent form of the r-component of displacement.
Definition: axisym_linear_elasticity/cylinder/cylinder.cc:130
r
Definition: UniformPSDSelfTest.py:20
int c
Definition: calibrate.py:100
#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 a, alpha(), calibrate::c, d2u_dt2(), density_ratio(), dq_edge_dt(), dq_internal_dt(), du_dt(), fluid_body_force(), i, oomph::FiniteElement::integral_pt(), oomph::GeneralisedElement::internal_data_pt(), interpolated_p(), interpolated_q(), interpolated_u(), oomph::FiniteElement::interpolated_x(), J, j, oomph::Integral::knot(), lambda, lambda_sq(), mass_source(), Global_Parameters::mu, oomph::FiniteElement::nnode(), oomph::FiniteElement::nodal_local_eqn(), oomph::FiniteElement::nodal_position(), oomph::FiniteElement::node_pt(), np_basis(), nq_basis(), nq_basis_edge(), nu(), oomph::Integral::nweight(), OOMPH_CURRENT_FUNCTION, OOMPH_EXCEPTION_LOCATION, p_local_eqn(), p_value(), permeability(), permeability_ratio(), porosity(), Eigen::bfloat16_impl::pow(), q_edge(), q_edge_local_eqn(), q_edge_node_number(), q_internal(), q_internal_index(), q_internal_local_eqn(), UniformPSDSelfTest::r, oomph::FiniteElement::raw_nodal_value(), s, shape_basis_test_local_at_knot(), solid_body_force(), oomph::Time::time(), oomph::TimeStepper::time_pt(), oomph::Data::time_stepper_pt(), u_index_axisym_poroelasticity(), Global_Parameters::u_r(), w, oomph::Integral::weight(), oomph::TimeStepper::weight(), and youngs_modulus().

Referenced by fill_in_contribution_to_jacobian(), and fill_in_contribution_to_residuals().

◆ fluid_body_force()

void oomph::AxisymmetricPoroelasticityEquations::fluid_body_force ( const double time,
const Vector< double > &  x,
Vector< double > &  b 
) const
inline

Indirect access to the fluid body force function - returns 0 if no forcing function has been set

257  {
258  // If no function has been set, return zero vector
259  if (Fluid_body_force_fct_pt == 0)
260  {
261  // Get spatial dimension of element
262  unsigned n = dim();
263  for (unsigned i = 0; i < n; i++)
264  {
265  b[i] = 0.0;
266  }
267  }
268  else
269  {
270  (*Fluid_body_force_fct_pt)(time, x, b);
271  }
272  }
Scalar * b
Definition: benchVecAdd.cpp:17
unsigned dim() const
Definition: elements.h:2611

References b, oomph::FiniteElement::dim(), Fluid_body_force_fct_pt, i, n, and plotDoE::x.

Referenced by fill_in_generic_residual_contribution().

◆ fluid_body_force_fct_pt() [1/2]

SourceFctPt& oomph::AxisymmetricPoroelasticityEquations::fluid_body_force_fct_pt ( )
inline

Access function: Pointer to fluid force function.

208  {
210  }

References Fluid_body_force_fct_pt.

◆ fluid_body_force_fct_pt() [2/2]

SourceFctPt oomph::AxisymmetricPoroelasticityEquations::fluid_body_force_fct_pt ( ) const
inline

Access function: Pointer to fluid force function (const version)

214  {
216  }

References Fluid_body_force_fct_pt.

◆ get_div_q_basis_local()

virtual void oomph::AxisymmetricPoroelasticityEquations::get_div_q_basis_local ( const Vector< double > &  s,
Shape div_q_basis_ds 
) const
pure virtual

Compute the local form of the q basis and dbasis/ds at local coordinate s

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >, oomph::TAxisymmetricPoroelasticityElement< ORDER >, and oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by interpolated_div_q().

◆ get_p_basis()

virtual void oomph::AxisymmetricPoroelasticityEquations::get_p_basis ( const Vector< double > &  s,
Shape p_basis 
) const
pure virtual

◆ get_q_basis()

void oomph::AxisymmetricPoroelasticityEquations::get_q_basis ( const Vector< double > &  s,
Shape q_basis 
) const
inline

Compute the transformed basis at local coordinate s.

387  {
388  const unsigned n_node = this->nnode();
389  Shape psi(n_node, 2);
390  const unsigned n_q_basis = this->nq_basis();
391  Shape q_basis_local(n_q_basis, 2);
392  this->get_q_basis_local(s, q_basis_local);
393  (void)this->transform_basis(s, q_basis_local, psi, q_basis);
394  }
double transform_basis(const Vector< double > &s, const Shape &q_basis_local, Shape &psi, DShape &dpsi, Shape &q_basis) const
Definition: axisym_poroelasticity_elements.cc:80
virtual void get_q_basis_local(const Vector< double > &s, Shape &q_basis) const =0
Comute the local form of the q basis at local coordinate s.

References get_q_basis_local(), oomph::FiniteElement::nnode(), nq_basis(), and transform_basis().

Referenced by interpolated_q().

◆ get_q_basis_local()

virtual void oomph::AxisymmetricPoroelasticityEquations::get_q_basis_local ( const Vector< double > &  s,
Shape q_basis 
) const
pure virtual

◆ get_Z2_flux()

void oomph::AxisymmetricPoroelasticityEquations::get_Z2_flux ( const Vector< double > &  s,
Vector< double > &  flux 
)
inlinevirtual

Z2 flux (use Darcy flux)

Implements oomph::ElementWithZ2ErrorEstimator.

1276  {
1277  interpolated_q(s, flux);
1278  }
void flux(const double &time, const Vector< double > &x, double &flux)
Get flux applied along boundary x=0.
Definition: pretend_melt.cc:59

References ProblemParameters::flux(), interpolated_q(), and s.

◆ interpolated_div_du_dt()

double oomph::AxisymmetricPoroelasticityEquations::interpolated_div_du_dt ( const Vector< double > &  s,
Vector< double > &  div_dudt_components 
) const
inline

Calculate the FE representation of the divergence of the skeleton velocity, div(du/dt), and its components: 1/r diff(r*du_r/dt,r) and diff(du_z/dt,z).

481  {
482  // Find number of nodes
483  unsigned n_node = nnode();
484 
485  // Local shape function
486  Shape psi(n_node);
487  DShape dpsidx(n_node, 2);
488 
489  // Find values of shape function
490  dshape_eulerian(s, psi, dpsidx);
491 
492  // Local coordinates
493  double r = interpolated_x(s, 0);
494 
495  // Assemble the "cartesian-like" contributions
496  for (unsigned i = 0; i < 2; i++)
497  {
498  // Initialise
499  div_dudt_components[i] = 0.0;
500 
501  // Loop over the local nodes and sum the "cartesian-like"
502  // contributions
503  for (unsigned l = 0; l < n_node; l++)
504  {
505  div_dudt_components[i] += du_dt(l, i) * dpsidx(l, i);
506  }
507  }
508 
509  // Radial skeleton veloc
510  double dur_dt = 0.0;
511  for (unsigned l = 0; l < n_node; l++)
512  {
513  dur_dt += du_dt(l, 0) * psi(l);
514  }
515 
516  // Add geometric component to radial contribution
517  div_dudt_components[0] += dur_dt / r;
518 
519  // Return sum
520  return div_dudt_components[0] + div_dudt_components[1];
521  }
double dshape_eulerian(const Vector< double > &s, Shape &psi, DShape &dpsidx) const
Definition: elements.cc:3298

References oomph::FiniteElement::dshape_eulerian(), du_dt(), i, oomph::FiniteElement::interpolated_x(), oomph::FiniteElement::nnode(), UniformPSDSelfTest::r, and s.

Referenced by point_output_data().

◆ interpolated_div_q() [1/2]

double oomph::AxisymmetricPoroelasticityEquations::interpolated_div_q ( const Vector< double > &  s) const
inline

Calculate the FE representation of div q and return it.

835  {
836  // Temporary storage for div q
837  double div_q = 0;
838 
839  // Get the intepolated divergence
840  interpolated_div_q(s, div_q);
841 
842  // Return it
843  return div_q;
844  }

References interpolated_div_q(), and s.

◆ interpolated_div_q() [2/2]

void oomph::AxisymmetricPoroelasticityEquations::interpolated_div_q ( const Vector< double > &  s,
double div_q 
) const
inline

Calculate the FE representation of div u.

783  {
784  // Zero the divergence
785  div_q = 0;
786 
787  // Get the number of nodes, q basis function, and q edge basis functions
788  unsigned n_node = nnode();
789  const unsigned n_q_basis = nq_basis();
790  const unsigned n_q_basis_edge = nq_basis_edge();
791 
792  // Storage for the divergence basis
793  Shape div_q_basis_ds(n_q_basis);
794 
795  // Storage for the geometric basis and it's derivatives
796  Shape psi(n_node);
797  DShape dpsi(n_node, 2);
798 
799  // Call the geometric shape functions and their derivatives
800  this->dshape_local(s, psi, dpsi);
801 
802  // Storage for the inverse of the geometric jacobian (just so we can call
803  // the local to eulerian mapping)
804  DenseMatrix<double> inverse_jacobian(2);
805 
806  // Get the determinant of the geometric mapping
807  double det = local_to_eulerian_mapping(dpsi, inverse_jacobian);
808 
809  // Get the divergence basis (wrt local coords) at local coords s
810  get_div_q_basis_local(s, div_q_basis_ds);
811 
812  // Add the contribution to the divergence from the edge basis functions
813  for (unsigned l = 0; l < n_q_basis_edge; l++)
814  {
815  div_q += 1.0 / det * div_q_basis_ds(l) * q_edge(l);
816  }
817 
818  // Add the contribution to the divergence from the internal basis
819  // functions
820  for (unsigned l = n_q_basis_edge; l < n_q_basis; l++)
821  {
822  div_q += 1.0 / det * div_q_basis_ds(l) * q_internal(l - n_q_basis_edge);
823  }
824 
825  // Extra term due to cylindrical coords
826  if (std::abs(interpolated_x(s, 0)) > 1e-10)
827  {
828  div_q += interpolated_q(s, 0) / interpolated_x(s, 0);
829  }
830  }
AnnoyingScalar abs(const AnnoyingScalar &x)
Definition: AnnoyingScalar.h:135
Array< double, 1, 3 > e(1./3., 0.5, 2.)
virtual void get_div_q_basis_local(const Vector< double > &s, Shape &div_q_basis_ds) const =0
virtual double local_to_eulerian_mapping(const DShape &dpsids, DenseMatrix< double > &jacobian, DenseMatrix< double > &inverse_jacobian) const
Definition: elements.h:1508
virtual void dshape_local(const Vector< double > &s, Shape &psi, DShape &dpsids) const
Definition: elements.h:1981

References abs(), oomph::FiniteElement::dshape_local(), e(), get_div_q_basis_local(), interpolated_q(), oomph::FiniteElement::interpolated_x(), oomph::FiniteElement::local_to_eulerian_mapping(), oomph::FiniteElement::nnode(), nq_basis(), nq_basis_edge(), q_edge(), q_internal(), and s.

Referenced by compute_error(), interpolated_div_q(), output(), point_output_data(), and scalar_value_paraview().

◆ interpolated_div_u()

double oomph::AxisymmetricPoroelasticityEquations::interpolated_div_u ( const Vector< double > &  s,
Vector< double > &  div_u_components 
) const
inline

Calculate the FE representation of the divergence of the skeleton displ, div(u), and its components: 1/r diff(r*u_r,r) and diff(u_z,z).

529  {
530  // Find number of nodes
531  unsigned n_node = nnode();
532 
533  // Local shape function
534  Shape psi(n_node);
535  DShape dpsidx(n_node, 2);
536 
537  // Find values of shape function
538  dshape_eulerian(s, psi, dpsidx);
539 
540  // Local coordinates
541  double r = interpolated_x(s, 0);
542 
543  // Assemble the "cartesian-like" contributions
544  for (unsigned i = 0; i < 2; i++)
545  {
546  // Get nodal index at which i-th velocity is stored
547  unsigned u_nodal_index = u_index_axisym_poroelasticity(i);
548 
549  // Initialise
550  div_u_components[i] = 0.0;
551 
552  // Loop over the local nodes and sum the "cartesian-like"
553  // contributions
554  for (unsigned l = 0; l < n_node; l++)
555  {
556  div_u_components[i] += nodal_value(l, u_nodal_index) * dpsidx(l, i);
557  }
558  }
559 
560  // Radial skeleton displ
561  double ur = 0.0;
562  for (unsigned l = 0; l < n_node; l++)
563  {
564  ur += nodal_value(l, u_index_axisym_poroelasticity(0)) * psi(l);
565  }
566 
567  // Add geometric component to radial contribution
568  div_u_components[0] += ur / r;
569 
570  // Return sum
571  return div_u_components[0] + div_u_components[1];
572  }

References oomph::FiniteElement::dshape_eulerian(), i, oomph::FiniteElement::interpolated_x(), oomph::FiniteElement::nnode(), oomph::FiniteElement::nodal_value(), UniformPSDSelfTest::r, s, and u_index_axisym_poroelasticity().

Referenced by point_output_data().

◆ interpolated_du_dt()

void oomph::AxisymmetricPoroelasticityEquations::interpolated_du_dt ( const Vector< double > &  s,
Vector< double > &  du_dt 
) const
inline

Calculate the FE representation of du_dt.

665  {
666  // Find number of nodes
667  unsigned n_node = nnode();
668 
669  // Local shape function
670  Shape psi(n_node);
671 
672  // Find values of shape function
673  shape(s, psi);
674 
675  for (unsigned i = 0; i < 2; i++)
676  {
677  // Initialise value of u
678  du_dt[i] = 0.0;
679 
680  // Loop over the local nodes and sum
681  for (unsigned l = 0; l < n_node; l++)
682  {
683  du_dt[i] += this->du_dt(l, i) * psi[l];
684  }
685  }
686  }
virtual void shape(const Vector< double > &s, Shape &psi) const =0

References du_dt(), i, oomph::FiniteElement::nnode(), s, and oomph::FiniteElement::shape().

Referenced by output(), point_output_data(), and scalar_value_paraview().

◆ interpolated_p() [1/2]

double oomph::AxisymmetricPoroelasticityEquations::interpolated_p ( const Vector< double > &  s) const
inline

Calculate the FE representation of p and return it.

870  {
871  // Temporary storage for p
872  double p = 0;
873 
874  // Get the interpolated pressure
875  interpolated_p(s, p);
876 
877  // Return it
878  return p;
879  }
float * p
Definition: Tutorial_Map_using.cpp:9

References interpolated_p(), p, and s.

◆ interpolated_p() [2/2]

void oomph::AxisymmetricPoroelasticityEquations::interpolated_p ( const Vector< double > &  s,
double p 
) const
inline

Calculate the FE representation of p.

848  {
849  // Get the number of p basis functions
850  unsigned n_p_basis = np_basis();
851 
852  // Storage for the p basis
853  Shape p_basis(n_p_basis);
854 
855  // Call the p basis
856  get_p_basis(s, p_basis);
857 
858  // Zero the pressure
859  p = 0;
860 
861  // Add the contribution to the pressure from each basis function
862  for (unsigned l = 0; l < n_p_basis; l++)
863  {
864  p += p_value(l) * p_basis(l);
865  }
866  }
virtual void get_p_basis(const Vector< double > &s, Shape &p_basis) const =0
Compute the pressure basis.

References get_p_basis(), np_basis(), p, p_value(), and s.

Referenced by compute_error(), fill_in_generic_residual_contribution(), interpolated_p(), output(), point_output_data(), and scalar_value_paraview().

◆ interpolated_q() [1/4]

double oomph::AxisymmetricPoroelasticityEquations::interpolated_q ( const unsigned t,
const Vector< double > &  s,
const unsigned  i 
) const
inline

Calculate the FE representation of the i-th component of q at time level t (t=0: current)

760  {
761  unsigned n_q_basis = nq_basis();
762  unsigned n_q_basis_edge = nq_basis_edge();
763 
764  Shape q_basis(n_q_basis, 2);
765 
766  get_q_basis(s, q_basis);
767  double q_i = 0.0;
768  for (unsigned l = 0; l < n_q_basis_edge; l++)
769  {
770  q_i += q_edge(t, l) * q_basis(l, i);
771  }
772  for (unsigned l = n_q_basis_edge; l < n_q_basis; l++)
773  {
774  q_i += q_internal(t, l - n_q_basis_edge) * q_basis(l, i);
775  }
776 
777  return q_i;
778  }
void get_q_basis(const Vector< double > &s, Shape &q_basis) const
Compute the transformed basis at local coordinate s.
Definition: axisym_poroelasticity_elements.h:386

References get_q_basis(), i, nq_basis(), nq_basis_edge(), q_edge(), q_internal(), s, and plotPSD::t.

◆ interpolated_q() [2/4]

void oomph::AxisymmetricPoroelasticityEquations::interpolated_q ( const unsigned t,
const Vector< double > &  s,
Vector< double > &  q 
) const
inline

Calculate the FE representation of q at time level t (t=0: current)

714  {
715  unsigned n_q_basis = nq_basis();
716  unsigned n_q_basis_edge = nq_basis_edge();
717  Shape q_basis(n_q_basis, 2);
718  get_q_basis(s, q_basis);
719  for (unsigned i = 0; i < 2; i++)
720  {
721  q[i] = 0.0;
722  for (unsigned l = 0; l < n_q_basis_edge; l++)
723  {
724  q[i] += q_edge(t, l) * q_basis(l, i);
725  }
726  for (unsigned l = n_q_basis_edge; l < n_q_basis; l++)
727  {
728  q[i] += q_internal(t, l - n_q_basis_edge) * q_basis(l, i);
729  }
730  }
731  }
EIGEN_DEVICE_FUNC const Scalar & q
Definition: SpecialFunctionsImpl.h:2019

References get_q_basis(), i, nq_basis(), nq_basis_edge(), Eigen::numext::q, q_edge(), q_internal(), s, and plotPSD::t.

◆ interpolated_q() [3/4]

double oomph::AxisymmetricPoroelasticityEquations::interpolated_q ( const Vector< double > &  s,
const unsigned  i 
) const
inline

Calculate the FE representation of the i-th component of q.

735  {
736  unsigned n_q_basis = nq_basis();
737  unsigned n_q_basis_edge = nq_basis_edge();
738 
739  Shape q_basis(n_q_basis, 2);
740 
741  get_q_basis(s, q_basis);
742  double q_i = 0.0;
743  for (unsigned l = 0; l < n_q_basis_edge; l++)
744  {
745  q_i += q_edge(l) * q_basis(l, i);
746  }
747  for (unsigned l = n_q_basis_edge; l < n_q_basis; l++)
748  {
749  q_i += q_internal(l - n_q_basis_edge) * q_basis(l, i);
750  }
751 
752  return q_i;
753  }

References get_q_basis(), i, nq_basis(), nq_basis_edge(), q_edge(), q_internal(), and s.

◆ interpolated_q() [4/4]

void oomph::AxisymmetricPoroelasticityEquations::interpolated_q ( const Vector< double > &  s,
Vector< double > &  q 
) const
inline

Calculate the FE representation of q.

690  {
691  unsigned n_q_basis = nq_basis();
692  unsigned n_q_basis_edge = nq_basis_edge();
693  Shape q_basis(n_q_basis, 2);
694  get_q_basis(s, q_basis);
695  for (unsigned i = 0; i < 2; i++)
696  {
697  q[i] = 0.0;
698  for (unsigned l = 0; l < n_q_basis_edge; l++)
699  {
700  q[i] += q_edge(l) * q_basis(l, i);
701  }
702  for (unsigned l = n_q_basis_edge; l < n_q_basis; l++)
703  {
704  q[i] += q_internal(l - n_q_basis_edge) * q_basis(l, i);
705  }
706  }
707  }

References get_q_basis(), i, nq_basis(), nq_basis_edge(), Eigen::numext::q, q_edge(), q_internal(), and s.

Referenced by compute_error(), fill_in_generic_residual_contribution(), get_Z2_flux(), interpolated_div_q(), output(), point_output_data(), and scalar_value_paraview().

◆ interpolated_u() [1/3]

double oomph::AxisymmetricPoroelasticityEquations::interpolated_u ( const unsigned t,
const Vector< double > &  s,
const unsigned i 
) const
inline

Calculate the FE representation of the i-th component of u at time level t (t=0: current)

636  {
637  // Find number of nodes
638  unsigned n_node = nnode();
639 
640  // Local shape function
641  Shape psi(n_node);
642 
643  // Find values of shape function
644  shape(s, psi);
645 
646  // Get nodal index at which i-th velocity is stored
647  unsigned u_nodal_index = u_index_axisym_poroelasticity(i);
648 
649  // Initialise value of u
650  double interpolated_u = 0.0;
651 
652  // Loop over the local nodes and sum
653  for (unsigned l = 0; l < n_node; l++)
654  {
655  interpolated_u += nodal_value(t, l, u_nodal_index) * psi[l];
656  }
657 
658  return (interpolated_u);
659  }

References i, interpolated_u(), oomph::FiniteElement::nnode(), oomph::FiniteElement::nodal_value(), s, oomph::FiniteElement::shape(), plotPSD::t, and u_index_axisym_poroelasticity().

◆ interpolated_u() [2/3]

double oomph::AxisymmetricPoroelasticityEquations::interpolated_u ( const Vector< double > &  s,
const unsigned i 
) const
inline

Calculate the FE representation of the i-th component of u.

605  {
606  // Find number of nodes
607  unsigned n_node = nnode();
608 
609  // Local shape function
610  Shape psi(n_node);
611 
612  // Find values of shape function
613  shape(s, psi);
614 
615  // Get nodal index at which i-th velocity is stored
616  unsigned u_nodal_index = u_index_axisym_poroelasticity(i);
617 
618  // Initialise value of u
619  double interpolated_u = 0.0;
620 
621  // Loop over the local nodes and sum
622  for (unsigned l = 0; l < n_node; l++)
623  {
624  interpolated_u += nodal_value(l, u_nodal_index) * psi[l];
625  }
626 
627  return (interpolated_u);
628  }

References i, interpolated_u(), oomph::FiniteElement::nnode(), oomph::FiniteElement::nodal_value(), s, oomph::FiniteElement::shape(), and u_index_axisym_poroelasticity().

◆ interpolated_u() [3/3]

void oomph::AxisymmetricPoroelasticityEquations::interpolated_u ( const Vector< double > &  s,
Vector< double > &  disp 
) const
inline

Calculate the FE representation of u.

577  {
578  // Find number of nodes
579  unsigned n_node = nnode();
580 
581  // Local shape function
582  Shape psi(n_node);
583 
584  // Find values of shape function
585  shape(s, psi);
586 
587  for (unsigned i = 0; i < 2; i++)
588  {
589  // Index at which the nodal value is stored
590  unsigned u_nodal_index = u_index_axisym_poroelasticity(i);
591 
592  // Initialise value of u
593  disp[i] = 0.0;
594 
595  // Loop over the local nodes and sum
596  for (unsigned l = 0; l < n_node; l++)
597  {
598  disp[i] += nodal_value(l, u_nodal_index) * psi[l];
599  }
600  }
601  }

References i, oomph::FiniteElement::nnode(), oomph::FiniteElement::nodal_value(), s, oomph::FiniteElement::shape(), and u_index_axisym_poroelasticity().

Referenced by compute_error(), fill_in_generic_residual_contribution(), interpolated_u(), output(), point_output_data(), and scalar_value_paraview().

◆ lambda_sq()

const double& oomph::AxisymmetricPoroelasticityEquations::lambda_sq ( ) const
inline

Access function for timescale ratio (nondim density)

119  {
120  return *Lambda_sq_pt;
121  }

References Lambda_sq_pt.

Referenced by fill_in_generic_residual_contribution().

◆ lambda_sq_pt()

double*& oomph::AxisymmetricPoroelasticityEquations::lambda_sq_pt ( )
inline

Access function for pointer to timescale ratio (nondim density)

125  {
126  return Lambda_sq_pt;
127  }

References Lambda_sq_pt.

◆ mass_source()

void oomph::AxisymmetricPoroelasticityEquations::mass_source ( const double time,
const Vector< double > &  x,
double b 
) const
inline

Indirect access to the mass source function - returns 0 if no mass source function has been set

279  {
280  // If no function has been set, return zero vector
281  if (Mass_source_fct_pt == 0)
282  {
283  b = 0.0;
284  }
285  else
286  {
287  (*Mass_source_fct_pt)(time, x, b);
288  }
289  }

References b, Mass_source_fct_pt, and plotDoE::x.

Referenced by fill_in_generic_residual_contribution().

◆ mass_source_fct_pt() [1/2]

MassSourceFctPt& oomph::AxisymmetricPoroelasticityEquations::mass_source_fct_pt ( )
inline

Access function: Pointer to mass source function.

220  {
221  return Mass_source_fct_pt;
222  }

References Mass_source_fct_pt.

◆ mass_source_fct_pt() [2/2]

MassSourceFctPt oomph::AxisymmetricPoroelasticityEquations::mass_source_fct_pt ( ) const
inline

Access function: Pointer to mass source function (const version)

226  {
227  return Mass_source_fct_pt;
228  }

References Mass_source_fct_pt.

◆ nedge_flux_interpolation_point()

virtual unsigned oomph::AxisymmetricPoroelasticityEquations::nedge_flux_interpolation_point ( ) const
pure virtual

Returns the number of flux_interpolation points along each edge of the element

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >, oomph::TAxisymmetricPoroelasticityElement< ORDER >, and oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ np_basis()

virtual unsigned oomph::AxisymmetricPoroelasticityEquations::np_basis ( ) const
pure virtual

◆ nq_basis()

virtual unsigned oomph::AxisymmetricPoroelasticityEquations::nq_basis ( ) const
inlinevirtual

Return the total number of computational basis functions for q.

366  {
367  return nq_basis_edge() + nq_basis_internal();
368  }
virtual unsigned nq_basis_internal() const =0
Return the number of internal basis functions for q.

References nq_basis_edge(), and nq_basis_internal().

Referenced by fill_in_generic_residual_contribution(), get_q_basis(), interpolated_div_q(), interpolated_q(), oomph::TAxisymmetricPoroelasticityElement< ORDER >::shape_basis_test_local(), and transform_basis().

◆ nq_basis_edge()

virtual unsigned oomph::AxisymmetricPoroelasticityEquations::nq_basis_edge ( ) const
pure virtual

◆ nq_basis_internal()

virtual unsigned oomph::AxisymmetricPoroelasticityEquations::nq_basis_internal ( ) const
pure virtual

◆ nscalar_paraview()

unsigned oomph::AxisymmetricPoroelasticityEquations::nscalar_paraview ( ) const
inlinevirtual

Number of scalars/fields output by this element. Reimplements broken virtual function in base class.

Reimplemented from oomph::FiniteElement.

1053  {
1054  return 8;
1055  }

◆ nu()

const double& oomph::AxisymmetricPoroelasticityEquations::nu ( ) const
inline

Access function for Poisson's ratio.

97  {
98 #ifdef PARANOID
99  if (Nu_pt == 0)
100  {
101  std::ostringstream error_message;
102  error_message << "No pointer to Poisson's ratio set. Please set one!\n";
103  throw OomphLibError(error_message.str(),
106  }
107 #endif
108  return *Nu_pt;
109  }

References Nu_pt, OOMPH_CURRENT_FUNCTION, and OOMPH_EXCEPTION_LOCATION.

Referenced by fill_in_generic_residual_contribution().

◆ nu_pt()

double*& oomph::AxisymmetricPoroelasticityEquations::nu_pt ( )
inline

Access function for pointer to Poisson's ratio.

113  {
114  return Nu_pt;
115  }

References Nu_pt.

◆ num_Z2_flux_terms()

unsigned oomph::AxisymmetricPoroelasticityEquations::num_Z2_flux_terms ( )
inlinevirtual

Number off flux terms for Z2 error estimator (use Darcy flux)

Implements oomph::ElementWithZ2ErrorEstimator.

1270  {
1271  return 2;
1272  }

◆ output() [1/2]

void oomph::AxisymmetricPoroelasticityEquations::output ( std::ostream &  outfile)
inlinevirtual

Output with default number of plot points.

Reimplemented from oomph::FiniteElement.

Reimplemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

1222  {
1223  unsigned nplot = 5;
1224  output(outfile, nplot);
1225  }
void output(std::ostream &outfile)
Output with default number of plot points.
Definition: axisym_poroelasticity_elements.h:1221

Referenced by oomph::TAxisymmetricPoroelasticityElement< ORDER >::output().

◆ output() [2/2]

void oomph::AxisymmetricPoroelasticityEquations::output ( std::ostream &  outfile,
const unsigned nplot 
)
virtual

Output FE representation of soln: x,y,u1,u2,div_q,p at Nplot^2 plot points

Output FE representation of soln: x,y,u1,u2,q1,q2,div_q,p at Nplot^2 plot points

Reimplemented from oomph::FiniteElement.

Reimplemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

147  {
148  // Vector of local coordinates
149  Vector<double> s(2);
150 
151  // Skeleton velocity
152  Vector<double> du_dt(2);
153 
154  // Tecplot header info
155  outfile << tecplot_zone_string(nplot);
156 
157  // Loop over plot points
158  unsigned num_plot_points = nplot_points(nplot);
159 
160  for (unsigned iplot = 0; iplot < num_plot_points; iplot++)
161  {
162  // Get local coordinates of plot point
163  get_s_plot(iplot, nplot, s);
164 
165  // Output the components of the position
166  for (unsigned i = 0; i < 2; i++)
167  {
168  outfile << interpolated_x(s, i) << " ";
169  }
170 
171  // Output the components of the FE representation of skeleton displ. at s
172  for (unsigned i = 0; i < 2; i++)
173  {
174  outfile << interpolated_u(s, i) << " "; // soln 0 and 1
175  }
176 
177  // Output the components of the FE representation of q at s
178  for (unsigned i = 0; i < 2; i++)
179  {
180  outfile << interpolated_q(s, i) << " "; // soln 2 and 3
181  }
182 
183  // Output FE representation of div u at s
184  outfile << interpolated_div_q(s) << " "; // soln 4
185 
186  // Output FE representation of p at s
187  outfile << interpolated_p(s) << " "; // soln 5
188 
189  // Skeleton velocity
191  outfile << du_dt[0] << " "; // soln 6
192  outfile << du_dt[1] << " "; // soln 7
193 
194  outfile << std::endl;
195  }
196 
197  // Write tecplot footer (e.g. FE connectivity lists)
198  this->write_tecplot_zone_footer(outfile, nplot);
199  }
void interpolated_du_dt(const Vector< double > &s, Vector< double > &du_dt) const
Calculate the FE representation of du_dt.
Definition: axisym_poroelasticity_elements.h:663
virtual std::string tecplot_zone_string(const unsigned &nplot) const
Definition: elements.h:3161
virtual void get_s_plot(const unsigned &i, const unsigned &nplot, Vector< double > &s, const bool &shifted_to_interior=false) const
Definition: elements.h:3148
virtual unsigned nplot_points(const unsigned &nplot) const
Definition: elements.h:3186
virtual void write_tecplot_zone_footer(std::ostream &outfile, const unsigned &nplot) const
Definition: elements.h:3174

References du_dt(), oomph::FiniteElement::get_s_plot(), i, interpolated_div_q(), interpolated_du_dt(), interpolated_p(), interpolated_q(), interpolated_u(), oomph::FiniteElement::interpolated_x(), oomph::FiniteElement::nplot_points(), s, oomph::FiniteElement::tecplot_zone_string(), and oomph::FiniteElement::write_tecplot_zone_footer().

◆ output_fct() [1/2]

void oomph::AxisymmetricPoroelasticityEquations::output_fct ( std::ostream &  outfile,
const unsigned nplot,
const double time,
FiniteElement::UnsteadyExactSolutionFctPt  exact_soln_pt 
)
virtual

Output FE representation of exact soln: x,y,u1,u2,div_q,p at Nplot^2 plot points. Unsteady version

Output FE representation of exact soln at Nplot^2 plot points. Unsteady version

Reimplemented from oomph::FiniteElement.

261  {
262  // Vector of local coordinates
263  Vector<double> s(2);
264 
265  // Vector for coordintes
266  Vector<double> x(2);
267 
268  // Tecplot header info
269  outfile << this->tecplot_zone_string(nplot);
270 
271  // Exact solution Vector
272  Vector<double> exact_soln(13);
273 
274  // Loop over plot points
275  unsigned num_plot_points = this->nplot_points(nplot);
276 
277  for (unsigned iplot = 0; iplot < num_plot_points; iplot++)
278  {
279  // Get local coordinates of plot point
280  this->get_s_plot(iplot, nplot, s);
281 
282  // Get x position as Vector
283  this->interpolated_x(s, x);
284 
285  // Get exact solution at this point
286  (*exact_soln_pt)(time, x, exact_soln);
287 
288  // Output
289  for (unsigned i = 0; i < 2; i++)
290  {
291  outfile << x[i] << " ";
292  }
293  for (unsigned i = 0; i < 13; i++)
294  {
295  outfile << exact_soln[i] << " ";
296  }
297  outfile << std::endl;
298  }
299 
300  // Write tecplot footer (e.g. FE connectivity lists)
301  this->write_tecplot_zone_footer(outfile, nplot);
302  }

References ProblemParameters::exact_soln(), oomph::FiniteElement::get_s_plot(), i, oomph::FiniteElement::interpolated_x(), oomph::FiniteElement::nplot_points(), s, oomph::FiniteElement::tecplot_zone_string(), oomph::FiniteElement::write_tecplot_zone_footer(), and plotDoE::x.

◆ output_fct() [2/2]

void oomph::AxisymmetricPoroelasticityEquations::output_fct ( std::ostream &  outfile,
const unsigned nplot,
FiniteElement::SteadyExactSolutionFctPt  exact_soln_pt 
)
virtual

Output FE representation of exact soln: x,y,u1,u2,div_q,p at Nplot^2 plot points

Output FE representation of exact soln at Nplot^2 plot points

Reimplemented from oomph::FiniteElement.

209  {
210  // Vector of local coordinates
211  Vector<double> s(2);
212 
213  // Vector for coordintes
214  Vector<double> x(2);
215 
216  // Tecplot header info
217  outfile << this->tecplot_zone_string(nplot);
218 
219  // Exact solution Vector
220  Vector<double> exact_soln(13);
221 
222  // Loop over plot points
223  unsigned num_plot_points = this->nplot_points(nplot);
224 
225  for (unsigned iplot = 0; iplot < num_plot_points; iplot++)
226  {
227  // Get local coordinates of plot point
228  this->get_s_plot(iplot, nplot, s);
229 
230  // Get x position as Vector
231  this->interpolated_x(s, x);
232 
233  // Get exact solution at this point
234  (*exact_soln_pt)(x, exact_soln);
235 
236  // Output
237  for (unsigned i = 0; i < 2; i++)
238  {
239  outfile << x[i] << " ";
240  }
241  for (unsigned i = 0; i < 13; i++)
242  {
243  outfile << exact_soln[i] << " ";
244  }
245  outfile << std::endl;
246  }
247 
248  // Write tecplot footer (e.g. FE connectivity lists)
249  this->write_tecplot_zone_footer(outfile, nplot);
250  }

References ProblemParameters::exact_soln(), oomph::FiniteElement::get_s_plot(), i, oomph::FiniteElement::interpolated_x(), oomph::FiniteElement::nplot_points(), s, oomph::FiniteElement::tecplot_zone_string(), oomph::FiniteElement::write_tecplot_zone_footer(), and plotDoE::x.

◆ output_with_projected_flux()

void oomph::AxisymmetricPoroelasticityEquations::output_with_projected_flux ( std::ostream &  outfile,
const unsigned nplot,
const Vector< double unit_normal 
)

Output incl. projection of fluxes into direction of the specified unit vector

◆ p_data_pt()

virtual Data* oomph::AxisymmetricPoroelasticityEquations::p_data_pt ( ) const
pure virtual

Return pointer to the Data object that stores the pressure values.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ p_local_eqn()

virtual int oomph::AxisymmetricPoroelasticityEquations::p_local_eqn ( const unsigned j) const
pure virtual

Return the equation number of the j-th pressure degree of freedom.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by fill_in_generic_residual_contribution().

◆ p_value()

virtual double oomph::AxisymmetricPoroelasticityEquations::p_value ( const unsigned j) const
pure virtual

Return the jth pressure value.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by fill_in_generic_residual_contribution(), and interpolated_p().

◆ permeability()

const double& oomph::AxisymmetricPoroelasticityEquations::permeability ( ) const
inline

Access function for the nondim permeability.

143  {
144  return *Permeability_pt;
145  }

References Permeability_pt.

Referenced by fill_in_generic_residual_contribution().

◆ permeability_pt()

double*& oomph::AxisymmetricPoroelasticityEquations::permeability_pt ( )
inline

Access function for pointer to the nondim permeability.

149  {
150  return Permeability_pt;
151  }

References Permeability_pt.

◆ permeability_ratio()

const double& oomph::AxisymmetricPoroelasticityEquations::permeability_ratio ( ) const
inline

Access function for the ratio of the material's actual permeability to the permeability used in the non-dimensionalisation of the equations

158  {
159  return *Permeability_ratio_pt;
160  }

References Permeability_ratio_pt.

Referenced by fill_in_generic_residual_contribution().

◆ permeability_ratio_pt()

double*& oomph::AxisymmetricPoroelasticityEquations::permeability_ratio_pt ( )
inline

Access function for pointer to ratio of the material's actual permeability to the permeability used in the non-dimensionalisation of the equations

166  {
167  return Permeability_ratio_pt;
168  }

References Permeability_ratio_pt.

◆ pin_p_value()

virtual void oomph::AxisymmetricPoroelasticityEquations::pin_p_value ( const unsigned j,
const double p 
)
pure virtual

Pin the jth pressure value and set it to p.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by switch_off_darcy().

◆ pin_q_edge_value()

virtual void oomph::AxisymmetricPoroelasticityEquations::pin_q_edge_value ( const unsigned j,
const double value 
)
pure virtual

Pin the j-th edge (flux) degree of freedom and set it to specified value.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by switch_off_darcy().

◆ pin_q_internal_value()

virtual void oomph::AxisymmetricPoroelasticityEquations::pin_q_internal_value ( const unsigned j,
const double value 
)
pure virtual

Pin the jth internal q value and set it to specified value.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by switch_off_darcy().

◆ point_output_data()

void oomph::AxisymmetricPoroelasticityEquations::point_output_data ( const Vector< double > &  s,
Vector< double > &  data 
)
inlinevirtual

Output solution in data vector at local cordinates s: r,z,u_r,u_z,q_r,q_z,div_q,p,durdt,duzdt

Reimplemented from oomph::FiniteElement.

1175  {
1176  // Output the components of the position
1177  for (unsigned i = 0; i < 2; i++)
1178  {
1179  data.push_back(interpolated_x(s, i));
1180  }
1181 
1182  // Output the components of the FE representation of u at s
1183  for (unsigned i = 0; i < 2; i++)
1184  {
1185  data.push_back(interpolated_u(s, i));
1186  }
1187 
1188  // Output the components of the FE representation of q at s
1189  for (unsigned i = 0; i < 2; i++)
1190  {
1191  data.push_back(interpolated_q(s, i));
1192  }
1193 
1194  // Output FE representation of div u at s
1195  data.push_back(interpolated_div_q(s));
1196 
1197  // Output FE representation of p at s
1198  data.push_back(interpolated_p(s));
1199 
1200  // Skeleton velocity
1201  Vector<double> du_dt(2);
1203  data.push_back(du_dt[0]);
1204  data.push_back(du_dt[1]);
1205 
1206  // Get divergence of skeleton velocity and its components
1207  Vector<double> div_dudt_components(2);
1208  data.push_back(interpolated_div_du_dt(s, div_dudt_components));
1209  data.push_back(div_dudt_components[0]);
1210  data.push_back(div_dudt_components[1]);
1211 
1212  // Get divergence of skeleton displacement and its components
1213  Vector<double> div_u_components(2);
1214  data.push_back(interpolated_div_u(s, div_u_components));
1215  data.push_back(div_u_components[0]);
1216  data.push_back(div_u_components[1]);
1217  }
int data[]
Definition: Map_placement_new.cpp:1
double interpolated_div_u(const Vector< double > &s, Vector< double > &div_u_components) const
Definition: axisym_poroelasticity_elements.h:527
double interpolated_div_du_dt(const Vector< double > &s, Vector< double > &div_dudt_components) const
Definition: axisym_poroelasticity_elements.h:479

References data, du_dt(), i, interpolated_div_du_dt(), interpolated_div_q(), interpolated_div_u(), interpolated_du_dt(), interpolated_p(), interpolated_q(), interpolated_u(), oomph::FiniteElement::interpolated_x(), and s.

◆ porosity()

const double& oomph::AxisymmetricPoroelasticityEquations::porosity ( ) const
inline

Access function for the porosity.

184  {
185  return *Porosity_pt;
186  }

References Porosity_pt.

Referenced by fill_in_generic_residual_contribution().

◆ porosity_pt()

double*& oomph::AxisymmetricPoroelasticityEquations::porosity_pt ( )
inline

Access function for pointer to the porosity.

190  {
191  return Porosity_pt;
192  }

References Porosity_pt.

◆ q_edge() [1/2]

virtual double oomph::AxisymmetricPoroelasticityEquations::q_edge ( const unsigned j) const
pure virtual

Return the values of the j-th edge (flux) degree of freedom.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by dq_edge_dt(), fill_in_generic_residual_contribution(), interpolated_div_q(), and interpolated_q().

◆ q_edge() [2/2]

virtual double oomph::AxisymmetricPoroelasticityEquations::q_edge ( const unsigned t,
const unsigned j 
) const
pure virtual

Return the values of the j-th edge (flux) degree of freedom at time history level t

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ q_edge_data_pt()

virtual Vector<Data*> oomph::AxisymmetricPoroelasticityEquations::q_edge_data_pt ( ) const
pure virtual

Return vector of pointers to the Data objects that store the edge flux values

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ q_edge_index()

virtual unsigned oomph::AxisymmetricPoroelasticityEquations::q_edge_index ( const unsigned j) const
pure virtual

Return the nodal index at which the jth edge unknown is stored.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ q_edge_local_eqn()

virtual int oomph::AxisymmetricPoroelasticityEquations::q_edge_local_eqn ( const unsigned j) const
pure virtual

Return the equation number of the j-th edge (flux) degree of freedom.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by fill_in_generic_residual_contribution().

◆ q_edge_node_number()

virtual unsigned oomph::AxisymmetricPoroelasticityEquations::q_edge_node_number ( const unsigned j) const
pure virtual

Return the number of the node where the jth edge unknown is stored.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by dq_edge_dt(), and fill_in_generic_residual_contribution().

◆ q_internal() [1/2]

virtual double oomph::AxisymmetricPoroelasticityEquations::q_internal ( const unsigned j) const
pure virtual

Return the values of the j-th internal degree of freedom.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by dq_internal_dt(), fill_in_generic_residual_contribution(), interpolated_div_q(), and interpolated_q().

◆ q_internal() [2/2]

virtual double oomph::AxisymmetricPoroelasticityEquations::q_internal ( const unsigned t,
const unsigned j 
) const
pure virtual

Return the values of the j-th internal degree of freedom at time history level t

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ q_internal_data_pt()

virtual Data* oomph::AxisymmetricPoroelasticityEquations::q_internal_data_pt ( ) const
pure virtual

Return pointer to the Data object that stores the internal flux values.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ q_internal_index()

virtual unsigned oomph::AxisymmetricPoroelasticityEquations::q_internal_index ( ) const
pure virtual

Return the index of the internal data where the q internal degrees of freedom are stored

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by dq_internal_dt(), fill_in_generic_residual_contribution(), and set_q_internal_timestepper().

◆ q_internal_local_eqn()

virtual int oomph::AxisymmetricPoroelasticityEquations::q_internal_local_eqn ( const unsigned j) const
pure virtual

Return the equation number of the j-th internal degree of freedom.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by fill_in_generic_residual_contribution().

◆ required_nvalue()

virtual unsigned oomph::AxisymmetricPoroelasticityEquations::required_nvalue ( const unsigned n) const
pure virtual

Number of values required at node n.

Reimplemented from oomph::FiniteElement.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ scalar_name_paraview()

std::string oomph::AxisymmetricPoroelasticityEquations::scalar_name_paraview ( const unsigned i) const
inlinevirtual

Name of the i-th scalar field. Default implementation returns V1 for the first one, V2 for the second etc. Can (should!) be overloaded with more meaningful names in specific elements.

Reimplemented from oomph::FiniteElement.

1122  {
1123  switch (i)
1124  {
1125  case 0:
1126  return "radial displacement";
1127  break;
1128 
1129  case 1:
1130  return "axial displacement";
1131  break;
1132 
1133  case 2:
1134  return "radial flux";
1135  break;
1136 
1137  case 3:
1138  return "axial flux";
1139  break;
1140 
1141  case 4:
1142  return "divergence of flux";
1143  break;
1144 
1145  case 5:
1146  return "pore pressure";
1147  break;
1148 
1149  case 6:
1150  return "radial skeleton velocity";
1151  break;
1152 
1153  case 7:
1154  return "axial skeleton velocity";
1155  break;
1156 
1157  default:
1158 
1159  std::stringstream error_stream;
1160  error_stream
1161  << "AxisymmetricPoroelasticityEquations only store 8 fields "
1162  << std::endl;
1163  throw OomphLibError(error_stream.str(),
1166 
1167  // Dummy return
1168  return " ";
1169  }
1170  }

References i, OOMPH_CURRENT_FUNCTION, and OOMPH_EXCEPTION_LOCATION.

◆ scalar_value_paraview()

void oomph::AxisymmetricPoroelasticityEquations::scalar_value_paraview ( std::ofstream &  file_out,
const unsigned i,
const unsigned nplot 
) const
inlinevirtual

Write values of the i-th scalar field at the plot points. Needs to be implemented for each new specific element type.

Reimplemented from oomph::FiniteElement.

1062  {
1063  // Vector of local coordinates
1064  Vector<double> s(2);
1065 
1066  // Loop over plot points
1067  unsigned num_plot_points = nplot_points_paraview(nplot);
1068  for (unsigned iplot = 0; iplot < num_plot_points; iplot++)
1069  {
1070  // Get local coordinates of plot point
1071  get_s_plot(iplot, nplot, s);
1072 
1073  // Skeleton velocity
1074  Vector<double> du_dt(2);
1076 
1077  // Displacements
1078  if (i < 2)
1079  {
1080  file_out << interpolated_u(s, i) << std::endl;
1081  }
1082  // Flux
1083  else if (i < 4)
1084  {
1085  file_out << interpolated_q(s, i - 2) << std::endl;
1086  }
1087  // Divergence of flux
1088  else if (i == 4)
1089  {
1090  file_out << interpolated_div_q(s) << std::endl;
1091  }
1092  else if (i == 5)
1093  {
1094  file_out << interpolated_p(s) << std::endl;
1095  }
1096  else if (i == 6)
1097  {
1098  file_out << du_dt[0] << std::endl;
1099  }
1100  else if (i == 7)
1101  {
1102  file_out << du_dt[1] << std::endl;
1103  }
1104  // Never get here
1105  else
1106  {
1107  std::stringstream error_stream;
1108  error_stream
1109  << "Axisymmetric poroelasticity elements only store 6 fields "
1110  << std::endl;
1111  throw OomphLibError(error_stream.str(),
1114  }
1115  }
1116  }
virtual unsigned nplot_points_paraview(const unsigned &nplot) const
Definition: elements.h:2862

References du_dt(), oomph::FiniteElement::get_s_plot(), i, interpolated_div_q(), interpolated_du_dt(), interpolated_p(), interpolated_q(), interpolated_u(), oomph::FiniteElement::nplot_points_paraview(), OOMPH_CURRENT_FUNCTION, OOMPH_EXCEPTION_LOCATION, and s.

◆ scale_basis()

virtual void oomph::AxisymmetricPoroelasticityEquations::scale_basis ( Shape basis) const
pure virtual

Scale the edge basis to allow arbitrary edge mappings.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by transform_basis().

◆ self_test()

unsigned oomph::AxisymmetricPoroelasticityEquations::self_test ( )
inlinevirtual

Self test.

Reimplemented from oomph::FiniteElement.

1045  {
1046  return 0;
1047  }

◆ set_p_value()

virtual void oomph::AxisymmetricPoroelasticityEquations::set_p_value ( const unsigned j,
const double value 
)
pure virtual

Set the jth pressure value.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ set_q_edge() [1/2]

virtual void oomph::AxisymmetricPoroelasticityEquations::set_q_edge ( const unsigned j,
const double value 
)
pure virtual

Set the values of the j-th edge (flux) degree of freedom.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ set_q_edge() [2/2]

virtual void oomph::AxisymmetricPoroelasticityEquations::set_q_edge ( const unsigned t,
const unsigned j,
const double value 
)
pure virtual

Set the values of the j-th edge (flux) degree of freedom at time history level t

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ set_q_internal() [1/2]

virtual void oomph::AxisymmetricPoroelasticityEquations::set_q_internal ( const unsigned j,
const double value 
)
pure virtual

Set the values of the j-th internal degree of freedom.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ set_q_internal() [2/2]

virtual void oomph::AxisymmetricPoroelasticityEquations::set_q_internal ( const unsigned t,
const unsigned j,
const double value 
)
pure virtual

Set the values of the j-th internal degree of freedom at time history level t

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ set_q_internal_timestepper()

void oomph::AxisymmetricPoroelasticityEquations::set_q_internal_timestepper ( TimeStepper *const  time_stepper_pt)
inline

Set the timestepper of the q internal data object.

1001  {
1002  unsigned q_index = q_internal_index();
1003  this->internal_data_pt(q_index)->set_time_stepper(time_stepper_pt, false);
1004  }
void set_time_stepper(TimeStepper *const &time_stepper_pt, const bool &preserve_existing_data)
Definition: nodes.cc:406

References oomph::GeneralisedElement::internal_data_pt(), q_internal_index(), oomph::Data::set_time_stepper(), and oomph::GeomObject::time_stepper_pt().

◆ shape_basis_test_local()

virtual double oomph::AxisymmetricPoroelasticityEquations::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
protectedpure virtual

Compute the geometric basis, and the q, p and divergence basis functions and test functions at local coordinate s

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

◆ shape_basis_test_local_at_knot()

virtual double oomph::AxisymmetricPoroelasticityEquations::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
protectedpure virtual

Compute the geometric basis, and the q, p and divergence basis functions and test functions at integration point ipt

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by fill_in_generic_residual_contribution().

◆ solid_body_force()

void oomph::AxisymmetricPoroelasticityEquations::solid_body_force ( const double time,
const Vector< double > &  x,
Vector< double > &  b 
) const
inline

Indirect access to the solid body force function - returns 0 if no forcing function has been set

235  {
236  // If no function has been set, return zero vector
237  if (Solid_body_force_fct_pt == 0)
238  {
239  // Get spatial dimension of element
240  unsigned n = dim();
241  for (unsigned i = 0; i < n; i++)
242  {
243  b[i] = 0.0;
244  }
245  }
246  else
247  {
248  (*Solid_body_force_fct_pt)(time, x, b);
249  }
250  }

References b, oomph::FiniteElement::dim(), i, n, Solid_body_force_fct_pt, and plotDoE::x.

Referenced by fill_in_generic_residual_contribution().

◆ solid_body_force_fct_pt() [1/2]

SourceFctPt& oomph::AxisymmetricPoroelasticityEquations::solid_body_force_fct_pt ( )
inline

Access function: Pointer to solid body force function.

196  {
198  }

References Solid_body_force_fct_pt.

◆ solid_body_force_fct_pt() [2/2]

SourceFctPt oomph::AxisymmetricPoroelasticityEquations::solid_body_force_fct_pt ( ) const
inline

Access function: Pointer to solid body force function (const version)

202  {
204  }

References Solid_body_force_fct_pt.

◆ switch_off_darcy()

void oomph::AxisymmetricPoroelasticityEquations::switch_off_darcy ( )
inline

Switch off Darcy flow.

1016  {
1017  Darcy_is_switched_off = true;
1018 
1019  // Pin pressures and set them to zero
1020  double p = 0.0;
1021  unsigned np = np_basis();
1022  for (unsigned j = 0; j < np; j++)
1023  {
1024  pin_p_value(j, p);
1025  }
1026 
1027  // Pin internal flux data and set it to zero
1028  double q = 0.0;
1029  unsigned nq = nq_basis_internal();
1030  for (unsigned j = 0; j < nq; j++)
1031  {
1033  }
1034 
1035  // Pin edge flux data and set it to zero
1036  nq = nq_basis_edge();
1037  for (unsigned j = 0; j < nq; j++)
1038  {
1039  pin_q_edge_value(j, q);
1040  }
1041  }
virtual void pin_q_internal_value(const unsigned &j, const double &value)=0
Pin the jth internal q value and set it to specified value.
virtual void pin_p_value(const unsigned &j, const double &p)=0
Pin the jth pressure value and set it to p.
virtual void pin_q_edge_value(const unsigned &j, const double &value)=0
Pin the j-th edge (flux) degree of freedom and set it to specified value.

References Darcy_is_switched_off, j, np_basis(), nq_basis_edge(), nq_basis_internal(), p, pin_p_value(), pin_q_edge_value(), pin_q_internal_value(), and Eigen::numext::q.

◆ transform_basis() [1/2]

double oomph::AxisymmetricPoroelasticityEquations::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 the actual element

86  {
87  // Call the (geometric) shape functions and their derivatives
88  this->dshape_local(s, psi, dpsi);
89 
90  // Storage for the (geometric) jacobian and its inverse
91  DenseMatrix<double> jacobian(2), inverse_jacobian(2);
92 
93  // Get the jacobian of the geometric mapping and its determinant
94  double det = local_to_eulerian_mapping(dpsi, jacobian, inverse_jacobian);
95 
96  // Transform the derivative of the geometric basis so that it's w.r.t.
97  // global coordinates
98  this->transform_derivatives(inverse_jacobian, dpsi);
99 
100  // Get the number of computational basis vectors
101  const unsigned n_q_basis = this->nq_basis();
102 
103  // Loop over the basis vectors
104  for (unsigned l = 0; l < n_q_basis; l++)
105  {
106  // Loop over the spatial components
107  for (unsigned i = 0; i < 2; i++)
108  {
109  // Zero the basis
110  q_basis(l, i) = 0.0;
111  }
112  }
113 
114  // Loop over the spatial components
115  for (unsigned i = 0; i < 2; i++)
116  {
117  // And again
118  for (unsigned j = 0; j < 2; j++)
119  {
120  // Get the element of the jacobian (must transpose it due to different
121  // conventions) and divide by the determinant
122  double jac_trans = jacobian(j, i) / det;
123 
124  // Loop over the computational basis vectors
125  for (unsigned l = 0; l < n_q_basis; l++)
126  {
127  // Apply the appropriate div-conserving mapping
128  q_basis(l, i) += jac_trans * q_basis_local(l, j);
129  }
130  }
131  }
132 
133  // Scale the basis by the ratio of the length of the edge to the length of
134  // the corresponding edge on the reference element
135  scale_basis(q_basis);
136 
137  return det;
138  }
virtual void scale_basis(Shape &basis) const =0
Scale the edge basis to allow arbitrary edge mappings.
virtual void transform_derivatives(const DenseMatrix< double > &inverse_jacobian, DShape &dbasis) const
Definition: elements.cc:2833

References oomph::FiniteElement::dshape_local(), i, j, oomph::FiniteElement::local_to_eulerian_mapping(), nq_basis(), scale_basis(), and oomph::FiniteElement::transform_derivatives().

Referenced by get_q_basis(), oomph::TAxisymmetricPoroelasticityElement< ORDER >::shape_basis_test_local(), and transform_basis().

◆ transform_basis() [2/2]

double oomph::AxisymmetricPoroelasticityEquations::transform_basis ( const Vector< double > &  s,
const Shape q_basis_local,
Shape psi,
Shape q_basis 
) const
inline

Performs a div-conserving transformation of the vector basis functions from the reference element to the actual element

455  {
456  const unsigned n_node = this->nnode();
457  DShape dpsi(n_node, 2);
458  return transform_basis(s, q_basis_local, psi, dpsi, q_basis);
459  }

References oomph::FiniteElement::nnode(), s, and transform_basis().

◆ u_index_axisym_poroelasticity()

virtual unsigned oomph::AxisymmetricPoroelasticityEquations::u_index_axisym_poroelasticity ( const unsigned j) const
pure virtual

Return the nodal index of the j-th solid displacement unknown.

Implemented in oomph::TAxisymmetricPoroelasticityElement< ORDER >.

Referenced by d2u_dt2(), du_dt(), fill_in_generic_residual_contribution(), interpolated_div_u(), and interpolated_u().

◆ youngs_modulus()

const double& oomph::AxisymmetricPoroelasticityEquations::youngs_modulus ( ) const
inline

Access function to non-dim Young's modulus (ratio of actual Young's modulus to reference stress used to non-dim the equations. (const version)

84  {
85  return *Youngs_modulus_pt;
86  }

References Youngs_modulus_pt.

Referenced by fill_in_generic_residual_contribution().

◆ youngs_modulus_pt()

double*& oomph::AxisymmetricPoroelasticityEquations::youngs_modulus_pt ( )
inline

Pointer to non-dim Young's modulus (ratio of actual Young's modulus to reference stress used to non-dim the equations.

91  {
92  return Youngs_modulus_pt;
93  }

References Youngs_modulus_pt.

Member Data Documentation

◆ Alpha_pt

double* oomph::AxisymmetricPoroelasticityEquations::Alpha_pt
private

Alpha – the biot parameter.

Referenced by alpha(), and alpha_pt().

◆ Darcy_is_switched_off

bool oomph::AxisymmetricPoroelasticityEquations::Darcy_is_switched_off
private

Boolean to record that darcy has been switched off.

Referenced by darcy_is_switched_off(), and switch_off_darcy().

◆ Default_alpha_value

double oomph::AxisymmetricPoroelasticityEquations::Default_alpha_value = 1.0
staticprivate

Static default value for alpha, the biot parameter.

Static default value for alpha, the Biot parameter.

◆ Default_density_ratio_value

double oomph::AxisymmetricPoroelasticityEquations::Default_density_ratio_value = 1.0
staticprivate

Static default value for the density ratio.

Static default value for the density ratio (fluid to solid)

◆ Default_lambda_sq_value

double oomph::AxisymmetricPoroelasticityEquations::Default_lambda_sq_value = 1.0
staticprivate

Static default value for timescale ratio.

Static default value for timescale ratio (1.0)

◆ Default_permeability_ratio_value

double oomph::AxisymmetricPoroelasticityEquations::Default_permeability_ratio_value
staticprivate
Initial value:
=
1.0

Static default value for the ratio of the material's actual permeability to the permeability used to non-dimensionalise the equations

Static default value for ratio of the material's actual permeability to the permeability used in the non-dimensionalisastion of the equations

◆ Default_permeability_value

double oomph::AxisymmetricPoroelasticityEquations::Default_permeability_value = 1.0
staticprivate

Static default value for the permeability (1.0 for natural scaling; i.e. timescale is given by L^2/(k^* E)

Static default value for permeability (1.0 for natural scaling i.e. timescale is given by L^2/(k^* E)

◆ Default_porosity_value

double oomph::AxisymmetricPoroelasticityEquations::Default_porosity_value = 1.0
staticprivate

Static default value for the porosity.

◆ Default_youngs_modulus_value

double oomph::AxisymmetricPoroelasticityEquations::Default_youngs_modulus_value
staticprivate
Initial value:
=
1.0

Static default value for Young's modulus (1.0 – for natural scaling, i.e. all stresses have been non-dimensionalised by the same reference Young's modulus. Setting the "non-dimensional" Young's modulus (obtained by de-referencing Youngs_modulus_pt) to a number larger than one means that the material is stiffer than assumed in the non-dimensionalisation.

◆ Density_ratio_pt

double* oomph::AxisymmetricPoroelasticityEquations::Density_ratio_pt
private

Density ratio.

Referenced by density_ratio(), and density_ratio_pt().

◆ Fluid_body_force_fct_pt

SourceFctPt oomph::AxisymmetricPoroelasticityEquations::Fluid_body_force_fct_pt
private

Pointer to fluid source function.

Referenced by fluid_body_force(), and fluid_body_force_fct_pt().

◆ Lambda_sq_pt

double* oomph::AxisymmetricPoroelasticityEquations::Lambda_sq_pt
private

Timescale ratio (non-dim. density)

Referenced by lambda_sq(), and lambda_sq_pt().

◆ Mass_source_fct_pt

MassSourceFctPt oomph::AxisymmetricPoroelasticityEquations::Mass_source_fct_pt
private

Pointer to the mass source function.

Referenced by mass_source(), and mass_source_fct_pt().

◆ Nu_pt

double* oomph::AxisymmetricPoroelasticityEquations::Nu_pt
private

Pointer to Poisson's ratio.

Referenced by nu(), and nu_pt().

◆ Permeability_pt

double* oomph::AxisymmetricPoroelasticityEquations::Permeability_pt
private

permeability

Referenced by permeability(), and permeability_pt().

◆ Permeability_ratio_pt

double* oomph::AxisymmetricPoroelasticityEquations::Permeability_ratio_pt
private

Ratio of the material's actual permeability to the permeability used in the non-dimensionalisation of the equations

Referenced by permeability_ratio(), and permeability_ratio_pt().

◆ Porosity_pt

double* oomph::AxisymmetricPoroelasticityEquations::Porosity_pt
private

Porosity.

Referenced by porosity(), and porosity_pt().

◆ Solid_body_force_fct_pt

SourceFctPt oomph::AxisymmetricPoroelasticityEquations::Solid_body_force_fct_pt
private

Pointer to solid body force function.

Referenced by solid_body_force(), and solid_body_force_fct_pt().

◆ Youngs_modulus_pt

double* oomph::AxisymmetricPoroelasticityEquations::Youngs_modulus_pt
private

Pointer to the nondim Young's modulus.

Referenced by youngs_modulus(), and youngs_modulus_pt().


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