36 #include "MonodomainPurkinjeProblem.hpp" 37 #include "MonodomainPurkinjeSolver.hpp" 39 #include "ReplicatableVector.hpp" 42 template<
unsigned ELEMENT_DIM,
unsigned SPACE_DIM>
49 template<
unsigned ELEMENT_DIM,
unsigned SPACE_DIM>
59 this->mpBoundaryConditionsContainer.get());
62 template<
unsigned ELEMENT_DIM,
unsigned SPACE_DIM>
69 template<
unsigned ELEMENT_DIM,
unsigned SPACE_DIM>
75 DistributedVector ic = this->mpMesh->GetDistributedVectorFactory()->CreateDistributedVector(init_cond);
82 purkinje_voltage_stripe[index] = this->GetTissue()->GetPurkinjeCell(index.Global)->GetVoltage();
92 template<
unsigned ELEMENT_DIM,
unsigned SPACE_DIM>
101 template<
unsigned ELEMENT_DIM,
unsigned SPACE_DIM>
109 template<
unsigned ELEMENT_DIM,
unsigned SPACE_DIM>
115 template<
unsigned ELEMENT_DIM,
unsigned SPACE_DIM>
120 std::cout <<
"Solved to time " << time <<
"\n" << std::flush;
123 double v_max, v_min, v_purk_max, v_purk_min;
125 VecStrideMax( this->
mSolution, 0, PETSC_NULL, &v_max );
126 VecStrideMin( this->
mSolution, 0, PETSC_NULL, &v_min );
128 VecStrideMax( this->
mSolution, 1, PETSC_NULL, &v_purk_max );
129 VecStrideMin( this->
mSolution, 1, PETSC_NULL, &v_purk_min );
132 if(fabs(v_purk_min)<1e-20)
138 if(fabs(v_purk_max)<1e-20)
145 std::cout <<
" V_myo; V_purk = " <<
"[" <<v_min <<
", " << v_max <<
"]" <<
";\t" 146 <<
"[" << v_purk_min <<
", " << v_purk_max <<
"]" <<
"\n" 152 template<
unsigned ELEMENT_DIM,
unsigned SPACE_DIM>
168 template<
unsigned ELEMENT_DIM,
unsigned SPACE_DIM>
172 std::vector<int> variable_ids;
Hdf5DataWriter * mpWriter
unsigned mVoltageColumnId
int GetVariableByName(const std::string &rVariableName)
unsigned mPurkinjeVoltageColumnId
virtual Vec CreateInitialCondition()
DistributedTetrahedralMeshPartitionType::type GetMeshPartitioning() const
AbstractCardiacTissue< ELEMENT_DIM, SPACE_DIM > * CreateCardiacTissue()
virtual void DefineWriterColumns(bool extending)
virtual ~MonodomainPurkinjeProblem()
bool GetUseStateVariableInterpolation() const
MonodomainPurkinjeProblem()
#define EXPORT_TEMPLATE_CLASS2(CLASS, E, S)
const unsigned UNSIGNED_UNSET
Vec CreateInitialCondition()
int DefineVariable(const std::string &rVariableName, const std::string &rVariableUnits)
AbstractDynamicLinearPdeSolver< ELEMENT_DIM, SPACE_DIM, 2 > * CreateSolver()
#define EXCEPT_IF_NOT(test)
virtual void DefineWriterColumns(bool extending)
virtual void CreateMeshFromHeartConfig()
virtual void WriteOneStep(double time, Vec voltageVec)
void PutStripedVector(std::vector< int > variableIDs, Vec petscVector)
void WriteInfo(double time)
void WriteExtraVariablesOneStep()
void PutUnlimitedVariable(double value)
static HeartConfig * Instance()
void DefineExtraVariablesWriterColumns(bool extending)