33 template<
typename PbType>
40 if (p->
hasKey(
"activation time data"))
45 CepsString command =
"cp " + amap + ext +
" " + dir +
"/" + base +
"_APD_"
49 if (p->
hasKey(
"probe points"))
51 CepsString command =
"cp " + dir +
"/" + base +
"_probes.dat "
58 template<
typename PbType>
84 runConvergenceT<DirichletAnodeCathodeProblem>(p);
86 runConvergenceT<FluxAnodeCathodeProblem>(p);
88 runConvergenceT<MonodomainProblem>(p,
true,
true);
90 runConvergenceT<CLMonodomainProblem>(p,
true,
true);
92 runConvergenceT<BidomainProblem>(p,
true,
true);
94 runConvergenceT<ExtendedBidomainProblem>(p,
true,
true);
96 runConvergenceT<BilayerMonodomainProblem>(p,
true,
true);
98 runConvergenceT<PacemakerBidomainProblem>(p,
true,
true);
100 runConvergenceT<PacemakerPoissonProblem>(p,
true,
true);
103 "Unknown type of problem " << s <<
"\n" <<
constexpr const char * validProblems
#define CEPS_ABORT(message)
Stops the execution with a message. If testing is enabled, only throws a runtime_error.
std::basic_string< CepsChar > CepsString
C++ format string.
float CepsReal
Need single precision floating point.
Generic class that regroups common elements of convergence studies.
void setCallBackMethod(std::function< void(ConvergenceStudy< PdeProblem_t > *, CepsReal, CepsReal)>)
Determines the method that is called after computation of each numerical solution.
void run()
Runs the study.
InputParameters * getParameters() const
Link to parameters.
CepsString getDir(const CepsString &str)
Get a substring of s, from beginning of s to the last '/' character. Example: "/home/someone/file....
CepsString execute(CepsString command, CepsBool withErr=false, CepsBool abortOnErr=false)
Not really a parallel thing. Calls system() and deals with return code.
CepsString toString(_Tp value)
Convert a given value to a string (input has to be compatible with std::to_string)
CepsString toKey(const CepsString &s)
Transform to key type a std::string, upper case and no spaces.
CepsBool isMaster()
Is calling process the master ?
CepsString getBaseName(const CepsString &str)
Extracts the base of a file name, without path, nor extension. Ex: getBaseName("/path/to/myfile....
void destroyObject(_Type &)
Destroy[delete] any type.
CepsBool fileExists(const CepsString &fileName, const CepsString &directory)
void doConvergence(InputParameters *p)
Runs a convergence analysis Problem type deduced from input string in InputParameters.
void runConvergenceT(InputParameters *p, CepsBool refSol, CepsBool copyMap)
Runs a convergence analysis; templated on problem type.
void copyActivationMap(ConvergenceStudy< PbType > *cs, CepsReal dt, CepsReal hmax)
Callback functions that saves activation maps from cvNum directory to avoid overwriting.