45 #ifndef _ELECTROETABIDOMAINSOLVER_H_ 46 #define _ELECTROETABIDOMAINSOLVER_H_ 50 #include <Epetra_MpiComm.h> 52 #include <Epetra_SerialComm.h> 56 #include <lifev/core/fem/BCManage.hpp> 57 #include <lifev/core/filter/ExporterEnsight.hpp> 59 #include <lifev/core/filter/ExporterHDF5.hpp> 61 #include <lifev/core/filter/ExporterEmpty.hpp> 63 #include <Epetra_LocalMap.h> 65 #include <lifev/core/array/MatrixElemental.hpp> 66 #include <lifev/core/array/MatrixSmall.hpp> 68 #include <lifev/core/algorithm/SolverAztecOO.hpp> 69 #include <lifev/core/array/MapEpetra.hpp> 70 #include <lifev/core/array/MatrixEpetra.hpp> 71 #include <lifev/core/array/MatrixEpetraStructured.hpp> 72 #include <lifev/core/array/VectorEpetra.hpp> 73 #include <lifev/core/array/VectorEpetraStructured.hpp> 74 #include <lifev/core/array/MatrixEpetraStructuredUtility.hpp> 75 #include <lifev/core/fem/SobolevNorms.hpp> 76 #include <lifev/core/fem/GeometricMap.hpp> 77 #include <lifev/electrophysiology/solver/IonicModels/ElectroIonicModel.hpp> 79 #include <lifev/core/util/LifeChrono.hpp> 80 #include <lifev/core/fem/FESpace.hpp> 81 #include <lifev/electrophysiology/util/HeartUtility.hpp> 83 #include <Teuchos_RCP.hpp> 84 #include <Teuchos_ParameterList.hpp> 85 #include "Teuchos_XMLParameterListHelpers.hpp" 87 #include <lifev/eta/fem/ETFESpace.hpp> 88 #include <lifev/eta/expression/Integrate.hpp> 89 #include <lifev/core/mesh/MeshLoadingUtility.hpp> 91 #include <lifev/core/algorithm/LinearSolver.hpp> 92 #include <lifev/core/algorithm/Preconditioner.hpp> 93 #include <lifev/core/algorithm/PreconditionerML.hpp> 94 #include <lifev/core/algorithm/PreconditionerIfpack.hpp> 96 #include <boost/typeof/typeof.hpp> 98 #include <lifev/core/fem/GradientRecovery.hpp> 105 template<
typename Mesh,
typename IonicModel>
318 return M_elementsOrder;
405 return M_ionicModelPtr->appliedCurrentPtr();
450 this->M_surfaceVolumeRatio = p;
459 this->M_initialTime = p;
467 this->M_timeStep = p;
483 this->M_diffusionTensorIntra = p;
491 this->M_diffusionTensorExtra = p;
500 this->M_ionicModelPtr = p;
517 this->M_localMeshPtr = p;
525 this->M_fullMeshPtr = p;
533 this->M_ETFESpacePtr = p;
541 this->M_feSpacePtr = p;
550 this->M_massMatrixPtr = p;
558 this->M_stiffnessMatrixPtr = p;
566 this->M_globalMatrixPtr = p;
582 this->M_rhsPtrUnique = p;
587 this->M_potentialExtraPtr = p;
588 this->M_potentialGlobalPtr->replace ( (*p),
this->M_potentialGlobalPtr->block (1)->firstIndex);
593 this->M_potentialTransPtr = p;
594 this->M_potentialGlobalPtr->replace ( (*p),
this->M_potentialGlobalPtr->block (0)->firstIndex() );
604 M_ionicModelPtr->setAppliedCurrentPtr (p);
613 this->M_linearSolverPtr = p;
621 this->M_globalSolution = p;
629 this->M_globalRhs = p;
637 this->M_fiberPtr = p;
642 this->M_displacementPtr = p;
651 (* (M_ionicModelPtr) ) = p;
655 (* (M_commPtr) ) = p;
659 (* (M_localMeshPtr) ) = p;
663 (* (M_fullMeshPtr) ) = p;
667 (* (M_ETFESpacePtr) ) = p;
671 (* (M_feSpacePtr) ) = p;
675 (* (M_massMatrixPtr) ) = p;
679 (* (M_stiffnessMatrixPtr) ) = p;
683 (* (M_globalMatrixPtr) ) = p;
691 (* (M_rhsPtrUnique) ) = p;
695 (* (M_potentialTransPtr) ) = p;
696 this->M_potentialGlobalPtr->replace (p,
this->M_potentialGlobalPtr->block (0)->firstIndex() );
700 (* (M_potentialExtraPtr) ) = p;
701 this->M_potentialGlobalPtr->replace (p,
this->M_potentialGlobalPtr->block (1)->firstIndex() );
705 (* (M_fiberPtr) ) = p;
709 (* (M_displacementPtr) ) = p;
713 M_ionicModelPtr->setAppliedCurrent (p);
717 (* (M_linearSolverPtr) ) = p;
721 for (
int j = 0; j < M_ionicModelPtr->Size(); j++)
723 (* (M_globalSolution.at (j) ) ) = (* (p.at (j) ) );
729 M_globalSolution.at (j) = p;
734 for (
int j = 0; j < M_ionicModelPtr->Size(); j++)
736 (* (M_globalRhs.at (j) ) ) = (* (p.at (j) ) );
751 void setup (
GetPot& dataFile,
short int ionicSize);
753 void setup (std::string meshName, std::string meshPath,
GetPot& dataFile,
754 short int ionicSize);
788 (*M_potentialTransPtr) *= 0;
789 (*M_potentialExtraPtr) *= 0;
790 (*M_potentialGlobalPtr) *= 0;
795 (* (M_globalSolution.at (0) ) ) = k;
796 this->M_potentialGlobalPtr->replace ( (* (M_globalSolution.at (0) ) ),
this->M_potentialGlobalPtr->block (0)->firstIndex);
801 (*M_potentialExtraPtr) = k;
802 this->M_potentialGlobalPtr->replace ( (*M_potentialExtraPtr),
this->M_potentialGlobalPtr->block (1)->firstIndex);
809 (* (M_ionicModelPtr->appliedCurrentPtr() ) ) *= 0;
815 (* (M_ionicModelPtr->appliedCurrentPtr() ) ) = k;
834 MeshUtility::loadMesh (M_localMeshPtr, M_fullMeshPtr, meshName,
840 M_feSpacePtr->interpolate (
841 static_cast<FESpace<RegionMesh<LinearTetra>, MapEpetra>::function_Type> (f),
842 * (M_globalSolution.at (0) ), time);
847 M_feSpacePtr->interpolate (
848 static_cast<FESpace<RegionMesh<LinearTetra>, MapEpetra>::function_Type> (f),
849 *M_potentialExtraPtr, time);
855 M_ionicModelPtr->setAppliedCurrentFromFunction (f, M_feSpacePtr, time);
876 M_massMatrixPtr -> multiply (
false, (*M_potentialGlobalPtr) * (M_ionicModelPtr -> membraneCapacitance() / (M_timeStep) ), *tmp );
877 (*M_rhsPtrUnique) += (*tmp);
928 std::string folder =
"./");
937 ElectrophysiologyUtility::importFibers (M_fiberPtr, fibersFile, M_localMeshPtr);
941 inline void setupFibers (std::string fibersFile, std::string directory,
944 ElectrophysiologyUtility::importFibersFromTextFile (M_fiberPtr, fibersFile,
1006 exporter.postProcess (t);
1010 std::string postDir,
Real time);
1014 M_ionicModelPtr->initialize (M_globalSolution);
1019 Real threshold = 0.0);
1092 template<
typename Mesh,
typename IonicModel>
1099 template<
typename Mesh,
typename IonicModel>
1104 setParameters (list);
1105 setup (list.get (
"meshName",
"lid16.mesh"), list.get (
"meshPath",
"./"),
1106 dataFile, M_ionicModelPtr->Size() );
1109 template<
typename Mesh,
typename IonicModel>
1114 setParameters (list);
1116 setup (list.get (
"meshName",
"lid16.mesh"), list.get (
"meshPath",
"./"),
1117 dataFile, M_ionicModelPtr->Size() );
1120 template<
typename Mesh,
typename IonicModel>
1125 setParameters (list);
1127 setup (dataFile, M_ionicModelPtr->Size() );
1130 template<
typename Mesh,
typename IonicModel>
1132 std::string meshName, std::string meshPath,
GetPot& dataFile,
1137 setup (meshName, meshPath, dataFile, M_ionicModelPtr->Size() );
1140 template<
typename Mesh,
typename IonicModel>
1142 std::string meshName, std::string meshPath,
GetPot& dataFile,
1148 setup (meshName, meshPath, dataFile, M_ionicModelPtr->Size() );
1151 template<
typename Mesh,
typename IonicModel>
1158 setup (dataFile, M_ionicModelPtr->Size() );
1161 template<
typename Mesh,
typename IonicModel>
1183 if (M_commPtr -> MyPID() == 0)
1185 std::cout <<
"\n WARNING!!! ETA Bidomain Solver: you are using the copy constructor! This method is outdated.";
1186 std::cout <<
"\n WARNING!!! ETA Bidomain Solver: Don't count on it, at this moment. Feel free to update yourself...";
1189 setupGlobalSolution (M_ionicModelPtr->Size() );
1191 setupGlobalRhs (M_ionicModelPtr->Size() );
1195 template<
typename Mesh,
typename IonicModel>
1199 if (M_commPtr -> MyPID() == 0)
1201 std::cout <<
"\n WARNING!!! ETA Bidomain Solver: you are using the assignment operator! This method is outdated.";
1202 std::cout <<
"\n WARNING!!! ETA Bidomain Solver: Don't count on it, at this moment. Feel free to update yourself...";
1221 setPotential (* (solver.M_potentialPtr) );
1226 M_elementsOrder = solver.M_elementsOrder;
1234 template<
typename Mesh,
typename IonicModel>
1238 std::shared_ptr<FESpace<mesh_Type, MapEpetra> > Space3D (
1239 new FESpace<mesh_Type, MapEpetra> (M_localMeshPtr, M_elementsOrder,
1242 M_fiberPtr.reset (
new vector_Type (Space3D->map() ) );
1244 int d1 = (*M_fiberPtr).epetraVector().MyLength() / 3;
1247 for (
int k (0); k < d1; k++)
1249 j = (*M_fiberPtr).blockMap().GID (k + d1);
1250 (*M_fiberPtr) [j] = 1.0;
1254 template<
typename Mesh,
typename IonicModel>
1258 std::shared_ptr<FESpace<mesh_Type, MapEpetra> > Space3D (
1259 new FESpace<mesh_Type, MapEpetra> (M_localMeshPtr, M_elementsOrder,
1262 M_fiberPtr.reset (
new vector_Type (Space3D->map() ) );
1264 ElectrophysiologyUtility::setupFibers (*M_fiberPtr, fibers);
1267 template<
typename Mesh,
typename IonicModel>
1269 std::string postDir)
1271 std::shared_ptr<FESpace<mesh_Type, MapEpetra> > Space3D (
1272 new FESpace<mesh_Type, MapEpetra> (M_localMeshPtr, M_elementsOrder,
1275 ExporterHDF5 < mesh_Type > exp;
1276 exp.setMeshProcId (M_localMeshPtr, M_commPtr->MyPID() );
1277 exp.setPostDir (postDir);
1278 exp.setPrefix (
"FiberDirection");
1279 exp.addVariable (ExporterData<mesh_Type>::VectorField,
"fibers", Space3D,
1280 M_fiberPtr, UInt (0) );
1281 exp.postProcess (0);
1285 template<
typename Mesh,
typename IonicModel>
1289 std::shared_ptr<FESpace<mesh_Type, MapEpetra> > Space3D (
1290 new FESpace<mesh_Type, MapEpetra> (M_localMeshPtr, M_elementsOrder,
1293 exporter.addVariable (ExporterData<mesh_Type>::VectorField,
"fibers",
1294 Space3D, M_fiberPtr, UInt (0) );
1295 exporter.postProcess (0);
1298 template<
typename Mesh,
typename IonicModel>
1300 GetPot& dataFile, std::string prefix, std::string postDir,
Real time)
1302 const std::string exporterType = dataFile (
"exporter/type",
"ensight");
1305 importer->setDataFromGetPot (dataFile);
1306 importer->setPrefix (prefix);
1307 importer->setPostDir (postDir);
1309 importer->setMeshProcId (M_feSpacePtr->mesh(),
1310 M_feSpacePtr->map().comm().MyPID() );
1313 for (i = 0; i < M_ionicModelPtr->Size(); i++)
1314 importer->addVariable (IOData_Type::ScalarField,
1315 "Variable" + number2string (i), M_feSpacePtr,
1316 M_globalSolution.at (i),
static_cast<UInt> (0) );
1317 importer->addVariable (IOData_Type::ScalarField,
"Variable" + number2string (i), M_feSpacePtr, M_potentialExtraPtr,
static_cast<UInt> (0) );
1318 importer->importFromTime (time);
1319 importer->closeFile();
1324 template<
typename Mesh,
typename IonicModel>
1326 short int ionicSize)
1331 M_feSpacePtr.reset (
1332 new feSpace_Type (M_localMeshPtr, M_elementsOrder, 1, M_commPtr) );
1333 M_ETFESpacePtr.reset (
1334 new ETFESpace_Type (M_localMeshPtr, & (M_feSpacePtr -> refFE() ) , M_commPtr) );
1335 M_displacementETFESpacePtr.reset (
1336 new ETFESpaceVectorial_Type (M_localMeshPtr, & (M_feSpacePtr -> refFE() ), M_commPtr) );
1338 M_massMatrixPtr.reset (
new blockMatrix_Type (M_ETFESpacePtr->map() | M_ETFESpacePtr->map() ) );
1339 M_stiffnessMatrixPtr.reset (
new blockMatrix_Type (M_ETFESpacePtr->map() | M_ETFESpacePtr->map() ) );
1340 M_globalMatrixPtr.reset (
new blockMatrix_Type (M_ETFESpacePtr->map() | M_ETFESpacePtr->map() ) );
1342 M_rhsPtr.reset (
new blockVector_Type (M_ETFESpacePtr->map() | M_ETFESpacePtr->map(), Repeated) );
1343 M_rhsPtrUnique.reset (
new blockVector_Type (M_ETFESpacePtr->map() | M_ETFESpacePtr->map(), Unique) );
1344 M_potentialGlobalPtr.reset (
new blockVector_Type (M_ETFESpacePtr->map() | M_ETFESpacePtr->map() ) );
1345 M_potentialTransPtr.reset (
new vector_Type (M_ETFESpacePtr->map() ) );
1346 M_potentialExtraPtr.reset (
new vector_Type (M_ETFESpacePtr->map() ) );
1352 setupLinearSolver (dataFile);
1360 M_ionicModelPtr->setAppliedCurrent (Iapp);
1366 template<
typename Mesh,
typename IonicModel>
1368 std::string meshPath,
GetPot& dataFile,
short int ionicSize)
1371 partitionMesh (meshName, meshPath);
1376 template<
typename Mesh,
typename IonicModel>
1386 setupLumpedMassMatrix();
1392 setupMassMatrix (*M_displacementPtr);
1396 *M_massMatrixPtr *= 0.0;
1397 if (M_localMeshPtr->comm()->MyPID() == 0)
1399 std::cout <<
"\nETA Bidomain Solver: Setting up mass matrix";
1404 integrate (elements (M_localMeshPtr), M_feSpacePtr->qr(),
1405 M_ETFESpacePtr, M_ETFESpacePtr, phi_i * phi_j)
1406 >> M_massMatrixPtr->block (0, 0);
1409 M_massMatrixPtr->globalAssemble();
1415 template<
typename Mesh,
typename IonicModel>
1419 if (M_commPtr->MyPID() == 0)
1421 std::cout <<
"\nETA Bidomain Solver: Setting up mass matrix with coupling with mechanics ";
1424 *M_massMatrixPtr *= 0.0;
1425 ETFESpaceVectorialPtr_Type spaceVectorial (
new ETFESpaceVectorial_Type ( M_localMeshPtr, & (M_feSpacePtr -> refFE() ), M_commPtr ) );
1429 BOOST_AUTO_TPL (I, value (M_identity) );
1430 BOOST_AUTO_TPL (Grad_u, grad (spaceVectorial, disp) );
1431 BOOST_AUTO_TPL (F, (Grad_u + I) );
1432 BOOST_AUTO_TPL (J, det (F) );
1433 integrate (elements (M_localMeshPtr), M_feSpacePtr->qr(), M_ETFESpacePtr,
1434 M_ETFESpacePtr, J * phi_i * phi_j)
1435 >> M_massMatrixPtr->block (0, 0);
1438 M_massMatrixPtr->globalAssemble();
1442 template<
typename Mesh,
typename IonicModel>
1449 setupLumpedMassMatrix (*M_displacementPtr);
1453 *M_massMatrixPtr *= 0.0;
1454 if (M_localMeshPtr->comm()->MyPID() == 0)
1456 std::cout <<
"\nETA Bidomain Solver: Setting up lumped mass matrix";
1461 integrate (elements (M_localMeshPtr), quadRuleTetra4ptNodal,
1462 M_ETFESpacePtr, M_ETFESpacePtr, phi_i * phi_j)
1463 >> M_massMatrixPtr->block (0, 0);
1466 M_massMatrixPtr->globalAssemble();
1473 template<
typename Mesh,
typename IonicModel>
1565 template<
typename Mesh,
typename IonicModel>
1583 template<
typename Mesh,
typename IonicModel>
1588 if (M_localMeshPtr->comm()->MyPID() == 0)
1591 <<
"\nETA Bidomain Solver: Setting up stiffness matrix (only fiber field)";
1594 *M_stiffnessMatrixPtr *= 0.0;
1595 Real sigmal = diffusionIntra
[0
];
1596 Real sigmat = diffusionIntra
[1
];
1599 new ETFESpaceVectorial_Type (M_localMeshPtr, & (M_feSpacePtr -> refFE() ), M_commPtr) );
1601 (
new blockMatrix_Type ( M_ETFESpacePtr->map() ) );
1602 *ETcomponentStiffnessMatrix *= 0.0;
1608 BOOST_AUTO_TPL (I, value (M_identity) );
1609 BOOST_AUTO_TPL (f0, value (spaceVectorial, *M_fiberPtr) );
1612 + (value (sigmal) - value (sigmat) )
1613 * outerProduct (f0, f0) );
1615 integrate (elements (M_localMeshPtr), M_feSpacePtr->qr(), M_ETFESpacePtr,
1617 dot ( D * grad (phi_i), grad (phi_j) ) )
1618 >> ETcomponentStiffnessMatrix->block (0, 0);
1621 ETcomponentStiffnessMatrix->globalAssemble();
1623 MatrixEpetraStructuredUtility::copyBlock (*ETcomponentStiffnessMatrix->block (0, 0), *M_stiffnessMatrixPtr->block (0, 1) );
1624 MatrixEpetraStructuredUtility::copyBlock (*ETcomponentStiffnessMatrix->block (0, 0), *M_stiffnessMatrixPtr->block (1, 0) );
1625 MatrixEpetraStructuredUtility::copyBlock (*ETcomponentStiffnessMatrix->block (0, 0), *M_stiffnessMatrixPtr->block (0, 0) );
1628 sigmal += diffusionExtra
[0
];
1629 sigmat += diffusionExtra
[1
];
1634 BOOST_AUTO_TPL (I, value (M_identity) );
1635 BOOST_AUTO_TPL (f0, value (spaceVectorial, *M_fiberPtr) );
1638 + (value (sigmal) - value (sigmat) )
1639 * outerProduct (f0, f0) ) );
1641 integrate (elements (M_localMeshPtr), M_feSpacePtr->qr(), M_ETFESpacePtr,
1643 dot ( D * grad (phi_i), grad (phi_j) ) )
1644 >> M_stiffnessMatrixPtr->block (1, 1);
1647 M_stiffnessMatrixPtr->globalAssemble();
1654 template<
typename Mesh,
typename IonicModel>
1728 template<
typename Mesh,
typename IonicModel>
1731 (*M_globalMatrixPtr) *= 0;
1732 (*M_globalMatrixPtr) = (*M_stiffnessMatrixPtr);
1733 (*M_globalMatrixPtr) *= 1.0 / M_surfaceVolumeRatio;
1736 (*M_globalMatrixPtr) += ( (*M_massMatrixPtr) * ( M_ionicModelPtr -> membraneCapacitance() / M_timeStep) );
1739 template<
typename Mesh,
typename IonicModel>
1746 precRawPtr =
new prec_Type;
1747 precRawPtr->setDataFromGetPot (dataFile,
"prec");
1748 precPtr.reset (precRawPtr);
1749 Teuchos::RCP < Teuchos::ParameterList > solverParamList = Teuchos::rcp (
1750 new Teuchos::ParameterList);
1752 std::string xmlpath = dataFile (
"electrophysiology/bidomain_xml_path",
1754 std::string xmlfile = dataFile (
"electrophysiology/bidomain_xml_file",
1755 "BidomainSolverParamList.xml");
1757 solverParamList = Teuchos::getParametersFromXmlFile (xmlpath + xmlfile);
1759 M_linearSolverPtr->setCommunicator (M_commPtr);
1760 M_linearSolverPtr->setParameters (*solverParamList);
1761 M_linearSolverPtr->setPreconditioner (precPtr);
1762 M_linearSolverPtr->setOperator (M_globalMatrixPtr);
1765 template<
typename Mesh,
typename IonicModel>
1766 void ElectroETABidomainSolver<Mesh, IonicModel>::setupLinearSolver (
1767 GetPot dataFile, list_Type list)
1770 prec_Type* precRawPtr;
1771 basePrecPtr_Type precPtr;
1772 precRawPtr =
new prec_Type;
1773 precRawPtr->setDataFromGetPot (dataFile,
"prec");
1774 precPtr.reset (precRawPtr);
1776 M_linearSolverPtr->setCommunicator (M_commPtr);
1777 M_linearSolverPtr->setParameters (list);
1778 M_linearSolverPtr->setPreconditioner (precPtr);
1779 M_linearSolverPtr->setOperator (M_globalMatrixPtr);
1782 template<
typename Mesh,
typename IonicModel>
1783 void ElectroETABidomainSolver<Mesh, IonicModel>::setupGlobalSolution (
1784 short int ionicSize)
1787 M_globalSolution.push_back (M_potentialTransPtr);
1789 for (
int k = 1; k < ionicSize; ++k)
1791 M_globalSolution.push_back (
1792 * (
new vectorPtr_Type (
new VectorEpetra (M_ETFESpacePtr->map() ) ) ) );
1796 template<
typename Mesh,
typename IonicModel>
1797 void ElectroETABidomainSolver<Mesh, IonicModel>::setupGlobalRhs (
1798 short int ionicSize)
1800 M_globalRhs.push_back (M_ionicModelPtr->appliedCurrentPtr() );
1801 for (
int k = 1; k < ionicSize; ++k)
1803 M_globalRhs.push_back (
1804 * (
new vectorPtr_Type (
new VectorEpetra (M_ETFESpacePtr->map() ) ) ) );
1810 template<
typename Mesh,
typename IonicModel>
1811 void ElectroETABidomainSolver<Mesh, IonicModel>::solveOneReactionStepFE (
1814 M_ionicModelPtr->superIonicModel::computeRhs (M_globalSolution, M_globalRhs);
1815 for (
int i = 0; i < M_ionicModelPtr->Size(); i++)
1818 * (M_globalSolution.at (i) ) = * (M_globalSolution.at (i) )
1819 + ( (M_timeStep) / subiterations / M_ionicModelPtr -> membraneCapacitance() ) * (* (M_globalRhs.at (i) ) );
1821 * (M_globalSolution.at (i) ) = * (M_globalSolution.at (i) )
1822 + ( (M_timeStep) / subiterations) * (* (M_globalRhs.at (i) ) );
1825 M_potentialGlobalPtr->subset ( (*M_globalSolution.at (0) ), (M_globalSolution.at (0)->map() ), (UInt) 0, (UInt) 0);
1829 template<
typename Mesh,
typename IonicModel>
1830 void ElectroETABidomainSolver<Mesh, IonicModel>::solveOneReactionStepRL (
1833 M_ionicModelPtr->superIonicModel::computeRhs (M_globalSolution, M_globalRhs);
1835 * (M_globalSolution.at (0) ) = * (M_globalSolution.at (0) )
1836 + ( (M_timeStep) / subiterations / M_ionicModelPtr -> membraneCapacitance() ) * (* (M_globalRhs.at (0) ) );
1838 M_ionicModelPtr->superIonicModel::computeGatingVariablesWithRushLarsen (
1839 M_globalSolution, M_timeStep / subiterations);
1840 int offset = M_ionicModelPtr->numberOfGatingVariables() + 1;
1841 for (
int i = offset; i < M_ionicModelPtr->Size(); i++)
1843 * (M_globalSolution.at (i) ) = * (M_globalSolution.at (i) )
1844 + ( (M_timeStep) / subiterations) * (* (M_globalRhs.at (i) ) );
1846 M_potentialGlobalPtr->subset ( (*M_globalRhs.at (0) ), (M_globalRhs.at (0)->map() ), (UInt) 0, (UInt) 0);
1849 template<
typename Mesh,
typename IonicModel>
1850 void ElectroETABidomainSolver<Mesh, IonicModel>::solveOneDiffusionStepBE()
1852 if (M_displacementPtr)
1854 M_linearSolverPtr->setOperator (M_globalMatrixPtr);
1856 M_linearSolverPtr->setRightHandSide (M_rhsPtrUnique);
1857 M_linearSolverPtr->solve (M_potentialGlobalPtr);
1859 M_potentialTransPtr->subset ( (
const VectorEpetra&) (*M_potentialGlobalPtr->block (0)->vectorPtr() ), M_potentialTransPtr->map(), M_potentialGlobalPtr->block (0)->firstIndex(),
static_cast<UInt> (0) );
1860 M_potentialExtraPtr->subset ( (
const VectorEpetra&) (*M_potentialGlobalPtr->block (1)->vectorPtr() ), M_potentialExtraPtr->map(), M_potentialGlobalPtr->block (1)->firstIndex(),
static_cast<UInt> (0) );
1863 template<
typename Mesh,
typename IonicModel>
1864 void ElectroETABidomainSolver<Mesh, IonicModel>::solveOneSplittingStep()
1866 solveOneReactionStepFE();
1867 (*M_rhsPtrUnique) *= 0.0;
1869 solveOneDiffusionStepBE();
1875 template<
typename Mesh,
typename IonicModel>
1876 void ElectroETABidomainSolver<Mesh, IonicModel>::setupPotentialExporter (
1877 IOFile_Type& exporter)
1879 exporter.setMeshProcId (M_localMeshPtr, M_commPtr->MyPID() );
1880 exporter.setPrefix (
"Potential");
1881 exporter.addVariable (ExporterData<mesh_Type>::ScalarField,
"PotentialTransmembrane",
1882 M_feSpacePtr, M_globalSolution.at (0), UInt (0) );
1883 exporter.addVariable (ExporterData<mesh_Type>::ScalarField,
"PotentialExtracellular",
1884 M_feSpacePtr, M_potentialExtraPtr, UInt (0) );
1888 template<
typename Mesh,
typename IonicModel>
1889 void ElectroETABidomainSolver<Mesh, IonicModel>::setupPotentialExporter (
1890 IOFile_Type& exporter, std::string fileName)
1892 exporter.setMeshProcId (M_localMeshPtr, M_commPtr->MyPID() );
1893 exporter.setPrefix (fileName);
1894 exporter.exportPID (M_localMeshPtr, M_commPtr);
1895 exporter.addVariable (ExporterData<mesh_Type>::ScalarField,
"PotentialTransmembrane",
1896 M_feSpacePtr, M_globalSolution.at (0), UInt (0) );
1897 exporter.addVariable (ExporterData<mesh_Type>::ScalarField,
"PotentialExtracellular",
1898 M_feSpacePtr, M_potentialExtraPtr, UInt (0) );
1901 template<
typename Mesh,
typename IonicModel>
1902 void ElectroETABidomainSolver<Mesh, IonicModel>::setupExporter (
1903 IOFile_Type& exporter, std::string fileName, std::string folder)
1905 exporter.setMeshProcId (M_localMeshPtr, M_commPtr->MyPID() );
1906 exporter.setPrefix (fileName);
1907 exporter.exportPID (M_localMeshPtr, M_commPtr);
1908 exporter.setPostDir (folder);
1909 std::string variableName;
1910 for (
int i = 0; i < M_ionicModelPtr->Size(); i++)
1912 variableName =
"Variable" + std::to_string<std::string> (i);
1913 exporter.addVariable (ExporterData<mesh_Type>::ScalarField, variableName,
1914 M_feSpacePtr, M_globalSolution.at (i), UInt (0) );
1916 exporter.addVariable (ExporterData<mesh_Type>::ScalarField,
"PotentialExtracellular",
1917 M_feSpacePtr, M_potentialExtraPtr, UInt (0) );
1921 template<
typename Mesh,
typename IonicModel>
1922 void ElectroETABidomainSolver<Mesh, IonicModel>::init()
1924 M_linearSolverPtr.reset (
new LinearSolver() );
1925 M_globalSolution = * (
new vectorOfPtr_Type() );
1926 M_globalRhs = * (
new vectorOfPtr_Type() );
1927 M_identity (0, 0) = 1.0;
1928 M_identity (0, 1) = 0.0;
1929 M_identity (0, 2) = 0.0;
1930 M_identity (1, 0) = 0.0;
1931 M_identity (1, 1) = 1.0;
1932 M_identity (1, 2) = 0.0;
1933 M_identity (2, 0) = 0.0;
1934 M_identity (2, 1) = 0.0;
1935 M_identity (2, 2) = 1.0;
1938 template<
typename Mesh,
typename IonicModel>
1939 void ElectroETABidomainSolver<Mesh, IonicModel>::init (
1940 ionicModelPtr_Type model)
1943 M_commPtr.reset (
new Epetra_MpiComm (MPI_COMM_WORLD) );
1944 M_localMeshPtr.reset (
new mesh_Type (M_commPtr) );
1945 M_fullMeshPtr.reset (
new mesh_Type (M_commPtr) );
1946 M_ionicModelPtr = model;
1950 template<
typename Mesh,
typename IonicModel>
1951 void ElectroETABidomainSolver<Mesh, IonicModel>::init (commPtr_Type comm)
1955 M_localMeshPtr.reset (
new mesh_Type (M_commPtr) );
1956 M_fullMeshPtr.reset (
new mesh_Type (M_commPtr) );
1959 template<
typename Mesh,
typename IonicModel>
1960 void ElectroETABidomainSolver<Mesh, IonicModel>::init (meshPtr_Type meshPtr)
1964 M_localMeshPtr = meshPtr;
1965 M_fullMeshPtr.reset (
new mesh_Type (M_commPtr) );
1966 M_commPtr = meshPtr->comm();
1969 template<
typename Mesh,
typename IonicModel>
1970 void ElectroETABidomainSolver<Mesh, IonicModel>::init (commPtr_Type comm,
1971 ionicModelPtr_Type model)
1974 M_ionicModelPtr = model;
1977 template<
typename Mesh,
typename IonicModel>
1978 void ElectroETABidomainSolver<Mesh, IonicModel>::init (meshPtr_Type meshPtr,
1979 ionicModelPtr_Type model)
1982 M_ionicModelPtr = model;
1986 template<
typename Mesh,
typename IonicModel>
1987 void ElectroETABidomainSolver<Mesh, IonicModel>::setParameters()
1992 M_surfaceVolumeRatio = 1400.0;
1994 M_diffusionTensorIntra[0] = 1.7;
1995 M_diffusionTensorIntra[1] = 0.19;
1996 M_diffusionTensorIntra[2] = 0.19;
1998 M_diffusionTensorExtra[0] = 6.2;
1999 M_diffusionTensorExtra[1] = 2.4;
2000 M_diffusionTensorExtra[2] = 2.4;
2002 M_initialTime = 0.0;
2005 M_elementsOrder =
"P1";
2006 M_lumpedMassMatrix =
false;
2010 template<
typename Mesh,
typename IonicModel>
2011 void ElectroETABidomainSolver<Mesh, IonicModel>::setParameters (
2017 M_surfaceVolumeRatio = list.get (
"surfaceVolumeRatio", 1400.0);
2019 M_diffusionTensorIntra[0] = list.get (
"longitudinalDiffusionIntra", 1.7);
2020 M_diffusionTensorIntra[1] = list.get (
"transversalDiffusionIntra", 0.19);
2021 M_diffusionTensorIntra[2] = M_diffusionTensorIntra[1];
2023 M_diffusionTensorExtra[0] = list.get (
"longitudinalDiffusionExtra", 6.2);
2024 M_diffusionTensorExtra[1] = list.get (
"transversalDiffusionExtra", 2.4);
2025 M_diffusionTensorExtra[2] = M_diffusionTensorExtra[1];
2027 M_initialTime = list.get (
"initialTime", 0.0);
2028 M_endTime = list.get (
"endTime", 50.0);
2029 M_timeStep = list.get (
"timeStep", 0.01);
2030 M_elementsOrder = list.get (
"elementsOrder",
"P1");
2031 M_lumpedMassMatrix = list.get (
"LumpedMass",
false);
void setRhs(const vector_Type &p)
VectorEpetra - The Epetra Vector format Wrapper.
blockMatrixPtr_Type M_stiffnessMatrixPtr
void setup(GetPot &dataFile, short int ionicSize)
void setPotentialTransPtr(const vectorPtr_Type p)
LifeV::PreconditionerML prec_Type
void exportFiberDirection(IOFile_Type &exporter)
save the fiber direction into the given exporter
blockVectorPtr_Type M_rhsPtrUnique
void copyGlobalRhs(const vectorOfPtr_Type &p)
LifeV::Preconditioner basePrec_Type
Real M_surfaceVolumeRatio
void solveOneSVIStep(IOFile_Type &exporter, Real t)
Solve one full step with ionic current interpolation and export the solution.
void setIonicModel(const ionicModel_Type &p)
void setCommPtr(const commPtr_Type p)
set the pointer to the Epetra communicator
meshPtr_Type M_fullMeshPtr
void setSurfaceVolumeRatio(const Real &p)
set the surface to volume ratio
void setupStiffnessMatrix(VectorSmall< 3 > diffusionIntra, VectorSmall< 3 > diffusionExtra)
create stiffness matrix given a diagonal diffusion tensor
vectorPtr_Type displacementPtr() const
get the pointer to the transmembrane potential
std::shared_ptr< mesh_Type > meshPtr_Type
ElectroETABidomainSolver(list_Type list, GetPot &dataFile, ionicModelPtr_Type model, meshPtr_Type meshPtr)
Constructor.
void solveOneICIStep()
Solve one full step with ionic current interpolation.
void exportFiberDirection(std::string postDir="./")
Generates a file where the fiber direction is saved.
void setETFESpace(const ETFESpace_Type &p)
void solveOneDiffusionStepBE()
Solves one diffusion step using the backward Euler scheme.
virtual ~ElectroETABidomainSolver()
Destructor.
ETFESpaceVectorialPtr_Type M_displacementETFESpacePtr
std::shared_ptr< ETFESpaceVectorial_Type > ETFESpaceVectorialPtr_Type
void setPotentialExtra(const blockVector_Type &p)
ExporterEnsight data exporter.
void setAppliedCurrentIntraPtr(const vectorPtr_Type p)
set the pointer to the intra cell applied current vector
void setInitialConditions()
const linearSolverPtr_Type linearSolverPtr() const
get the pointer to the linear solver
MatrixEpetraStructured< Real > blockMatrix_Type
FESpace - Short description here please!
matrixSmall_Type M_identity
const vectorOfPtr_Type & globalSolution() const
get the pointer to the vector of pointers containing the transmembrane potential (at 0) and the gatin...
void setupLumpedMassMatrix(vector_Type &disp)
Exporter< mesh_Type > IOFile_Type
void setLocalMeshPtr(const meshPtr_Type p)
set the pointer to the partitioned mesh
void setupFibers(std::string fibersFile, std::string directory, int format=0)
Imports the fiber direction from a vtk file ( format = 0), or text file.
bool lumpedMassMatrix() const
void solveSplitting(IOFile_Type &exporter, Real dt)
Solve the system with operator splitting from M_initialTime to the M_endTime with time step M_timeSte...
void setRhsPtr(const blockVectorPtr_Type p)
set the pointer to the right hand side
void setupStiffnessMatrix(vectorPtr_Type disp)
create stiffness matrix in a moving domain
void importFromHDF5(std::string const &fileName, std::string const &matrixName="matrix")
Read a matrix from a HDF5 (.h5) file.
std::shared_ptr< comm_Type > commPtr_Type
void solveOneReactionStepFE(int subiterations=1)
Solves one reaction step using the forward Euler scheme.
void setDiffusionTensorIntra(const VectorSmall< 3 > &p)
set the intra cellular diagonal diffusion tensor
void solveOneReactionStepRL(int subiterations=1)
const vectorOfPtr_Type & globalRhs() const
get the pointer to the vector of pointers containing the rhs for transmembrane potential (at 0) and t...
void initializePotentialTrans(Real k)
Initialize the potential to the value k.
virtual std::vector< std::vector< Real > > getJac(const std::vector< Real > &v, Real h=1.0e-8)
This methods computes the Jacobian numerically.
void updateRhs()
Update the rhs.
void solveICI()
solve system using ICI from M_initialTime to the M_endTime with time step M_timeStep ...
void solveOneSplittingStep()
Solve one full step with operator splitting.
blockVectorPtr_Type M_rhsPtr
void setLinearSolverPtr(const linearSolverPtr_Type p)
set the pointer to the linear solver
std::shared_ptr< matrix_Type > matrixPtr_Type
ElectroETABidomainSolver(std::string meshName, std::string meshPath, GetPot &dataFile, ionicModelPtr_Type model)
Constructor.
ETFESpacePtr_Type M_ETFESpacePtr
std::function< Real(const Real &t, const Real &x, const Real &y, const Real &z, const ID &i) > function_Type
Teuchos::ParameterList list_Type
void setDisplacement(const vector_Type &p)
const commPtr_Type commPtr() const
get the pointer to the Epetra communicator
void solveOneSVIStep()
Solve one full step with ionic current interpolation.
void setAppliedCurrentIntra(const vector_Type &p)
void setupPotentialExporter(IOFile_Type &exporter, std::string fileName)
add to a given exporter the pointer to the potential saved with name fileName
VectorSmall< 3 > M_diffusionTensorExtra
const meshPtr_Type fullMeshPtr() const
get the pointer to the partitioned mesh
void setup(std::string meshName, std::string meshPath, GetPot &dataFile, short int ionicSize)
void solveSplitting(IOFile_Type &exporter)
Solve the system with operator splitting from M_initialTime to the M_endTime with time step M_timeSte...
MatrixEpetra< Real > matrix_Type
vectorPtr_Type M_potentialExtraPtr
void computeRhsICI()
Compute the rhs using ionic current interpolation.
vectorOfPtr_Type M_globalSolution
IonicModel ionicModel_Type
void computeRhsICI(matrix_Type &mass)
const Real & timeStep() const
get the final time
std::shared_ptr< IOFile_Type > IOFilePtr_Type
const VectorSmall< 3 > & diffusionTensorIntra() const
get the diagonal intra cellular diffusion tensor
feSpacePtr_Type M_feSpacePtr
void setVariablePtr(const vectorPtr_Type p, int j)
vectorOfPtr_Type M_globalRhs
void setMassMatrixPtr(const blockMatrixPtr_Type p)
set the pointer to the mass matrix
void setupLinearSolver(GetPot dataFile)
setup the linear solver
blockVectorPtr_Type potentialGlobalPtr()
get the pointer to the potential
void init(meshPtr_Type meshPtr, ionicModelPtr_Type model)
std::shared_ptr< basePrec_Type > basePrecPtr_Type
const vectorPtr_Type potentialTransPtr() const
get the pointer to the transmembrane potential
ElectroETABidomainSolver(GetPot &dataFile, ionicModelPtr_Type model, meshPtr_Type meshPtr)
Constructor.
const Real & endTime() const
get the time step
void setStiffnessMatrix(const matrix_Type &p)
void setPotentialExtraPtr(const vectorPtr_Type p)
void registerActivationTime(vector_Type &activationTimeVector, Real time, Real threshold=0.0)
save the fiber direction into the given exporter
Epetra_Import const & importer()
Getter for the Epetra_Import.
VectorSmall< 3 > M_diffusionTensorIntra
meshPtr_Type M_localMeshPtr
void solveICI(IOFile_Type &exporter)
solve system using ICI from M_initialTime to the M_endTime with time step M_timeStep and export the s...
vectorPtr_Type M_fiberPtr
void setupGlobalMatrix()
create stiffness matrix given the fiber direction and a diagonal diffusion tensor ...
Real & operator[](UInt const &i)
Operator [].
void setDisplacementPtr(const vectorPtr_Type p)
set the pointer to displacement of the tissue
void copyGlobalSolution(const vectorOfPtr_Type &p)
blockVectorPtr_Type M_potentialGlobalPtr
void setupFibers(std::string fibersFile)
Imports the fiber direction from a hdf5 file.
void setupPotentialExporter(IOFile_Type &exporter)
add to a given exporter the pointer to the potential
ElectroETABidomainSolver(const ElectroETABidomainSolver &solver)
Copy Constructor.
void setTimeStep(const Real &p)
set the ending time
ExporterHDF5< mesh_Type > hdf5IOFile_Type
void setupLumpedMassMatrix()
create mass matrix
const vectorPtr_Type potentialExtraPtr() const
get the pointer to the extra cellular potential
void setupMassMatrix(vector_Type &disp)
create mass matrix
void initializeAppliedCurrentIntra(Real k)
Initialize the intra cellular applied current to the value k.
void setInitialTime(const Real &p)
set the starting time
const feSpacePtr_Type feSpacePtr() const
get the pointer to the usual finite element space
blockMatrixPtr_Type M_globalMatrixPtr
void solveOneICIStep(IOFile_Type &exporter, Real t)
Solve one full step with ionic current interpolation and export the solution.
void setComm(const comm_Type &p)
const blockMatrixPtr_Type stiffnessMatrixPtr() const
get the pointer to the stiffness matrix
void setupFibers()
Generates a default fiber direction (0,1,0)
std::shared_ptr< VectorEpetra > vectorPtr_Type
void importFibers(vectorPtr_Type M_fiberPtr, std::string fibersFile, meshPtr_Type M_localMeshPtr)
void setLumpedMassMatrix(bool p) const
void setFiberPtr(const vectorPtr_Type p)
set the pointer to the fiber direction vector
const blockMatrixPtr_Type globalMatrixPtr() const
get the pointer to the global matrix
linearSolverPtr_Type M_linearSolverPtr
const ETFESpacePtr_Type ETFESpacePtr() const
get the pointer to the ETA finite element space
void setAppliedCurrentFromFunctionIntra(function_Type &f, Real time=0.0)
given a boost function initialize the applied intra cellular current
const Real & initialTime() const
get the initial time (by default 0)
void setIonicModelPtr(const ionicModelPtr_Type p)
set the pointer to the ionic model
void setParameters(list_Type list)
Set parameters from an xml file.
std::shared_ptr< blockMatrix_Type > blockMatrixPtr_Type
void setMassMatrix(const matrix_Type &p)
ElectroIonicModel superIonicModel
void setFeSpace(const feSpace_Type &p)
std::string M_elementsOrder
double Real
Generic real data.
void setupFibers(VectorSmall< 3 > fibers)
Generates the fiber direction given the three component of the vector (F_x,F_y,F_z) ...
void importSolution(GetPot &dataFile, std::string prefix, std::string postDir, Real time)
Import solution.
void solveOneICIStep(matrix_Type &mass)
void setupStiffnessMatrix()
create stiffness matrix
vectorPtr_Type M_displacementPtr
MatrixSmall< 3, 3 > matrixSmall_Type
void setFullMesh(const mesh_Type &p)
void setETFESpacePtr(const ETFESpacePtr_Type p)
set the pointer to the ETA fe space
ETFESpace< mesh_Type, MapEpetra, 3, 1 > ETFESpace_Type
LinearSolver linearSolver_Type
blockMatrixPtr_Type M_massMatrixPtr
void setDiffusionTensorExtra(const VectorSmall< 3 > &p)
set the extra cellular diagonal diffusion tensor
void setRhsUnique(const vector_Type &p)
const VectorSmall< 3 > & diffusionTensorExtra() const
get the diagonal extra cellular diffusion tensor
void setupExporter(IOFile_Type &exporter, std::string fileName="output", std::string folder="./")
add to a given exporter the pointer to the potential and to the gating variables saved with name file...
void setPotentialFromFunctionTrans(function_Type &f, Real time=0.0)
given a boost function initialize the transmembrane potential
vectorPtr_Type M_potentialTransPtr
void setFiber(const vector_Type &p)
ETFESpace< mesh_Type, MapEpetra, 3, 3 > ETFESpaceVectorial_Type
void initializePotentialExtra(Real k)
const blockVectorPtr_Type rhsPtrUnique() const
get the pointer to the unique version of the right hand side
const meshPtr_Type localMeshPtr() const
get the pointer to the partitioned mesh
void setGlobalMatrixPtr(const blockMatrixPtr_Type p)
set the pointer to the global matrix
ElectroETABidomainSolver(std::string meshName, std::string meshPath, GetPot &dataFile, ionicModelPtr_Type model, commPtr_Type comm)
Constructor.
void solveSplitting()
Solve the system with operator splitting from M_initialTime to the M_endTime with time step M_timeSte...
std::shared_ptr< blockVector_Type > blockVectorPtr_Type
const blockMatrixPtr_Type massMatrixPtr() const
get the pointer to the mass matrix
const vectorPtr_Type appliedCurrentIntraPtr()
get the pointer to the applied intra cellular current vector
void setFullMeshPtr(const meshPtr_Type p)
set the pointer to the partitioned mesh
std::shared_ptr< feSpace_Type > feSpacePtr_Type
const ionicModelPtr_Type ionicModelPtr() const
get the pointer to the ionic model
void partitionMesh(std::string meshName, std::string meshPath)
partition the mesh
ElectroETABidomainSolver< Mesh, IonicModel > & operator=(const ElectroETABidomainSolver &solver)
Operator=()
VectorEpetra & operator*=(const data_type &scalar)
Multiplication operator.
ElectroETABidomainSolver(list_Type list, GetPot &dataFile, ionicModelPtr_Type model)
Constructor.
void setFeSpacePtr(const feSpacePtr_Type p)
set the pointer to the usual fe space
void solveICI(IOFile_Type &exporter, Real dt)
Solve the system using ICI from M_initialTime to the M_endTime with time step M_timeStep and export t...
const Real & surfaceVolumeRatio() const
get the surface to volume ratio
void setPotentialTrans(const vector_Type &p)
void setStiffnessMatrixPtr(const blockMatrixPtr_Type p)
set the pointer to the stiffness matrix
void init(ionicModelPtr_Type model)
void setGlobalRhs(const vectorOfPtr_Type &p)
set the vector of pointers containing the rhs for the transmembrane potential (at 0) and the gating v...
std::shared_ptr< LinearSolver > linearSolverPtr_Type
void setupMassMatrix()
create mass matrix
void solveOneStepGatingVariablesRL()
void setupGlobalRhs(short int ionicSize)
creates a vector of pointers to store the rhs
void exportSolution(IOFile_Type &exporter, Real t)
Save the solution in the exporter.
ionicModelPtr_Type M_ionicModelPtr
void computeRhsSVI()
Compute the rhs using state variable interpolation.
void initializeAppliedCurrentIntra()
Initialize the applied current to zero.
ExporterEnsight< mesh_Type > ensightIOFile_Type
void solveOneReactionStepFE(matrix_Type &mass, int subiterations=1)
void setGlobalSolution(const vectorOfPtr_Type &p)
set the vector of pointers containing the transmembrane potential (at 0) and the gating variables ...
void solveOneDiffusionStepBDF2(vectorPtr_Type previousPotentialGlobalPtr)
Solves one diffusion step using the BDF2 scheme.
void solveOneStepGatingVariablesFE()
Solves the gating variables with forward Euler.
void setRhsPtrUnique(const blockVectorPtr_Type p)
set the pointer to the unique version of the right hand side
class ETFESpace A light, templated version of the FESpace
ETFESpaceVectorialPtr_Type displacementETFESpacePtr() const
std::shared_ptr< ionicModel_Type > ionicModelPtr_Type
const blockVectorPtr_Type rhsPtr() const
get the pointer to the right hand side
void solveOneSplittingStep(IOFile_Type &exporter, Real t)
Solve one full step with operator splitting and export the solution.
void setEndTime(const Real &p)
set the time step
void setGlobalMatrix(const matrix_Type &p)
const std::string elementsOrder() const
get the order of the elements
void initializePotential()
Initialize the potentials to zero.
const vectorPtr_Type fiberPtr() const
get the pointer to the fiber vector
void setLocalMesh(const mesh_Type &p)
void setupGlobalSolution(short int ionicSize)
creates a vector of pointers to store the solution
void setLinearSolver(const linearSolver_Type &p)
ElectroETABidomainSolver()
Empty Constructor.
void solveSVI(IOFile_Type &exporter)
solve system using SVI from M_initialTime to the M_endTime with time step M_timeStep and export the s...
void setPotentialFromFunctionExtra(function_Type &f, Real time=0.0)
given a boost function initialize the extra cellular potential
ExporterData< mesh_Type > IOData_Type
std::shared_ptr< prec_Type > precPtr_Type
void setupLinearSolver(GetPot dataFile, list_Type list)
setup the linear solver
std::shared_ptr< ETFESpace< mesh_Type, MapEpetra, 3, 1 > > ETFESpacePtr_Type
VectorEpetraStructured blockVector_Type
void solveSVI(IOFile_Type &exporter, Real dt)
Solve the using SVI from M_initialTime to the M_endTime with time step M_timeStep and export the solu...
FESpace< mesh_Type, MapEpetra > feSpace_Type
void solveSVI()
solve system using SVI from M_initialTime to the M_endTime with time step M_timeStep ...
std::vector< vectorPtr_Type > vectorOfPtr_Type