|
openCARP
Doxygen code documentation for the open cardiac electrophysiology simulator openCARP
|
#include <mechanics.h>
Public Member Functions | |
| void | init () |
| Initialize equlibirum solver. More... | |
| void | rebuild_matrices (MaterialType mtype, FILE_SPEC logger) |
| rebuild the matrices More... | |
| void | rebuild_stiffness (MaterialType mtype, FILE_SPEC logger) |
| rebuild stiffness matrix More... | |
| void | calc_internal_forces (MaterialType mtype, FILE_SPEC logger) |
| Calculation of the internal forces based on the deformation. More... | |
| void | calc_internal_forces_jacobian (MaterialType mtype, FILE_SPEC logger) |
| void | apply_external_forces (MaterialType mtype, FILE_SPEC logger, sf_mesh surfmesh, mech_bcs nmbcs) |
| Applying external forces from Neumann boundary conditions. More... | |
| void | solve () |
| void | apply_bcs_forces () |
| void | apply_bcs_jacobian () |
| void | update_node_coords () |
Public Attributes | |
| sf_vec * | position |
| position x More... | |
| sf_vec * | reference_pos |
| reference position X More... | |
| sf_vec * | displacement |
| absolute displacement u More... | |
| sf_vec * | du |
| incremental displacement du More... | |
| sf_vec * | initial_guess |
| needed for initial guess for nonlinear solver More... | |
| sf_vec * | f_internal |
| internal forces f_int More... | |
| sf_vec * | f_external |
| external forces f_ext More... | |
| sf_vec * | f_surf |
| external forces applied on surfaces More... | |
| sf_vec * | residuum |
| residuum r More... | |
| SF::vector< mesh_int_t > | dbc_idx |
| Indices for Dirichlet boundary conditions. More... | |
| SF::vector< mesh_int_t > | nbc_idx |
| Indices for Neumann boundary conditions. More... | |
| sf_vec * | dirichlet_bcs |
| Dirichlet boundary conditions, 0 = dbc exists. More... | |
| sf_vec * | dirichlet_bcs_1 |
| Dirichlet boundary conditions but with 1 = dbc exists. More... | |
| sf_mat * | K_eq = nullptr |
| stiffness matrix for static equilibrium solver K More... | |
| mech_bcs | dmbcs [10] |
| Dirichlet boundary condtions. More... | |
| mech_bcs | nmbcs [10] |
| Neumann boundary conditions. More... | |
| sf_nl_sol * | nonlin_solver = nullptr |
| the nonlinear solver More... | |
| double | tol = 1e-8 |
| CG stopping tolerance. More... | |
| int | max_it = 300 |
| maximum number of iterations More... | |
@ brief Class for static mechanics solver Inspired by CBSolverEquilibrium-->CardioMechanics and elliptic_solver-->openCARP
Definition at line 68 of file mechanics.h.
|
inline |
|
inline |
| void opencarp::equilibrium_solver::apply_external_forces | ( | MaterialType | mtype, |
| FILE_SPEC | logger, | ||
| sf_mesh | surfmesh, | ||
| mech_bcs | nmbcs | ||
| ) |
Applying external forces from Neumann boundary conditions.
Definition at line 610 of file mechanics.cc.
| void opencarp::equilibrium_solver::calc_internal_forces | ( | MaterialType | mtype, |
| FILE_SPEC | logger | ||
| ) |
Calculation of the internal forces based on the deformation.
Definition at line 596 of file mechanics.cc.
| void opencarp::equilibrium_solver::calc_internal_forces_jacobian | ( | MaterialType | mtype, |
| FILE_SPEC | logger | ||
| ) |
| void opencarp::equilibrium_solver::init | ( | ) |
Initialize equlibirum solver.
alloc vectors
alloc solver matrix
mappings and numberings
set position and reference position vector
setup of Dirichlet and Neumann boundary conditions
Definition at line 335 of file mechanics.cc.
| void opencarp::equilibrium_solver::rebuild_matrices | ( | MaterialType | mtype, |
| FILE_SPEC | logger | ||
| ) |
rebuild the matrices
Definition at line 561 of file mechanics.cc.
| void opencarp::equilibrium_solver::rebuild_stiffness | ( | MaterialType | mtype, |
| FILE_SPEC | logger | ||
| ) |
rebuild stiffness matrix
Definition at line 572 of file mechanics.cc.
| void opencarp::equilibrium_solver::solve | ( | ) |
|
inline |
| SF::vector<mesh_int_t> opencarp::equilibrium_solver::dbc_idx |
Indices for Dirichlet boundary conditions.
Definition at line 80 of file mechanics.h.
| sf_vec* opencarp::equilibrium_solver::dirichlet_bcs |
Dirichlet boundary conditions, 0 = dbc exists.
Definition at line 82 of file mechanics.h.
| sf_vec* opencarp::equilibrium_solver::dirichlet_bcs_1 |
Dirichlet boundary conditions but with 1 = dbc exists.
Definition at line 83 of file mechanics.h.
| sf_vec* opencarp::equilibrium_solver::displacement |
absolute displacement u
Definition at line 73 of file mechanics.h.
| mech_bcs opencarp::equilibrium_solver::dmbcs[10] |
Dirichlet boundary condtions.
Definition at line 86 of file mechanics.h.
| sf_vec* opencarp::equilibrium_solver::du |
incremental displacement du
Definition at line 74 of file mechanics.h.
| sf_vec* opencarp::equilibrium_solver::f_external |
external forces f_ext
Definition at line 77 of file mechanics.h.
| sf_vec* opencarp::equilibrium_solver::f_internal |
internal forces f_int
Definition at line 76 of file mechanics.h.
| sf_vec* opencarp::equilibrium_solver::f_surf |
external forces applied on surfaces
Definition at line 78 of file mechanics.h.
| sf_vec* opencarp::equilibrium_solver::initial_guess |
needed for initial guess for nonlinear solver
Definition at line 75 of file mechanics.h.
| sf_mat* opencarp::equilibrium_solver::K_eq = nullptr |
stiffness matrix for static equilibrium solver K
Definition at line 84 of file mechanics.h.
| int opencarp::equilibrium_solver::max_it = 300 |
maximum number of iterations
Definition at line 93 of file mechanics.h.
| SF::vector<mesh_int_t> opencarp::equilibrium_solver::nbc_idx |
Indices for Neumann boundary conditions.
Definition at line 81 of file mechanics.h.
| mech_bcs opencarp::equilibrium_solver::nmbcs[10] |
Neumann boundary conditions.
Definition at line 87 of file mechanics.h.
| sf_nl_sol* opencarp::equilibrium_solver::nonlin_solver = nullptr |
the nonlinear solver
Definition at line 89 of file mechanics.h.
| sf_vec* opencarp::equilibrium_solver::position |
position x
Definition at line 71 of file mechanics.h.
| sf_vec* opencarp::equilibrium_solver::reference_pos |
reference position X
Definition at line 72 of file mechanics.h.
| sf_vec* opencarp::equilibrium_solver::residuum |
residuum r
Definition at line 79 of file mechanics.h.
| double opencarp::equilibrium_solver::tol = 1e-8 |
CG stopping tolerance.
Definition at line 92 of file mechanics.h.