writeline(default, "Maple Housekeeping"): restart; digits := 5; interface(displayprecision=3); # -------------------------------------------------------------- writeline(default,"Constants"): writeline(default,"Equilibrium voltages, mV"): writeline(default," Sodium, Potassium, Leak"); vNa:=35; vK:=-67; # own data Fig 3. # Max Leak conductance and reversal potential measured # from trace of 18 mV and 1 nA # leak conductance smaller than IK - see infinity worksheet vLeak:=-20; writeline(default,"Fixed leak conductance"): gLeak :=0.02; # muS # -------------------------------------------------------------- # time independent functions ................ # Sodium current m and h ... Connor calls them a and b # they were in ms so divide by 1000 writeline(default,"Sodium current"): writeline(default," maximum conductance, m and h components "): writeline(default," with max value and time constant as functions of voltage"): gbarNa:=7.0; #default value is 7 - also use 9.3 and 4.9 minf := v -> 1/(1 + exp((24+v)/(-8))) ; taum := v -> (0.3+ 8/(1 + exp((v+40)/2.0)))/1000 ; hinf := v -> 1/(1 + exp((29.0+v)/3.8)) ; tauh := v -> (2.3 + 15/(1 + exp((v+24.3)/3.8)))/1000 ; writeline(default,"Sustained Potassium current"): writeline(default," maximum conductance, NA and NB components "): writeline(default," with max value and time constant as functions of voltage"): # maintained Potassium Current IK NA, NB # all own data # slow and fast components gbarKA := 1.44 ; NAinf := v -> 1/(1 + exp((14.9-v)/16.6)) ; tauNA := v -> 0.0383 - 0.00041 * v ; gbarKB := 2.88 ; NBinf := v -> 1/(1 + exp((8.6-v)/14.6)) ; tauNB := v -> 0.0057 - 0.00007 * v ; writeline(default,"Transient Potassium current"): writeline(default," maximum conductance, a and b components "): writeline(default," with max value and time constant as functions of voltage"): #Transient K current IA a b gbarA := 12; # activation (measured values) ainf := v -> 1/(1 + exp((12.4+v)/(-14.1))) ; taua := v -> 0.0018 - 0.00003 * v ; # inactivation - some uncertainty in literature so use own ## v = -71, h = 6.6 (measured) ## v = -97, h = 6.2 in Alekseev & Zayzin BBA 1148:100 Fig 2B ## v = -74, h = 6.4 in Connor & Stevens J Physiol 317:27 fig 5 ## binf := v -> 1/(1 + exp((v+71)/6.6)) ; taub := v -> 0.026 + 0.00022 * v ; # -------------------------------------------------------------- writeline(default,"Initial conditions, start from holding voltage (-50 mV)"): v0:=-50; writeline(default," Sodium current"): m0:=minf(v0); h0:=hinf(v0); writeline(default," Sustained Potassium current"): NA0:=NAinf(v0); NB0:=NBinf(v0); writeline(default," Transient Potassium current"): a0:=ainf(v0); b0:=binf(v0); v:= -10 ; writeline(default,"Current equations"): writeline(default," Sodium current"): writeline(default," Sustained Potassium current"): writeline(default," Transient Potassium current"): writeline(default," Leak current"): writeline(default," Total ionic current"): INa := (v(t)-vNa) * gbarNa*m(t)^3*h(t); IK := (v(t)-vK) * ( (gbarKA * NA(t)^2) + (gbarKB * NB(t)) ); IA := (v(t)-vK) * gbarA *a(t)^4*b(t); ILeak:=(v(t)-vLeak)*gLeak; ITotal := INa+IK+IA+ILeak ; # # odes for opening and closing channels............... writeline(default,"Differential equations"): writeline(default," ODEs for Sodium current"): odem:=diff(m(t),t)=(minf(v(t))-m(t))/taum(v(t)); odeh:=diff(h(t),t)=(hinf(v(t))-h(t))/tauh(v(t)); writeline(default," ODEs for Sustained Potassium current"): odeNA:=diff(NA(t),t)=(NAinf(v(t))-NA(t))/tauNA(v(t)); odeNB:=diff(NB(t),t)=(NBinf(v(t))-NB(t))/tauNB(v(t)); writeline(default," ODEs for Transient Potassium current"): odea:=diff(a(t),t)=(ainf(v(t))-a(t))/taua(v(t)); odeb:=diff(b(t),t)=(binf(v(t))-b(t))/taub(v(t)); # end of calculations of ODEs # -------------------------------------------------------------- writeline(default,"Solve system of ODEs"): sol100:=dsolve( { odem, odeh, odeNA, odeNB, odea, odeb, m(0)=m0, h(0)=h0, NA(0)=NA0, NB(0)=NB0, a(0)=a0, b(0)=b0}, {m(t), h(t), NA(t), NB(t), a(t), b(t)}, type=numeric, method=lsode ) ; writeline(default,"Plotting..."): writeline(default," Setup plot"): maxT := 0.03; # max s for plot maxPT := 200 ; # points to plot convert(v0,string); convert (v,string); sHead := cat ("Holding: ", %%, " pulse: ", % ); writeline(default," Plotting current vs time"): with (plots, odeplot); odeplot(sol100,[t,ITotal, color=black], 0..maxT, view = [0..maxT, -120..120], numpoints=maxPT , title = sHead, labels=["time, s","current nA"]) ;