#these are the initial values for the variables c1(0)=1 o1(0)=0 o1p(0)=0.8 #note: o1p(0)=1/(1+(k1m/k1p)) #these are the values of the parameters param kap=0.5, kam=0.1, kbp=0.10, kbm=0.05, cad=0.2 param V=20, Vca=60,g=10 #these are the rate functions c2=1-o1-c1 va(c1,o1)=kap*c1-kam*o1 vb(o1,c2)=kbp*cad*o1-kbm*c2 #these are the complete equations dc1/dt=-va(c1,o1) do1/dt=va(c1,o1)-vb(o1,c2) #rapid equilibrium approximation (va(c1,o1) = 0) gives do1p/dt=-kbp*cad*o1p+kbm*(1-(1+(kam/kap))*o1p) #the currents aux i=g*o1*(V-Vca) aux ip=g*o1p*(V-Vca) done