39 #include <lifev/electrophysiology/solver/IonicModels/IonicTenTusscher06.hpp> 48 IonicTenTusscher06::IonicTenTusscher06() :
53 M_membraneCapacitance = 2.0;
96 M_cellularCapacitance = 0.185;
149 inverseVcF2 = 1. / (2.*Vc * F);
150 inverseVcF = 1. / (Vc * F);
151 inversevssF2 = 1. / (2.*Vss * F);
154 M_restingConditions.at (0) = -86.2;
156 M_restingConditions.at (1) = 0.0;
158 M_restingConditions.at (2) = 0.75;
160 M_restingConditions.at (3) = 0.75;
162 M_restingConditions.at (4) = 0.;
164 M_restingConditions.at (5) = 1.;
166 M_restingConditions.at (6) = 1;
168 M_restingConditions.at (7) = 1.0;
170 M_restingConditions.at (8) = 0.;
172 M_restingConditions.at (9) = 1.0;
174 M_restingConditions.at (10) = 0.0;
176 M_restingConditions.at (11) = 1.0;
178 M_restingConditions.at (12) = 0.0;
180 M_restingConditions.at (13) = 7.67;
182 M_restingConditions.at (14) = 138.3;
184 M_restingConditions.at (15) = 0.00007;
186 M_restingConditions.at (16) = 0.00007;
188 M_restingConditions.at (17) = 1.3;
190 M_restingConditions.at (18) = 1.0;
233 IonicTenTusscher06::IonicTenTusscher06 ( Teuchos::ParameterList& parameterList ) :
236 knak = parameterList.get (
"knak", 0.0 );
237 KmNa = parameterList.get (
"KmNa", 0.0 );
238 KmK = parameterList.get (
"KmK", 0.0 );
239 knaca = parameterList.get (
"knaca", 0.0 );
240 KmNai = parameterList.get (
"KmNai", 0.0 );
241 KmCa = parameterList.get (
"KmCa", 0.0 );
242 ksat = parameterList.get (
"ksat", 0.0 );
243 n = parameterList.get (
"n", 0.0 );
246 Ko = parameterList.get (
"Ko", 0.0 );
247 Cao = parameterList.get (
"Cao", 0.0 );
248 Nao = parameterList.get (
"Nao", 0.0 );
251 Bufc = parameterList.get (
"Bufc", 0.0 );
252 Kbufc = parameterList.get (
"Kbufc", 0.0 );
253 Bufsr = parameterList.get (
"Bufsr", 0.0 );
254 Kbufsr = parameterList.get (
"Kbufsr", 0.0 );
255 Bufss = parameterList.get (
"Bufss", 0.0 );
256 Kbufss = parameterList.get (
"Kbufss", 0.0 );
258 Vmaxup = parameterList.get (
"Vmaxup", 0.0 );
259 Kup = parameterList.get (
"Kup", 0.0 );
260 Vrel = parameterList.get (
"Vrel", 0.0 );
261 k1_ = parameterList.get (
"k1", 0.0 );
262 k2_ = parameterList.get (
"k2", 0.0 );
263 k3 = parameterList.get (
"k3", 0.0 );
264 k4 = parameterList.get (
"k4", 0.0 );
265 EC = parameterList.get (
"EC", 0.0 );
266 maxsr = parameterList.get (
"maxsr", 0.0 );
267 minsr = parameterList.get (
"minsr", 0.0 );
268 Vleak = parameterList.get (
"Vleak", 0.0 );
269 Vxfer = parameterList.get (
"Vxfer", 0.0 );
272 pKNa = parameterList.get (
"pKNa", 0.0 );
275 M_cellularCapacitance = parameterList.get (
"Cm", 0.0 );
276 F = parameterList.get (
"F", 0.0 );
277 R = parameterList.get (
"R", 0.0 );
278 T = parameterList.get (
"T", 0.0 );
281 Gkr = parameterList.get (
"Gkr", 0.0 );
282 Gks = parameterList.get (
"Gks", 0.0 );
283 GK1 = parameterList.get (
"GK1", 0.0 );
284 Gto = parameterList.get (
"Gto", 0.0 );
285 GNa = parameterList.get (
"GNa", 0.0 );
286 GbNa = parameterList.get (
"GbNa", 0.0 );
287 GCaL = parameterList.get (
"GCal", 0.0 );
288 GbCa = parameterList.get (
"GbCa", 0.0 );
289 GpCa = parameterList.get (
"GpCa", 0.0 );
290 KpCa = parameterList.get (
"KpCa", 0.0 );
291 GpK = parameterList.get (
"GpK", 0.0 );
294 Vc = parameterList.get (
"Vc", 0.0 );
295 Vsr = parameterList.get (
"Vsr", 0.0 );
296 Vss = parameterList.get (
"Vss", 0.0 );
299 computeinverseVcF2();
301 computeinversevssF2();
303 std::map< std::string, WallFlag > WallFlagMap;
304 WallFlagMap[
"Endo"] = Endo;
305 WallFlagMap[
"Epi"] = Epi;
306 WallFlagMap[
"MCell"] = MCell;
308 flag = WallFlagMap[ parameterList.get (
"WallFlag",
"MCell" ) ];
310 M_restingConditions.at (0) = parameterList.get (
"V", -85.423);
312 M_restingConditions.at (1) = parameterList.get (
"m", 0.00165);
314 M_restingConditions.at (2) = parameterList.get (
"h", 0.749);
316 M_restingConditions.at (3) = parameterList.get (
"j", 0.6788);
318 M_restingConditions.at (4) = parameterList.get (
"d", 3.288e-5);
320 M_restingConditions.at (5) = parameterList.get (
"f", 0.7026);
322 M_restingConditions.at (6) = parameterList.get (
"f2", 0.9526);
324 M_restingConditions.at (7) = parameterList.get (
"fCass", 0.9942);
326 M_restingConditions.at (8) = parameterList.get (
"r", 2.347e-8);
328 M_restingConditions.at (9) = parameterList.get (
"s", 0.999998);
330 M_restingConditions.at (10) = parameterList.get (
"Xr1", 0.0165);
332 M_restingConditions.at (11) = parameterList.get (
"Xr2", 0.473);
334 M_restingConditions.at (12) = parameterList.get (
"Xs", 0.0174);
336 M_restingConditions.at (13) = parameterList.get (
"Nai", 10.132);
338 M_restingConditions.at (14) = parameterList.get (
"Ki", 138.52);
340 M_restingConditions.at (15) = parameterList.get (
"Cai", 0.000153);
342 M_restingConditions.at (16) = parameterList.get (
"Cass", -85.423);
344 M_restingConditions.at (17) = parameterList.get (
"Casr", 4.272);
346 M_restingConditions.at (18) = parameterList.get (
"Rprime", 0.8978);
349 IonicTenTusscher06::IonicTenTusscher06 (
const IonicTenTusscher06& model )
369 Kbufsr = model.Kbufsr;
371 Kbufss = model.Kbufss;
373 Vmaxup = model.Vmaxup;
412 computeinverseVcF2();
414 computeinversevssF2();
418 M_numberOfEquations = model.M_numberOfEquations;
419 M_numberOfGatingVariables = model.M_numberOfGatingVariables;
420 M_restingConditions = model.M_restingConditions;
427 IonicTenTusscher06& IonicTenTusscher06::operator= (
const IonicTenTusscher06& model )
447 Kbufsr = model.Kbufsr;
449 Kbufss = model.Kbufss;
451 Vmaxup = model.Vmaxup;
490 computeinverseVcF2();
492 computeinversevssF2();
496 M_numberOfEquations = model.M_numberOfEquations;
497 M_numberOfGatingVariables = model.M_numberOfGatingVariables;
498 M_restingConditions = model.M_restingConditions;
507 void IonicTenTusscher06::computeGatingRhs (
const std::vector<Real>& v,
508 std::vector<Real>& rhs )
541 rhs[5] = dF2 (V, f2);
543 rhs[6] = dFCaSS (V, fcass);
549 rhs[9] = dXr1 (V, xr1);
551 rhs[10] = dXr2 (V, xr2);
553 rhs[11] = dXs (V, xs);
555 rhs[12] = dNai (V, m, h, j, Nai, Cai);
557 rhs[13] = dKi (V, r, s, xr1, xr2, xs, Ki, Nai);
559 rhs[14] = dCai (V, Nai, Cai, CaSR, CaSS);
561 rhs[15] = dCaSS (Cai, CaSR, CaSS, RR, V, d, f, f2, fcass);
563 rhs[16] = dCaSR (Cai, CaSR, CaSS, RR);
565 rhs[17] = dRR (CaSR, CaSS, RR);
568 void IonicTenTusscher06::computeNonGatingRhs (
const std::vector<Real>& ,
573 void IonicTenTusscher06::computeRhs (
const std::vector<Real>& v,
574 std::vector<Real>& rhs )
597 rhs[0] = - Itot (V, m, h, j, d, f, f2, fcass, r, s, xr1, xr2, xs, Nai, Ki, Cai, CaSS );
609 rhs[6] = dF2 (V, f2);
611 rhs[7] = dFCaSS (V, fcass);
617 rhs[10] = dXr1 (V, xr1);
619 rhs[11] = dXr2 (V, xr2);
621 rhs[12] = dXs (V, xs);
623 rhs[13] = dNai (V, m, h, j, Nai, Cai);
625 rhs[14] = dKi (V, r, s, xr1, xr2, xs, Ki, Nai);
627 rhs[15] = dCai (V, Nai, Cai, CaSR, CaSS);
629 rhs[16] = dCaSS (Cai, CaSR, CaSS, RR, V, d, f, f2, fcass);
631 rhs[17] = dCaSR (Cai, CaSR, CaSS, RR);
633 rhs[18] = dRR (CaSR, CaSS, RR);
638 Real IonicTenTusscher06::computeLocalPotentialRhs (
const std::vector<Real>& v)
640 Real dPotential (0.0);
660 dPotential = -Itot (V, m, h, j, d, f, f2, fCass, r, s, Xr1, Xr2, Xs, Nai, Ki, Cai, Cass );
666 void IonicTenTusscher06::computeGatingVariablesWithRushLarsen ( std::vector<Real>& v,
const Real dt )
688 v[1] = M_INF (V) - ( M_INF (V) - m ) * std::exp (- dt / TAU_M (V) );
689 v[2] = H_INF (V) - ( H_INF (V) - h ) * std::exp (- dt / TAU_H (V) );
690 v[3] = J_INF (V) - ( J_INF (V) - j ) * std::exp (- dt / TAU_J (V) );
691 v[4] = D_INF (V) - ( D_INF (V) - d ) * std::exp (- dt / TAU_D (V) );
692 v[5] = F_INF (V) - ( F_INF (V) - f ) * std::exp (- dt / TAU_F (V) );
693 v[6] = F2_INF (V) - ( F2_INF (V) - f2 ) * std::exp (- dt / TAU_F2 (V) );
694 v[7] = FCaSS_INF (CaSS) - ( FCaSS_INF (CaSS) - fcass ) * std::exp ( -dt / TAU_FCaSS (CaSS) );
695 v[8] = R_INF (V) - ( R_INF (V) - r ) * std::exp (- dt / TAU_R (V) );
696 v[9] = S_INF (V) - ( S_INF (V) - s ) * std::exp (- dt / TAU_S (V) );
697 v[10] = Xr1_INF (V) - ( Xr1_INF (V) - xr1 ) * std::exp (- dt / TAU_Xr1 (V) );
698 v[11] = Xr2_INF (V) - ( Xr2_INF (V) - xr2 ) * std::exp (- dt / TAU_Xr2 (V) );
699 v[12] = Xs_INF (V) - ( Xs_INF (V) - xs ) * std::exp (- dt / TAU_Xs (V) );
700 v[13] = solveNai (V, m, h, j, Nai, Cai, dt);
701 v[14] = solveKi (V, r, s, xr1, xr2, xs, Nai, Ki, dt);
702 v[15] = solveCai (V, Nai, Cai, CaSR, CaSS, dt);
703 v[16] = solveCaSS (Cai, CaSR, CaSS, RR, V, d, f, f2, fcass, dt);
704 v[17] = solveCaSR (Cai, CaSR, CaSS, RR, dt);
705 v[18] = solveRR (CaSR, CaSS, RR, dt);
710 void IonicTenTusscher06::showMe()
712 std::cout <<
"\n\n************************************";
713 std::cout <<
"\n\tHi, I'm the Ten Tusscher model";
714 std::cout <<
"\n\t I've so many parameters that I don't think it's a good idea to display them all\n\n";
715 std::cout <<
"\n\tPlease use a getter, or implement this method otherwise.";
716 std::cout <<
"\n************************************\n\n";
719 void IonicTenTusscher06::solveOneStep (std::vector<Real>& v,
Real dt)
741 computeGatingVariablesWithRushLarsen (v, dt);
743 v[0] = solveV (V, m, h, j, d, f, f2, fcass, r, s, xr1, xr2, xs, Nai, Ki, Cai, CaSS, dt);
744 v[13] = solveNai (V, m, h, j, Nai, Cai, dt);
745 v[14] = solveKi (V, r, s, xr1, xr2, xs, Nai, Ki, dt);
746 v[15] = solveCai (V, Nai, Cai, CaSR, CaSS, dt);
747 v[16] = solveCaSS (Cai, CaSR, CaSS, RR, V, d, f, f2, fcass, dt);
748 v[17] = solveCaSR (Cai, CaSR, CaSS, RR, dt);
749 v[18] = solveRR (CaSR, CaSS, RR, dt);
757 void IonicTenTusscher06::showCurrents (std::vector<Real>& v)
777 showCurrents ( V, m, h, j, d, f, f2, fcass, r, s, xr1, xr2, xs, Nai, Ki, Cai, CaSS);
784 std::cout <<
"\nIKr = " << IKr (V, xr1, xr2, Ki);
785 std::cout <<
"\nIKs = " << IKs (V, xs, Ki, Nai);
786 std::cout <<
"\nIK1 = " << IK1 (V, Ki);
787 std::cout <<
"\nIto = " << Ito (V, r, s, Ki);
788 std::cout <<
"\nINa = " << INa (V, m, h, j, Nai);
789 std::cout <<
"\nIbNa = " << IbNa (V, Nai);
790 std::cout <<
"\nICaL = " << ICaL (V, d, f, f2, fcass, CaSS);
791 std::cout <<
"\nIbCa = " << IbCa (V, Cai);
792 std::cout <<
"\nINaK = " << INaK (V, Nai);
793 std::cout <<
"\nINaCa = " << INaCa (V, Nai, Cai);
794 std::cout <<
"\nIpCa = " << IpCa (Cai);
795 std::cout <<
"\nIKpK = " << IpK (V, Ki);
void updateInverseJacobian(const UInt &iQuadPt)
double Real
Generic real data.