openCARP
Doxygen code documentation for the open cardiac electrophysiology simulator openCARP
|
Namespaces | |
async | |
sig | |
stim_info | |
user_globals | |
Classes | |
struct | Activation |
event detection data structures More... | |
struct | async_io_item |
struct | base_timer |
class | Basic_physic |
The abstract physics interface we can use to trigger all physics. More... | |
struct | D_Complex |
class | dbc_manager |
manager for dirichlet boundary conditions More... | |
struct | diffMaterial |
class | elec_stiffness_integrator |
struct | elecMaterial |
class | Electrics |
class | elliptic_solver |
struct | file_desc |
File descriptor struct. More... | |
struct | generic_timing_stats |
for analysis of the #iterations to solve CG More... | |
class | geom_shape |
class to store shape definitions More... | |
struct | gvec_data |
class | igb_output_manager |
class | IGBheader |
class | Ionics |
class | Laplace |
class | LAT_detector |
struct | lin_solver_stats |
for analysis of the #iterations to solve CG More... | |
struct | List |
class | mass_integrator |
struct | MaterialType |
description of materal properties in a mesh More... | |
struct | opticsMaterial |
class | parabolic_solver |
struct | phie_recovery_data |
struct | physMaterial |
struct | prog_stats |
for display execution progress and statistical data of electrical solve More... | |
struct | RegionSpecs |
region based variations of arbitrary material parameters More... | |
union | rgba |
struct | S_Complex |
struct | Salt_list |
saltatory list – memory is allocated in chunks More... | |
struct | Sentinel |
sentinel for checking activity in the tissue More... | |
class | stim_electrode |
class | stim_physics |
class | stim_protocol |
class | stim_pulse |
define the wave form of a stimulation pulse More... | |
class | stimulus |
struct | sv_data |
struct | sync_io_item |
struct | timer_eq |
class | timer_manager |
centralize time managment and output triggering More... | |
struct | timer_neq |
struct | vec3 |
Typedefs | |
typedef SF::meshdata< mesh_int_t, mesh_real_t > | sf_mesh |
typedef SF::abstract_vector< SF_int, SF_real > | sf_vec |
typedef SF::abstract_matrix< SF_int, SF_real > | sf_mat |
typedef SF::abstract_linear_solver< SF_int, SF_real > | sf_sol |
typedef file_desc * | FILE_SPEC |
typedef struct opencarp::List | List |
typedef unsigned char | byte |
typedef unsigned char | Byte |
typedef char * | String |
typedef signed char | Char |
typedef struct S_Complex | S_Complex |
typedef double | Double |
typedef struct D_Complex | D_Complex |
typedef float | Float |
typedef int | Int |
typedef long | Long |
typedef unsigned int | UInt |
typedef short | Short |
typedef int | BooleaN |
typedef int | Flag |
typedef char * | RDir |
typedef char * | RFile |
typedef char * | RWDir |
typedef char * | RWFile |
typedef char * | WDir |
typedef char * | WFile |
typedef char ** | Text |
typedef void | Any |
typedef union opencarp::rgba | rgba |
typedef uint16_t | short_float |
typedef vec3< POINT_REAL > | Point |
Enumerations | |
enum | IO_t { INPUT, OUTPUT, POSTPROC, CURDIR } |
The different output (directory) types. More... | |
enum | tagreg_t { tagreg_sphere = 1, tagreg_block = 2, tagreg_cylinder = 3, tagreg_list = 4 } |
tag regions types. must be in line with carp.prm More... | |
enum | physMat_t { PhysMat =0, ElecMat =1, DiffuseMat =2, MechMat =3, OpticsMat =4 } |
identifier for physical material properties More... | |
enum | cond_t { intra_cond, extra_cond, sum_cond, para_cond } |
description of electrical tissue properties More... | |
enum | mesh_t { intra_elec_msh = 0, extra_elec_msh, eikonal_msh, elasticity_msh, fluid_msh, reference_msh, phie_recv_msh, unset_msh, num_msh } |
The enum identifying the different meshes we might want to load. More... | |
enum | PotType { VM, PHIE } |
enum | ActMethod { NONE, ACT_THRESH, ACT_DT } |
enum | physic_t { ion_phys =0, elec_phys, mech_phys, diffK_phys, magnet_phys, opt_phys, fluid_phys, NUM_PHYSICS } |
Identifier for the different physics we want to set up. More... | |
enum | datavec_t { vm_vec, iion_vec } |
Enum used to adress the different data vectors stored in the data registry. More... | |
enum | waveform_t { squarePulse = 0, truncExpPulse, sinePulse, arbPulse, constPulse, unsetPulse } |
enum | stim_t { I_tm =0, I_ex =1, V_ex =2, GND_ex =3, I_in =4, V_ex_ol =5, Illum =6, I_tm_grad =7, I_lat =8, Vm_clmp =9, Phie_pre =10, Ignore_stim =11 } |
enum | stim_domain_t { intra_stim = 1, purk_stim = 2, all_stim = 3 } |
enum | io_time { iotm_console = 0, iotm_state_var, iotm_spacedt, iotm_chkpt_list, iotm_chkpt_intv, iotm_trace, iotm_num_timers } |
The timers we always need are indexed in this enum. More... | |
enum | t_timer { EQUDIST, NONEQUDIST } |
We distinguish between equidistant and non-equidistant timers with an enum. More... | |
Functions | |
void | parse_params_cpy (int argc, char **argv) |
Initialize input parameters on a copy of the real command line parameters. More... | |
void | register_physics () |
Register physics to the physics registry. More... | |
void | initialize_physics () |
Initialize all physics in the registry. More... | |
void | destroy_physics () |
Destroy all physics in the registry. More... | |
void | ignore_extracellular_stim (Stimulus *st, int ns, int ignore) |
int | set_ignore_flags (int mode) |
void | check_nullspace_ok () |
void | show_build_info () |
show the build info, exit if -buildinfo was provided. This code runs before MPI_Init(). More... | |
void | check_and_convert_params () |
Here we want to put all parameter checks, conversions and modifications that have been littered throughout the codebase. More... | |
void | set_io_dirs (char *sim_ID, char *pp_ID, IO_t init) |
bool | setup_IO (int argc, char **argv) |
void | update_cwd () |
save the current working directory to curdir so that we can switch back to it if needed. More... | |
int | set_dir (IO_t dest) |
void | basic_timer_setup () |
Here we set up the timers that we always want to have, independent of physics. More... | |
void | get_protocol_column_widths (std::vector< int > &col_width, std::vector< int > &used_timer_ids) |
int | plot_protocols (const char *fname) |
plot simulation protocols (I/O timers, stimuli, boundary conditions, etc) More... | |
void | init_console_output (const timer_manager &tm, prog_stats &p) |
void | time_to_string (float time, char *str, short str_size) |
void | update_console_output (const timer_manager &tm, prog_stats &p) |
void | simulate () |
Main simulate loop. More... | |
void | post_process () |
do postprocessing More... | |
Basic_physic * | get_physics (physic_t p, bool error_if_missing=true) |
Convinience function to get a physics. More... | |
sf_vec * | get_data (datavec_t d) |
Retrieve a petsc data vector from the data registry. More... | |
void | register_data (sf_vec *dat, datavec_t d) |
Register a data vector in the global registry. More... | |
void | parse_mesh_types () |
Parse the phys_type CLI parameters and set up (empty) SF::meshdata meshes. More... | |
void | retag_elements (sf_mesh &mesh, TagRegion *tagRegs, int ntr) |
size_t | renormalise_fibres (SF::vector< mesh_real_t > &fib, size_t l_numelem) |
void | setup_meshes () |
Read in the reference mesh and use its data to populate all meshes registered in the mesh registry. More... | |
void | output_meshes () |
void | cleanup_and_exit () |
char * | get_file_dir (const char *file) |
void | setup_petsc_err_log () |
set up error logs for PETSc, so that it doesnt print errors to stderr. More... | |
short | get_mesh_dim (mesh_t id) |
get (lowest) dimension of the mesh used in the experiment More... | |
void | output_parameter_file (const char *fname, int argc, char **argv) |
void | savequit () |
save state and quit simulator More... | |
unsigned int | classify_soln_methods () |
void | parse_comment_line (char *buff, const int buffsize, std::map< std::string, std::string > &metadata) |
void | read_metadata (const std::string filename, std::map< std::string, std::string > &metadata, MPI_Comm comm) |
Read metadata from the header. More... | |
char * | skip_comments (FILE_SPEC stream, char *readbuff, size_t buffsize, MPI_Comm comm) |
void | indices_from_region_tag (SF::vector< mesh_int_t > &idx, const sf_mesh &mesh, const int tag) |
Populate vertex data with the vertices of a given tag region. More... | |
void | indices_from_geom_shape (SF::vector< mesh_int_t > &idx, const sf_mesh &mesh, const geom_shape shape, const bool nodal) |
Populate vertex data with the vertices inside a defined box shape. More... | |
SF_real | get_volume_from_nodes (sf_mat &mass, SF::vector< mesh_int_t > &local_idx) |
void | warn_when_passing_intra_vtx (const std::string filename) |
template<class T > | |
void | read_indices_global (SF::vector< T > &idx, const std::string filename, MPI_Comm comm) |
template<class T > | |
void | read_indices (SF::vector< T > &idx, const std::string filename, const hashmap::unordered_map< mesh_int_t, mesh_int_t > &dd_map, MPI_Comm comm) |
Read indices from a file. More... | |
template<class T > | |
void | read_indices (SF::vector< T > &idx, const std::string filename, const sf_mesh &mesh, const SF::SF_nbr nbr, const bool algebraic, MPI_Comm comm) |
Read indices from a file. More... | |
template<class T > | |
void | read_indices (SF::vector< T > &idx, const std::string filename, const SF::vector< mesh_int_t > &dd_nbr, MPI_Comm comm) |
Read indices from a file. More... | |
template<class T , class S > | |
void | read_indices_with_data (SF::vector< T > &idx, SF::vector< S > &dat, const std::string filename, const hashmap::unordered_map< mesh_int_t, mesh_int_t > &dd_map, const int dpn, MPI_Comm comm) |
like read_indices, but with associated data for each index More... | |
template<class T , class S > | |
void | read_indices_with_data (SF::vector< T > &idx, SF::vector< S > &dat, const std::string filename, const sf_mesh &mesh, const SF::SF_nbr nbr, const bool algebraic, const int dpn, MPI_Comm comm) |
like read_indices, but with associated data for each index More... | |
template<class T , class S > | |
void | read_indices_with_data (SF::vector< T > &idx, SF::vector< S > &dat, const std::string filename, const SF::vector< mesh_int_t > &dd_nbr, const int dpn, MPI_Comm comm) |
like read_indices, but with associated data for each index More... | |
sf_mesh & | get_mesh (const mesh_t gt) |
Get a mesh by specifying the gridID. More... | |
const char * | get_mesh_type_name (mesh_t t) |
get a char* to the name of a mesh type More... | |
bool | mesh_is_registered (const mesh_t gt) |
check wheter a SF mesh is set More... | |
SF::scattering * | register_scattering (const int from, const int to, const SF::SF_nbr nbr, const int dpn) |
Register a scattering between to grids, or between algebraic and nodal representation of data on the same grid. More... | |
SF::scattering * | get_scattering (const int from, const int to, const SF::SF_nbr nbr, const int dpn) |
Get a scattering from the global scatter registry. More... | |
bool | have_scattering (const int from, const int to, const SF::SF_nbr nbr, const int dpn) |
SF::scattering * | register_permutation (const int mesh_id, const int perm_id, const int dpn) |
Register a permutation between two orderings for a mesh. More... | |
SF::scattering * | get_permutation (const int mesh_id, const int perm_id, const int dpn) |
Get the PETSC to canonical permutation scattering for a given mesh and number of dpn. More... | |
bool | have_permutation (const int mesh_id, const int perm_id, const int dpn) |
SF::scattering * | register_scattering (const int from, const int to, const int dpn) |
SF::scattering * | get_scattering (const int from, const int to, const int dpn) |
bool | have_scattering (const int from, const int to, const int dpn) |
int | get_preferred_int_order (SF::elem_t &etype, int mat_type) |
void | print_element_info (const SF::element_view< mesh_int_t, mesh_real_t > &elem, const int *reg, const double vol, const double *eVals, const char *msg_start) |
void | get_conductivity_evals (const elecMaterial &emat, const bool is_bath, double *evals) |
void | get_conductivity (const double *evals, const SF::Point *f, const SF::Point *s, SF::dmat< double > &cond) |
void | print_points (SF::Point *pts, int npts) |
void | set_elec_tissue_properties (MaterialType *mtype, Electrics::grid_t g, FILE_SPEC logger) |
Fill the RegionSpec of an electrics grid with the associated inputs from the param parameters. More... | |
void | balance_electrode (SF::vector< stimulus > &stimuli, int balance_from, int balance_to) |
void | apply_stim_to_vector (const stimulus &s, sf_vec &vec, bool add) |
void | compute_restr_idx (sf_mesh &mesh, SF::vector< mesh_int_t > &inp_idx, SF::vector< mesh_int_t > &idx) |
void | compute_restr_idx_async (sf_mesh &mesh, SF::vector< mesh_int_t > &inp_idx, SF::vector< mesh_int_t > &idx) |
void | setup_dataout (const int dataout, std::string dataout_vtx, mesh_t grid, SF::vector< mesh_int_t > *&restr, bool async=false) |
int | stimidx_from_timeridx (const SF::vector< stimulus > &stimuli, const int timer_id) |
determine link between timer and stimulus More... | |
void | get_kappa (sf_vec &kappa, IMPregion *ir, limpet::MULTI_IF &miif, double k) |
compute the vector ![]() | |
void | set_cond_type (MaterialType &m, cond_t type) |
bool | have_dbc_stims (const SF::vector< stimulus > &stimuli) |
return wheter any stimuli require dirichlet boundary conditions More... | |
const char * | get_tsav_ext (double time) |
void | print_act_log (FILE_SPEC logger, const SF::vector< Activation > &acts, int idx) |
int | output_all_activations (FILE_SPEC fp, int *ibuf, double *act_tbuf, int nlacts) |
void | recover_phie_std (sf_vec &vm, phie_recovery_data &rcv) |
int | postproc_recover_phie () |
void | setup_phie_recovery_data (phie_recovery_data &data) |
void | constant_total_stimulus_current (SF::vector< stimulus > &stimuli, sf_mat &mass_i, sf_mat &mass_e, limpet::MULTI_IF *miif, FILE_SPEC logger) |
void | initialize_sv_dumps (limpet::MULTI_IF *pmiif, IMPregion *reg, int id, double t, double dump_dt) |
bool | check_tags_in_elems (const SF::vector< int > &tags, SF::vector< RegionSpecs > ®spec, const char *gridname, const char *reglist) |
Check whether the tags in the region spec struct matches with an array of tags. More... | |
void | region_mask (mesh_t meshspec, SF::vector< RegionSpecs > ®spec, SF::vector< int > ®ionIDs, bool mask_elem, const char *reglist) |
classify elements/points as belonging to a region More... | |
void | compute_IIF (limpet::IonIfBase &pIF, limpet::GlobalData_t **impdata, int n) |
void * | find_SV_in_IMP (limpet::MULTI_IF *miif, const int idx, const char *IMP, const char *SV, int *offset, int *sz, int *plugin_idx) |
void | alloc_gvec_data (const int nGVcs, const int nRegs, GVecs *prmGVecs, gvec_data &glob_vecs) |
void | init_sv_gvec (gvec_data &GVs, limpet::MULTI_IF *miif, sf_vec &tmpl, igb_output_manager &output_manager) |
void | assemble_sv_gvec (gvec_data &gvecs, limpet::MULTI_IF *miif) |
void | init_stim_info (void) |
bool | is_voltage (stim_t type) |
uses voltage as stimulation More... | |
bool | is_current (stim_t type) |
uses current as stimulation More... | |
bool | is_dbc (stim_t type) |
whether stimulus is a dirichlet type. implies boundary conditions on matrix More... | |
bool | is_extra (stim_t type) |
whether stimulus is on extra grid (or on intra) More... | |
void | get_stim_list (const char *str_list, std::vector< double > &stlist) |
void | sample_wave_form (stim_pulse &sp, int idx) |
sample a signal given in analytic form More... | |
void | sltlst_append (Salt_list *sl, void *p, int quantum) |
char * | dupstr (const char *old_str) |
char * | stringify (double r) |
std::string | get_basename (const std::string &path) |
void | log_msg (FILE_SPEC out, int level, unsigned char flag, const char *fmt,...) |
bool | f_exist (const char *fname) |
FILE_SPEC | f_open (const char *fname, const char *mode) |
Open a FILE_SPEC. More... | |
void | f_close (FILE_SPEC &f) |
Close a FILE_SPEC. More... | |
void | f_read_par (void *ptr, size_t size, size_t nmemb, FILE_SPEC stream, MPI_Comm comm=PETSC_COMM_WORLD) |
Parallel fread. Root reads, then broadcasts. More... | |
void | f_write_par (void *ptr, size_t size, size_t nmemb, int source_pid, FILE_SPEC stream, MPI_Comm comm=PETSC_COMM_WORLD) |
Write in parallel. Data comes from one rank, rank 0 writes. More... | |
char * | f_gets_par (char *s, int size, FILE_SPEC stream, MPI_Comm comm) |
void | write_bin_string (FILE_SPEC out, const char *s) |
char * | read_bin_string (FILE_SPEC in) |
char * | read_bin_string_par (FILE_SPEC in) |
bool | point_in_shape (const Point &p, const geom_shape &shape) |
test if a point is inside a simple geometric shape More... | |
bool | is_big_endian () |
bool | file_can_be_opened (const char *file) |
Check wheterh a file can be opened for reading. More... | |
bool | path_is_absolute (const char *path) |
check whether path is absolute More... | |
template<class STRVEC > | |
void | split_string (const std::string &input, const char s, STRVEC &list) |
Split a string holding a character-seperated list into a vector of strings. More... | |
template<typename T > | |
T | get_global (T in, MPI_Op OP, MPI_Comm comm=PETSC_COMM_WORLD) |
Do a global reduction on a variable. More... | |
template<> | |
int | get_global< int > (int in, MPI_Op OP, MPI_Comm comm) |
template<> | |
long int | get_global< long int > (long int in, MPI_Op OP, MPI_Comm comm) |
template<typename T > | |
void | get_global (SF::vector< T > &vec, int sender=0, MPI_Comm comm=PETSC_COMM_WORLD) |
Broadcast a SF::vector to all processes. More... | |
int | get_rank (MPI_Comm comm=PETSC_COMM_WORLD) |
int | get_size (MPI_Comm comm=PETSC_COMM_WORLD) |
int | get_remote_size (MPI_Comm intercomm) |
void | init_iterations_logger (FILE_SPEC *&logger, const char *filename) |
init a logger for solver iterations More... | |
void | remove_preceding_char (char *buff, const int buffsize, const char c) |
void | remove_char (char *buff, const int buffsize, const char c) |
bool | has_char (char *buff, const int buffsize, const char c) |
void | get_time (double &tm) |
double | get_time () |
template<typename V > | |
V | timing (V &t2, const V &t1) |
int | my_fputs (FILE *, char *) |
template<class T > | |
int | read_IGB_data (T *dp, int numt, IGBheader *h, char *buf=NULL) |
template<class T > | |
T | IGB_convert_buffer_datum (IGBheader *, void *buf, int a) |
template<typename V > | |
V | det3 (const vec3< V > &a, const vec3< V > &b, const vec3< V > &c) |
template<typename V > | |
V | dist_2 (const vec3< V > &p1, const vec3< V > &p2) |
template<typename V > | |
V | dist (const vec3< V > &p1, const vec3< V > &p2) |
template<typename V > | |
V | angle (const vec3< V > &v1, const vec3< V > &v2) |
template<typename V > | |
V | dot (const vec3< V > &p1, const vec3< V > &p2) |
template<typename V > | |
V | mag (const vec3< V > &vect) |
template<typename V > | |
V | mag2 (const vec3< V > &vect) |
template<typename V > | |
vec3< V > | cross (const vec3< V > &a, const vec3< V > &b) |
template<typename V , typename S > | |
vec3< V > | scal_X (const vec3< V > &a, S k) |
template<typename V > | |
vec3< V > | operator* (const vec3< V > &a, V k) |
template<typename V > | |
vec3< V > | operator/ (const vec3< V > &a, V k) |
template<typename V > | |
vec3< V > | scale3 (const vec3< V > &a, const vec3< V > &k) |
template<typename V > | |
vec3< V > | operator- (const vec3< V > &a, const vec3< V > &b) |
template<typename V > | |
vec3< V > | operator+ (const vec3< V > &a, const vec3< V > &b) |
template<typename V > | |
vec3< V > | normalize (vec3< V > a) |
template<typename V > | |
double * | v_scale (int n, double *a, double k, double *b) |
template<typename V > | |
float * | v_scale_f (int n, float *a, double k, double *b) |
template<typename V > | |
vec3< V > | mid_point (vec3< V > a, vec3< V > b) |
template<typename V > | |
vec3< V > | rotate_z (vec3< V > p, double theta) |
template<typename V > | |
vec3< V > | rotate_y (vec3< V > p, double theta) |
template<typename V > | |
vec3< V > | rotate_x (vec3< V > p, double theta) |
void | matrix_mathematica (int n, double **a, char *outfile) |
template<typename V > | |
vec3< V > | p_project (vec3< V > A, vec3< V > B) |
template<typename V > | |
vec3< V > | p_transverse (vec3< V > A, vec3< V > B) |
template<typename V > | |
double | triple_prod (vec3< V > a, vec3< V > b, vec3< V > c) |
template<typename V > | |
bool | isNaN (vec3< V > a) |
template<typename V > | |
double | infnorm (const vec3< V > &a) |
Variables | |
const std::string | wfLabels [] = {"squarePulse", "truncExpPulse", "sinePulse", "arbPulse"} |
bool | Header_Quiet = false |
char | Header_Message [256] |
const char * | Header_Type [] |
const char * | deprecated [] |
unsigned short | Data_Size [] |
int | Num_Components [] |
long unsigned | Header_Systeme_No [] |
const char * | Header_Systeme [] |
const uint16_t | basetable [512] |
const uint16_t | shifttable [512] |
const uint32_t | mantissatable [2048] |
const uint16_t | offsettable [64] |
const uint32_t | exponenttable [64] |
typedef void opencarp::Any |
Definition at line 145 of file IGBheader.h.
typedef int opencarp::BooleaN |
Definition at line 136 of file IGBheader.h.
typedef unsigned char opencarp::byte |
Definition at line 122 of file IGBheader.h.
typedef unsigned char opencarp::Byte |
Definition at line 124 of file IGBheader.h.
typedef signed char opencarp::Char |
Definition at line 127 of file IGBheader.h.
typedef struct D_Complex opencarp::D_Complex |
Definition at line 130 of file IGBheader.h.
typedef double opencarp::Double |
Definition at line 129 of file IGBheader.h.
typedef file_desc* opencarp::FILE_SPEC |
typedef int opencarp::Flag |
Definition at line 137 of file IGBheader.h.
typedef float opencarp::Float |
Definition at line 131 of file IGBheader.h.
typedef int opencarp::Int |
Definition at line 132 of file IGBheader.h.
typedef struct opencarp::List opencarp::List |
typedef long opencarp::Long |
Definition at line 133 of file IGBheader.h.
typedef vec3<POINT_REAL> opencarp::Point |
typedef char* opencarp::RDir |
Definition at line 138 of file IGBheader.h.
typedef char* opencarp::RFile |
Definition at line 139 of file IGBheader.h.
typedef union opencarp::rgba opencarp::rgba |
typedef char* opencarp::RWDir |
Definition at line 140 of file IGBheader.h.
typedef char* opencarp::RWFile |
Definition at line 141 of file IGBheader.h.
typedef struct S_Complex opencarp::S_Complex |
Definition at line 128 of file IGBheader.h.
typedef SF::abstract_matrix<SF_int,SF_real> opencarp::sf_mat |
Shorthand for abstract matrix. Uses double value type.
Definition at line 51 of file sf_interface.h.
Shorthand type for the mesh. Uses mesh_real_t (float) as value type.
Definition at line 47 of file sf_interface.h.
Shorthand for abstract linear solver. Uses double value type.
Definition at line 53 of file sf_interface.h.
typedef SF::abstract_vector<SF_int,SF_real> opencarp::sf_vec |
Shorthand for abstract vector. Uses double value type.
Definition at line 49 of file sf_interface.h.
typedef short opencarp::Short |
Definition at line 135 of file IGBheader.h.
typedef uint16_t opencarp::short_float |
Definition at line 48 of file short_float.h.
typedef char* opencarp::String |
Definition at line 125 of file IGBheader.h.
typedef char** opencarp::Text |
Definition at line 144 of file IGBheader.h.
typedef unsigned int opencarp::UInt |
Definition at line 134 of file IGBheader.h.
typedef char* opencarp::WDir |
Definition at line 142 of file IGBheader.h.
typedef char* opencarp::WFile |
Definition at line 143 of file IGBheader.h.
enum opencarp::ActMethod |
Enumerator | |
---|---|
NONE | |
ACT_THRESH | |
ACT_DT |
Definition at line 161 of file electrics.h.
enum opencarp::cond_t |
description of electrical tissue properties
Enumerator | |
---|---|
intra_cond | |
extra_cond | |
sum_cond | |
para_cond |
Definition at line 42 of file fem_types.h.
enum opencarp::datavec_t |
Enum used to adress the different data vectors stored in the data registry.
Enumerator | |
---|---|
vm_vec | |
iion_vec |
Definition at line 99 of file physics_types.h.
enum opencarp::IO_t |
The different output (directory) types.
Enumerator | |
---|---|
INPUT | |
OUTPUT | |
POSTPROC | |
CURDIR |
Definition at line 52 of file sim_utils.h.
enum opencarp::io_time |
The timers we always need are indexed in this enum.
Enumerator | |
---|---|
iotm_console | |
iotm_state_var | |
iotm_spacedt | |
iotm_chkpt_list | |
iotm_chkpt_intv | |
iotm_trace | |
iotm_num_timers |
Definition at line 44 of file timer_utils.h.
enum opencarp::mesh_t |
The enum identifying the different meshes we might want to load.
Enumerator | |
---|---|
intra_elec_msh | |
extra_elec_msh | |
eikonal_msh | |
elasticity_msh | |
fluid_msh | |
reference_msh | |
phie_recv_msh | |
unset_msh | |
num_msh |
Definition at line 58 of file sf_interface.h.
enum opencarp::physic_t |
Identifier for the different physics we want to set up.
The order of the physics defines the order the in which initialize(), compute_step() and output_step() will be called.
The physic_t does not correspond directly to mesh_t, since we have multiple physics defined on one mesh (electrics).
Enumerator | |
---|---|
ion_phys | |
elec_phys | |
mech_phys | |
diffK_phys | |
magnet_phys | |
opt_phys | |
fluid_phys | |
NUM_PHYSICS |
Definition at line 51 of file physics_types.h.
enum opencarp::physMat_t |
identifier for physical material properties
Enumerator | |
---|---|
PhysMat | |
ElecMat | |
DiffuseMat | |
MechMat | |
OpticsMat |
Definition at line 39 of file fem_types.h.
enum opencarp::PotType |
Enumerator | |
---|---|
VM | |
PHIE |
Definition at line 160 of file electrics.h.
Enumerator | |
---|---|
intra_stim | |
purk_stim | |
all_stim |
Definition at line 84 of file stimulate.h.
enum opencarp::stim_t |
Enumerator | |
---|---|
I_tm | |
I_ex | |
V_ex | |
GND_ex | |
I_in | |
V_ex_ol | |
Illum | |
I_tm_grad | |
I_lat | |
Vm_clmp | |
Phie_pre | |
Ignore_stim |
Definition at line 83 of file stimulate.h.
enum opencarp::t_timer |
We distinguish between equidistant and non-equidistant timers with an enum.
Enumerator | |
---|---|
EQUDIST | |
NONEQUDIST |
Definition at line 49 of file timer_utils.h.
enum opencarp::tagreg_t |
tag regions types. must be in line with carp.prm
Enumerator | |
---|---|
tagreg_sphere | |
tagreg_block | |
tagreg_cylinder | |
tagreg_list |
Definition at line 55 of file sim_utils.h.
enum opencarp::waveform_t |
Enumerator | |
---|---|
squarePulse | |
truncExpPulse | |
sinePulse | |
arbPulse | |
constPulse | |
unsetPulse |
Definition at line 79 of file stimulate.h.
void opencarp::alloc_gvec_data | ( | const int | nGVcs, |
const int | nRegs, | ||
GVecs * | prmGVecs, | ||
gvec_data & | glob_vecs | ||
) |
Convert PrM data to internal data structures
NGVcs | number of global (composite) state vectors |
nRegs | number of IMP regions defined over entire domain |
prmGVecs | Global composite vector structure to unPrM |
GlobalVecs | store data needed to compose gloabl vectors |
Definition at line 509 of file ionics.cc.
void opencarp::assemble_sv_gvec | ( | gvec_data & | gvecs, |
limpet::MULTI_IF * | miif | ||
) |
output the global vector
Gvec | global vectors |
miif | IMPs |
purk | Purkinje system |
SVgetfcn
but the header dependency got really ugly so it is void*
and then typecast Definition at line 631 of file ionics.cc.
void opencarp::balance_electrode | ( | SF::vector< stimulus > & | stimuli, |
int | balance_from, | ||
int | balance_to | ||
) |
void opencarp::basic_timer_setup | ( | ) |
Here we set up the timers that we always want to have, independent of physics.
start_time | Start time of the simulation |
Definition at line 458 of file sim_utils.cc.
void opencarp::check_and_convert_params | ( | ) |
Here we want to put all parameter checks, conversions and modifications that have been littered throughout the codebase.
Usualy people modify param globals next to the code that is affected by that change. This works well first, but after some time a lot of state is accumulated to the initially stateless functions. As such, the code works only if the order of function calls etc is not changed. In the long term it is better to accumulate all changes and checks of globals in specific functions so that the rest of the codebase can be programmed and used stateless. -Aurel
Definition at line 227 of file sim_utils.cc.
void opencarp::check_nullspace_ok | ( | ) |
check the Nullspace strategy of the setup for solving the elliptic PDE
s | stimulus array |
fGND | floating ground |
true | if strategy is ok, i.e. either we specify a potential, a floating ground or a dedicated strategy (expicit enforcement of zero mean, etc) |
false | system is singular |
Definition at line 199 of file sim_utils.cc.
bool opencarp::check_tags_in_elems | ( | const SF::vector< int > & | tags, |
SF::vector< RegionSpecs > & | regspec, | ||
const char * | gridname, | ||
const char * | reglist | ||
) |
Check whether the tags in the region spec struct matches with an array of tags.
tags | Tags vector. |
regspec | Array of region spec structs |
gridname | Grid name (for message output) |
reglist | Name of the regspec list. |
Definition at line 323 of file ionics.cc.
unsigned int opencarp::classify_soln_methods | ( | ) |
determine the solution methods
void opencarp::cleanup_and_exit | ( | ) |
void opencarp::compute_IIF | ( | limpet::IonIfBase & | pIF, |
limpet::GlobalData_t ** | impdata, | ||
int | n | ||
) |
void opencarp::compute_restr_idx | ( | sf_mesh & | mesh, |
SF::vector< mesh_int_t > & | inp_idx, | ||
SF::vector< mesh_int_t > & | idx | ||
) |
void opencarp::compute_restr_idx_async | ( | sf_mesh & | mesh, |
SF::vector< mesh_int_t > & | inp_idx, | ||
SF::vector< mesh_int_t > & | idx | ||
) |
void opencarp::constant_total_stimulus_current | ( | SF::vector< stimulus > & | simuli, |
sf_mat & | mass_i, | ||
sf_mat & | mass_e, | ||
limpet::MULTI_IF * | miif, | ||
FILE_SPEC | logger | ||
) |
scale current densities to keep total injected current constant
[in] | stimuli | The stimuli vector. |
[in] | mass_i | intracellular mass matrix, ![]() |
[in] | mass_e | extracellular mass matrix, ![]() |
[in] | miif | ionic interface |
[in] | logger | handle to output log |
Definition at line 2164 of file electrics.cc.
void opencarp::destroy_physics | ( | ) |
Destroy all physics in the registry.
Definition at line 124 of file sim_utils.cc.
char * opencarp::dupstr | ( | const char * | old_str | ) |
void opencarp::f_close | ( | FILE_SPEC & | f | ) |
bool opencarp::f_exist | ( | const char * | fname | ) |
char * opencarp::f_gets_par | ( | char * | s, |
int | size, | ||
FILE_SPEC | stream, | ||
MPI_Comm | comm | ||
) |
FILE_SPEC opencarp::f_open | ( | const char * | fname, |
const char * | mode | ||
) |
void opencarp::f_read_par | ( | void * | ptr, |
size_t | size, | ||
size_t | nmemb, | ||
FILE_SPEC | stream, | ||
MPI_Comm | comm = PETSC_COMM_WORLD |
||
) |
void opencarp::f_write_par | ( | void * | ptr, |
size_t | size, | ||
size_t | nmemb, | ||
int | source_pid, | ||
FILE_SPEC | stream, | ||
MPI_Comm | comm = PETSC_COMM_WORLD |
||
) |
Write in parallel. Data comes from one rank, rank 0 writes.
ptr | Buffer to write. Needs only be allocated on rank source_pid. |
size | Size of data type. |
nmemb | Number of data members. Needs only be set on rank source_pid. |
source_pid | The PID of the rank the data is on. |
stream | The file we write to. Needs only be valid rank 0. |
comm | The MPI communicator to use. |
bool opencarp::file_can_be_opened | ( | const char * | file | ) |
void* opencarp::find_SV_in_IMP | ( | limpet::MULTI_IF * | miif, |
const int | idx, | ||
const char * | IMP, | ||
const char * | SV, | ||
int * | offset, | ||
int * | sz, | ||
int * | plugin_idx | ||
) |
search an IMP and its plugins for a state variable
[in] | miif | ionic structure |
[in] | inx | region index of the miif to search |
[in] | IMP | IMP name to look in |
[in] | SV | state variable to find |
[out] | offset | offset into IMP state variable structure |
[out] | sz | size of SV structure |
Definition at line 480 of file ionics.cc.
std::string opencarp::get_basename | ( | const std::string & | path | ) |
void opencarp::get_conductivity_evals | ( | const elecMaterial & | emat, |
const bool | is_bath, | ||
double * | evals | ||
) |
Retrieve a petsc data vector from the data registry.
d | The identifier of the data vector. |
Definition at line 834 of file sim_utils.cc.
char * opencarp::get_file_dir | ( | const char * | file | ) |
|
inline |
Do a global reduction on a variable.
The variable gets internally cast to a double, then reduced and then cast back.
T | Variable type. |
in | Local input variable. |
OP | MPI operation to perform. |
Definition at line 233 of file basics.h.
|
inline |
Broadcast a SF::vector to all processes.
T | Datatype of vector entries |
vec | The vector we globalize |
sender |
|
inline |
|
inline |
void opencarp::get_kappa | ( | sf_vec & | kappa, |
IMPregion * | ir, | ||
limpet::MULTI_IF & | miif, | ||
double | k | ||
) |
compute the vector
is the membrane surface area per unit tissue volume
kappa | spatially varying kappa in vector form |
ir | imp regions array provided by param |
miif | miif class holding the ionic parameters |
k | region-independent scaling factor |
Definition at line 779 of file electrics.cc.
Get a mesh by specifying the gridID.
gt | The grid ID. |
Definition at line 33 of file sf_interface.cc.
short opencarp::get_mesh_dim | ( | mesh_t | id | ) |
get (lowest) dimension of the mesh used in the experiment
Definition at line 1255 of file sim_utils.cc.
const char * opencarp::get_mesh_type_name | ( | mesh_t | t | ) |
get a char* to the name of a mesh type
Definition at line 46 of file sf_interface.cc.
SF::scattering * opencarp::get_permutation | ( | const int | mesh_id, |
const int | perm_id, | ||
const int | dpn | ||
) |
Get the PETSC to canonical permutation scattering for a given mesh and number of dpn.
mesh_id | The mesh id. |
perm_id | The permutation specifier index (see sf_interface.h). |
dpn | Degrees of freedom per node. |
Definition at line 204 of file sf_interface.cc.
Basic_physic * opencarp::get_physics | ( | physic_t | p, |
bool | error_if_missing = true |
||
) |
Convinience function to get a physics.
p | The physics type. |
Definition at line 818 of file sim_utils.cc.
|
inline |
void opencarp::get_protocol_column_widths | ( | std::vector< int > & | col_width, |
std::vector< int > & | used_timer_ids | ||
) |
|
inline |
|
inline |
SF::scattering * opencarp::get_scattering | ( | const int | from, |
const int | to, | ||
const SF::SF_nbr | nbr, | ||
const int | dpn | ||
) |
Get a scattering from the global scatter registry.
[in] | from | The mesh ID we scatter from. |
[in] | to | The mesh ID we scatter to, or ALG_TO_NODAL. |
[in] | nbr | The used numbering. |
[in] | dpn | The degrees of freedom per node. |
Definition at line 121 of file sf_interface.cc.
|
inline |
Definition at line 152 of file sf_interface.h.
|
inline |
void opencarp::get_stim_list | ( | const char * | str_list, |
std::vector< double > & | stlist | ||
) |
|
inline |
const char* opencarp::get_tsav_ext | ( | double | time | ) |
helper function to get the tsav_ext string where the associated tsav value is closest to a given time
Definition at line 837 of file electrics.cc.
SF_real opencarp::get_volume_from_nodes | ( | sf_mat & | mass, |
SF::vector< mesh_int_t > & | local_idx | ||
) |
|
inline |
bool opencarp::have_dbc_stims | ( | const SF::vector< stimulus > & | stimuli | ) |
return wheter any stimuli require dirichlet boundary conditions
Definition at line 826 of file electrics.cc.
bool opencarp::have_permutation | ( | const int | mesh_id, |
const int | perm_id, | ||
const int | dpn | ||
) |
bool opencarp::have_scattering | ( | const int | from, |
const int | to, | ||
const SF::SF_nbr | nbr, | ||
const int | dpn | ||
) |
|
inline |
Definition at line 156 of file sf_interface.h.
T opencarp::IGB_convert_buffer_datum | ( | IGBheader * | , |
void * | buf, | ||
int | a | ||
) |
void opencarp::ignore_extracellular_stim | ( | Stimulus * | st, |
int | ns, | ||
int | ignore | ||
) |
for monodomain simulations, ignore extracellular current and potentials and convert intracellular current injection to transmembrane
st | specified stimuli ns #stimuli |
ignore | flags type of stimuli to ignore 0: ignore extracellular GND 1: ignore extracellular voltage 2: ignore extracellular current |
Definition at line 151 of file sim_utils.cc.
void opencarp::indices_from_geom_shape | ( | SF::vector< mesh_int_t > & | idx, |
const sf_mesh & | mesh, | ||
const geom_shape | shape, | ||
const bool | nodal | ||
) |
Populate vertex data with the vertices inside a defined box shape.
mesh | The mesh. |
shape | The shape we test against. |
nodal | Whether to test mesh nodes, or mesh elements. |
Definition at line 169 of file fem_utils.cc.
void opencarp::indices_from_region_tag | ( | SF::vector< mesh_int_t > & | idx, |
const sf_mesh & | mesh, | ||
const int | tag | ||
) |
Populate vertex data with the vertices of a given tag region.
mesh | The mesh. |
tag | The tag region to compute the vertices for. |
Definition at line 155 of file fem_utils.cc.
|
inline |
void opencarp::init_console_output | ( | const timer_manager & | tm, |
prog_stats & | p | ||
) |
void opencarp::init_iterations_logger | ( | FILE_SPEC *& | logger, |
const char * | filename | ||
) |
init a logger for solver iterations
void opencarp::init_stim_info | ( | void | ) |
< transmembrane current
< extracellular current, volumetric source density
< extracellular voltage, closed loop
< ground (extracellular voltage)
< intracellular current
< extracellular voltage, open loop
<
< acts as transmembrane current stimulus
< clamps transmembrane voltate
< extracellular voltage, open loop
Definition at line 49 of file stimulate.cc.
void opencarp::init_sv_gvec | ( | gvec_data & | GVs, |
limpet::MULTI_IF * | miif, | ||
sf_vec & | tmpl, | ||
igb_output_manager & | output_manager | ||
) |
initialize the global state variable dumps
GVs | SV dumps |
miif | ionic models |
purk | Purkine system |
tmo | timer |
grid | on what to output |
tmpl | template vector to decide on parallel layout |
Definition at line 560 of file ionics.cc.
void opencarp::initialize_physics | ( | ) |
Initialize all physics in the registry.
Definition at line 100 of file sim_utils.cc.
void opencarp::initialize_sv_dumps | ( | limpet::MULTI_IF * | pmiif, |
IMPregion * | reg, | ||
int | id, | ||
double | t, | ||
double | dump_dt | ||
) |
bool opencarp::is_big_endian | ( | ) |
bool opencarp::is_current | ( | stim_t | type | ) |
uses current as stimulation
Definition at line 71 of file stimulate.cc.
bool opencarp::is_dbc | ( | stim_t | type | ) |
whether stimulus is a dirichlet type. implies boundary conditions on matrix
Definition at line 76 of file stimulate.cc.
bool opencarp::is_extra | ( | stim_t | type | ) |
whether stimulus is on extra grid (or on intra)
Definition at line 81 of file stimulate.cc.
bool opencarp::is_voltage | ( | stim_t | type | ) |
uses voltage as stimulation
type | uses voltage as stimulation |
Definition at line 65 of file stimulate.cc.
|
inline |
void opencarp::log_msg | ( | FILE_SPEC | out, |
int | level, | ||
unsigned char | flag, | ||
const char * | fmt, | ||
... | |||
) |
output message into a log file
out | output location, NULL implies ECHO |
level | Severity level of message (0-5) |
flags | the following may be or'ed:
|
fmt | format string for printf |
... | values for format string |
message
prepended with the level.NONL
is specified _hdf5_out
must be set before this routine is called fmt
to NULL
|
inline |
|
inline |
|
inline |
bool opencarp::mesh_is_registered | ( | const mesh_t | gt | ) |
check wheter a SF mesh is set
Definition at line 59 of file sf_interface.cc.
int opencarp::my_fputs | ( | FILE * | , |
char * | |||
) |
int opencarp::output_all_activations | ( | FILE_SPEC | fp, |
int * | ibuf, | ||
double * | act_tbuf, | ||
int | nlacts | ||
) |
void opencarp::output_meshes | ( | ) |
Output the meshes specified by the user
Definition at line 1164 of file sim_utils.cc.
void opencarp::output_parameter_file | ( | const char * | fname, |
int | argc, | ||
char ** | argv | ||
) |
output the command line and convert to a single parameter file
This involves including any parameter files specified with +F and stripping hyphens from command line options
fname | output file name |
argc | number of arguments |
argv | arguments |
Definition at line 1517 of file sim_utils.cc.
void opencarp::parse_comment_line | ( | char * | buff, |
const int | buffsize, | ||
std::map< std::string, std::string > & | metadata | ||
) |
void opencarp::parse_mesh_types | ( | ) |
Parse the phys_type CLI parameters and set up (empty) SF::meshdata meshes.
Definition at line 854 of file sim_utils.cc.
void opencarp::parse_params_cpy | ( | int | argc, |
char ** | argv | ||
) |
Initialize input parameters on a copy of the real command line parameters.
argc | The true parameter count. |
argv | The true cli parameters. |
Definition at line 46 of file sim_utils.cc.
bool opencarp::path_is_absolute | ( | const char * | path | ) |
int opencarp::plot_protocols | ( | const char * | ) |
plot simulation protocols (I/O timers, stimuli, boundary conditions, etc)
plot experimental/simulation protocols by stepping through all timers
Definition at line 536 of file sim_utils.cc.
bool opencarp::point_in_shape | ( | const Point & | p, |
const geom_shape & | shape | ||
) |
void opencarp::post_process | ( | ) |
do postprocessing
Definition at line 802 of file sim_utils.cc.
int opencarp::postproc_recover_phie | ( | ) |
void opencarp::print_act_log | ( | FILE_SPEC | logger, |
const SF::vector< Activation > & | acts, | ||
int | idx | ||
) |
void opencarp::print_element_info | ( | const SF::element_view< mesh_int_t, mesh_real_t > & | elem, |
const int * | reg, | ||
const double | vol, | ||
const double * | eVals, | ||
const char * | msg_start | ||
) |
void opencarp::print_points | ( | SF::Point * | pts, |
int | npts | ||
) |
char * opencarp::read_bin_string | ( | FILE_SPEC | in | ) |
char * opencarp::read_bin_string_par | ( | FILE_SPEC | in | ) |
int opencarp::read_IGB_data | ( | T * | dp, |
int | numt, | ||
IGBheader * | h, | ||
char * | buf = NULL |
||
) |
|
inline |
Read indices from a file.
T | The index type. |
[out] | idx | Vector with indices in local indexing. |
[in] | filename | File path to read from. |
[in] | dd_map | Global to local map. |
[in] | comm | MPI communicator |
Definition at line 120 of file fem_utils.h.
|
inline |
Read indices from a file.
The global indices are mapped by a global-to-local map constrcuted from mesh, numbering and algebraic flag.
T | The index type. |
[out] | idx | Vector with indices in local indexing. |
[in] | filename | File path to read from. |
[in] | mesh | The local mesh we localize on. |
[in] | nbr | The numbering we localize for. |
[in] | algebraic | Whether to keep the data nodal (overlapping) or algebraic (non-overlapping) |
[in] | comm | MPI communicator |
Definition at line 216 of file fem_utils.h.
|
inline |
Read indices from a file.
The global indices are mapped by a global-to-local map constrcuted from a indexing vector.
T | The index type. |
[out] | idx | Vector with indices in local indexing. |
[in] | filename | File path to read from. |
[in] | dd_nbr | Indexing vector used to construct global-to-local map. |
[in] | comm | MPI communicator |
Definition at line 254 of file fem_utils.h.
|
inline |
Definition at line 53 of file fem_utils.h.
|
inline |
like read_indices, but with associated data for each index
Definition at line 269 of file fem_utils.h.
|
inline |
like read_indices, but with associated data for each index
Definition at line 375 of file fem_utils.h.
|
inline |
like read_indices, but with associated data for each index
Definition at line 403 of file fem_utils.h.
void opencarp::read_metadata | ( | const std::string | filename, |
std::map< std::string, std::string > & | metadata, | ||
MPI_Comm | comm | ||
) |
Read metadata from the header.
filename | Filename to read from. |
metadata | Metadata we populate. |
comm | MPI communicator to use for parallel communication. |
Definition at line 72 of file fem_utils.cc.
void opencarp::recover_phie_std | ( | sf_vec & | vm, |
phie_recovery_data & | rcv | ||
) |
void opencarp::region_mask | ( | mesh_t | meshspec, |
SF::vector< RegionSpecs > & | regspec, | ||
SF::vector< int > & | regionIDs, | ||
bool | mask_elem, | ||
const char * | reglist | ||
) |
classify elements/points as belonging to a region
Element tags in the elem files are grouped to construct regions. If points are to be assigned to a region, points on the boundary between regions belong to several regions. In this case, the point is assigned to the region with the highest number
meshspec | Identifier for the mesh we work on. |
regspec | Vector or region spec structs |
regionIDs | Vector of element/nodal IDs (mapping into the region spec vec). |
mask_elem | Whether we mask elements or points. |
reglist | A string naming to region we work on for output. |
Definition at line 356 of file ionics.cc.
Register a data vector in the global registry.
dat | A pointer to the data vector. |
d | The identifier of the data vector. |
Definition at line 844 of file sim_utils.cc.
SF::scattering * opencarp::register_permutation | ( | const int | mesh_id, |
const int | perm_id, | ||
const int | dpn | ||
) |
Register a permutation between two orderings for a mesh.
mesh_id | The mesh we register the permutation for. |
perm_id | The permutation specifier index (see sf_interface.h). |
dpn | Degrees of freedom per node. |
Definition at line 141 of file sf_interface.cc.
void opencarp::register_physics | ( | ) |
Register physics to the physics registry.
Definition at line 89 of file sim_utils.cc.
SF::scattering * opencarp::register_scattering | ( | const int | from, |
const int | to, | ||
const SF::SF_nbr | nbr, | ||
const int | dpn | ||
) |
Register a scattering between to grids, or between algebraic and nodal representation of data on the same grid.
from | The mesh ID we scatter from. |
to | The mesh ID we scatter to, or ALG_TO_NODAL. |
nbr | The used numbering. |
dpn | The degrees of freedom per node. |
Definition at line 65 of file sf_interface.cc.
|
inline |
Definition at line 122 of file sf_interface.h.
|
inline |
|
inline |
size_t opencarp::renormalise_fibres | ( | SF::vector< mesh_real_t > & | fib, |
size_t | l_numelem | ||
) |
void opencarp::retag_elements | ( | sf_mesh & | mesh, |
TagRegion * | tagRegs, | ||
int | ntr | ||
) |
retag elements based on user defined regions
nl | node list |
elist | Element list |
tagreg | tag regions |
ntr | #tag regions |
elst->Elemtags
will be altered Definition at line 913 of file sim_utils.cc.
void opencarp::sample_wave_form | ( | stim_pulse & | sp, |
int | idx | ||
) |
sample a signal given in analytic form
Sample a stim pulse wave form.
sp | stimulus pulse to be sampled |
idx | index of stimulus definition in stimulus array |
sp | Stim pulse struct. |
idx | param_globals stimulus index. |
Definition at line 365 of file stimulate.cc.
void opencarp::savequit | ( | ) |
save state and quit simulator
Definition at line 1602 of file sim_utils.cc.
void opencarp::set_cond_type | ( | MaterialType & | m, |
cond_t | type | ||
) |
set conductivity tensor modifier type for each material in a grid
[in] | m | electrical material properties |
[in] | type | modifier type, rule for assembling the tensor |
Definition at line 803 of file electrics.cc.
int opencarp::set_dir | ( | IO_t | dest | ) |
set the current working directory
dest | either INPUT, OUTPUT or POSTPROC |
Definition at line 446 of file sim_utils.cc.
void opencarp::set_elec_tissue_properties | ( | MaterialType * | mtype, |
Electrics::grid_t | g, | ||
FILE_SPEC | logger | ||
) |
Fill the RegionSpec of an electrics grid with the associated inputs from the param parameters.
g | The electrics grid we want to set up. |
Definition at line 100 of file electrics.cc.
int opencarp::set_ignore_flags | ( | int | mode | ) |
set flags to select which extracellular stimuli types are ignored and convert intracellular current injection to transmembrane
mode | simulation modes (MONODOMAIN, BIDOMAIN, PSEUDO_BIDM) |
Definition at line 177 of file sim_utils.cc.
void opencarp::set_io_dirs | ( | char * | sim_ID, |
char * | pp_ID, | ||
IO_t | init | ||
) |
set the I/O directories
argc | #words on command line |
argv | the words |
sim_ID | ID for naming output dir |
pp_ID | ID for naming the postprocessing directory |
Definition at line 317 of file sim_utils.cc.
void opencarp::setup_dataout | ( | const int | dataout, |
std::string | dataout_vtx, | ||
mesh_t | grid, | ||
SF::vector< mesh_int_t > *& | restr, | ||
bool | async = false |
||
) |
setup the restriction indices vector. the indices we store depends on how we do output, see below.
Definition at line 592 of file electrics.cc.
bool opencarp::setup_IO | ( | int | argc, |
char ** | argv | ||
) |
void opencarp::setup_meshes | ( | ) |
Read in the reference mesh and use its data to populate all meshes registered in the mesh registry.
Definition at line 986 of file sim_utils.cc.
void opencarp::setup_petsc_err_log | ( | ) |
set up error logs for PETSc, so that it doesnt print errors to stderr.
Definition at line 1240 of file sim_utils.cc.
void opencarp::setup_phie_recovery_data | ( | phie_recovery_data & | data | ) |
void opencarp::show_build_info | ( | ) |
show the build info, exit if -buildinfo was provided. This code runs before MPI_Init().
Definition at line 219 of file sim_utils.cc.
void opencarp::simulate | ( | ) |
Main simulate loop.
Definition at line 754 of file sim_utils.cc.
char * opencarp::skip_comments | ( | FILE_SPEC | stream, |
char * | readbuff, | ||
size_t | buffsize, | ||
MPI_Comm | comm | ||
) |
void opencarp::sltlst_append | ( | Salt_list * | sl, |
void * | p, | ||
int | quantum | ||
) |
void opencarp::split_string | ( | const std::string & | input, |
const char | s, | ||
STRVEC & | list | ||
) |
Split a string holding a character-seperated list into a vector of strings.
STRVEC | vector-of-string type, e.g. std::vector<std::string> or SF::vector<std::string> |
[in] | input | string holding list |
[in] | s | character delimiting the list entries |
[out] | list | the parsed list |
Definition at line 103 of file basics.h.
int opencarp::stimidx_from_timeridx | ( | const SF::vector< stimulus > & | stimuli, |
const int | timer_id | ||
) |
determine link between timer and stimulus
figure out stimulus index linked to a given timer
Definition at line 751 of file electrics.cc.
char * opencarp::stringify | ( | double | r | ) |
void opencarp::time_to_string | ( | float | time, |
char * | str, | ||
short | str_size | ||
) |
|
inline |
void opencarp::update_console_output | ( | const timer_manager & | tm, |
prog_stats & | p | ||
) |
void opencarp::update_cwd | ( | ) |
save the current working directory to curdir so that we can switch back to it if needed.
Definition at line 441 of file sim_utils.cc.
|
inline |
|
inline |
void opencarp::warn_when_passing_intra_vtx | ( | const std::string | filename | ) |
void opencarp::write_bin_string | ( | FILE_SPEC | out, |
const char * | s | ||
) |
const uint16_t opencarp::basetable |
Definition at line 23 of file short_float.cc.
unsigned short opencarp::Data_Size |
Definition at line 264 of file IGBheader.cc.
const char* opencarp::deprecated[] |
list of deprecated keywords
Definition at line 259 of file IGBheader.cc.
const uint32_t opencarp::exponenttable |
Definition at line 3171 of file short_float.cc.
char opencarp::Header_Message |
Definition at line 247 of file IGBheader.cc.
bool opencarp::Header_Quiet = false |
Definition at line 246 of file IGBheader.cc.
const char * opencarp::Header_Systeme |
Definition at line 289 of file IGBheader.cc.
unsigned long opencarp::Header_Systeme_No |
Definition at line 282 of file IGBheader.cc.
const char * opencarp::Header_Type |
Definition at line 249 of file IGBheader.cc.
const uint32_t opencarp::mantissatable |
Definition at line 1053 of file short_float.cc.
int opencarp::Num_Components |
the number of components for each data type
Definition at line 275 of file IGBheader.cc.
const uint16_t opencarp::offsettable |
Definition at line 3104 of file short_float.cc.
const uint16_t opencarp::shifttable |
Definition at line 538 of file short_float.cc.
const std::string opencarp::wfLabels[] = {"squarePulse", "truncExpPulse", "sinePulse", "arbPulse"} |
Definition at line 80 of file stimulate.h.