- Author:
- Shelley Fong <s.fong@auckland.ac.nz>
- Date:
- 2022-03-03 09:58:16+13:00
- Desc:
- Changing Xi to X_i, and adding python param finder code
- Permanent Source URI:
- https://models.physiomeproject.org/workspace/82c/rawfile/73d6bc1016edb1be3ceadf6cccc4aa05ef251e58/parameter_finder/output/TEMP.cellml.txt
def model individual_Kr_channel as
def import using "units_and_constants/units_BG.cellml" for
unit mM using unit mM;
unit fmol using unit fmol;
unit per_fmol using unit per_fmol;
unit J_per_mol using unit J_per_mol;
unit fmol_per_sec using unit fmol_per_sec;
unit C_per_mol using unit C_per_mol;
unit J_per_C using unit J_per_C;
unit microm3 using unit microm3;
unit fF using unit fF;
unit fC using unit fC;
unit fA using unit fA;
unit per_second using unit per_second;
unit millivolt using unit millivolt;
unit per_sec using unit per_sec;
unit J_per_K_per_mol using unit J_per_K_per_mol;
unit fmol_per_L using unit fmol_per_L;
unit fmol_per_L_per_sec using unit fmol_per_L_per_sec;
unit per_sec_per_fmol_per_L using unit per_sec_per_fmol_per_L;
unit uM using unit uM;
unit mM_per_sec using unit mM_per_sec;
unit uM_per_sec using unit uM_per_sec;
unit pL using unit pL;
unit m_to_u using unit m_to_u;
enddef;
def import using "units_and_constants/constants_BG.cellml" for
comp constants using comp constants;
enddef;
def comp environment as
var time: second {pub: out};
// initial values
var q_K_i: fmol {init: 1e-888, pub: out};
var q_K_o: fmol {init: 1e-888, pub: out};
var q_C3: fmol {init: 1e-888, pub: out};
var q_C2: fmol {init: 1e-888, pub: out};
var q_C1: fmol {init: 1e-888, pub: out};
var q_O: fmol {init: 1e-888, pub: out};
var q_I: fmol {init: 1e-888, pub: out};
// From submodule
var v_Kr: fmol_per_sec {pub: in};
var v_rC3: fmol_per_sec {pub: in};
var v_rC2: fmol_per_sec {pub: in};
var v_rC1: fmol_per_sec {pub: in};
var v_rC1IF: fmol_per_sec {pub: in};
var v_rOIF: fmol_per_sec {pub: in};
ode(q_K_i, time) = vvv;
ode(q_K_o, time) = vvv;
ode(q_C3, time) = vvv;
ode(q_C2, time) = vvv;
ode(q_C1, time) = vvv;
ode(q_O, time) = vvv;
ode(q_I, time) = vvv;
enddef;
def comp Kr_channel_parameters as
var kappa_Kr: fmol_per_sec {init: 740.548, pub: out};
var kappa_rC3: fmol_per_sec {init: 0.374318, pub: out};
var kappa_rC2: fmol_per_sec {init: 0.344937, pub: out};
var kappa_rC1: fmol_per_sec {init: 3.96058, pub: out};
var kappa_rC1IF: fmol_per_sec {init: 151.064, pub: out};
var kappa_rOIF: fmol_per_sec {init: 23.2033, pub: out};
var K_K_i: per_fmol {init: 0.791076, pub: out};
var K_K_o: per_fmol {init: 5.25145, pub: out};
var K_C3: per_fmol {init: 76.2011, pub: out};
var K_C2: per_fmol {init: 6.2968, pub: out};
var K_C1: per_fmol {init: 3.12231, pub: out};
var K_O: per_fmol {init: 0.532948, pub: out};
var K_I: per_fmol {init: 2.24495, pub: out};
enddef;
def comp Kr_channel as
var time: second {pub: in};
var R: J_per_K_per_mol {pub: in};
var T: kelvin {pub: in};
// parameters
var kappa_Kr: fmol_per_sec {pub: in};
var kappa_rC3: fmol_per_sec {pub: in};
var kappa_rC2: fmol_per_sec {pub: in};
var kappa_rC1: fmol_per_sec {pub: in};
var kappa_rC1IF: fmol_per_sec {pub: in};
var kappa_rOIF: fmol_per_sec {pub: in};
var K_K_i: per_fmol {pub: in};
var K_K_o: per_fmol {pub: in};
var K_C3: per_fmol {pub: in};
var K_C2: per_fmol {pub: in};
var K_C1: per_fmol {pub: in};
var K_O: per_fmol {pub: in};
var K_I: per_fmol {pub: in};
// Input from global environment
var q_K_i: fmol {pub: in};
var q_K_o: fmol {pub: in};
var q_C3: fmol {pub: in};
var q_C2: fmol {pub: in};
var q_C1: fmol {pub: in};
var q_O: fmol {pub: in};
var q_I: fmol {pub: in};
// Constitutive parameters
var mu_K_i: J_per_mol;
var mu_K_o: J_per_mol;
var mu_C3: J_per_mol;
var mu_C2: J_per_mol;
var mu_C1: J_per_mol;
var mu_O: J_per_mol;
var mu_I: J_per_mol;
var v_Kr: fmol_per_sec {pub: out};
var v_rC3: fmol_per_sec {pub: out};
var v_rC2: fmol_per_sec {pub: out};
var v_rC1: fmol_per_sec {pub: out};
var v_rC1IF: fmol_per_sec {pub: out};
var v_rOIF: fmol_per_sec {pub: out};
mu_K_i = R*T*ln(K_K_i*q_K_i);
mu_K_o = R*T*ln(K_K_o*q_K_o);
mu_C3 = R*T*ln(K_C3*q_C3);
mu_C2 = R*T*ln(K_C2*q_C2);
mu_C1 = R*T*ln(K_C1*q_C1);
mu_O = R*T*ln(K_O*q_O);
mu_I = R*T*ln(K_I*q_I);
v_Kr = ppp;
v_rC3 = ppp;
v_rC2 = ppp;
v_rC1 = ppp;
v_rC1IF = ppp;
v_rOIF = ppp;
enddef;
def map between environment and Kr_channel for
vars time and time;
vars q_K_i and q_K_i;
vars q_K_o and q_K_o;
vars q_C3 and q_C3;
vars q_C2 and q_C2;
vars q_C1 and q_C1;
vars q_O and q_O;
vars q_I and q_I;
vars v_Kr and v_Kr;
vars v_rC3 and v_rC3;
vars v_rC2 and v_rC2;
vars v_rC1 and v_rC1;
vars v_rC1IF and v_rC1IF;
vars v_rOIF and v_rOIF;
enddef;
def map between Kr_channel and Kr_channel_parameters for
vars kappa_Kr and kappa_Kr;
vars kappa_rC3 and kappa_rC3;
vars kappa_rC2 and kappa_rC2;
vars kappa_rC1 and kappa_rC1;
vars kappa_rC1IF and kappa_rC1IF;
vars kappa_rOIF and kappa_rOIF;
vars K_K_i and K_K_i;
vars K_K_o and K_K_o;
vars K_C3 and K_C3;
vars K_C2 and K_C2;
vars K_C1 and K_C1;
vars K_O and K_O;
vars K_I and K_I;
enddef;
def map between constants and Kr_channel for
vars R and R;
vars T and T;
enddef;
enddef;