{VERSION 5 0 "IBM INTEL NT" "5.0" } {USTYLETAB {CSTYLE "Maple Input" -1 0 "Courier" 0 1 255 0 0 1 0 1 0 0 1 0 0 0 0 1 }{PSTYLE "Normal" -1 0 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 }0 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }} {SECT 0 {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 105 "writeline(default, \+ \"Maple Housekeeping\"):\n restart;\n digits := 5;\n interface(d isplayprecision=3);\n\n" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 5510 " # ------------------------------------------------------------ --\nwriteline(default,\"Constants\"):\n # Stimulus current - threshol d is 1.55 nA; reduced to 1.25 when gBarNa is \n # increased from 7 to 9.3\nwriteline(default,\"Stimulus current, in nA, at 0.1 ms goes from zero to 1.6 nA\");\n Istim:= `if`(t<0.1,0,1.6) ; ## nA \n \n # a n octopamine current (OA > 100 muM) 0.5 nA ; \nwriteline(default,\"Oc topamine ligand gated current\"):\n I_OA := 0.0 ; \n \n # capacitan ce microF (1nF)\nwriteline(default,\"Capacitance in microF\"):\n Cm: =0.0035 ;\n \nwriteline(default,\"Equilibrium voltages, mV\"):\nwrite line(default,\" Sodium, Potassium, Leak\");\n vNa:=35;\n vK:=-6 7; # own data Fig 3.\n \n # Max Leak conductance and reversal po tential measured\n # from trace of 18 mV and 1 nA\n # leak conductan ce smaller than IK - see infinity worksheet \n vLeak:=-20;\nwrite line(default,\"Fixed leak conductance\"):\n gLeak :=0.02; # muS\n\n # --------------------------------------------------------------\n \+ # time independent functions ................\n \n # Sodium current m and h ... Connor calls them a and b\n # they were in ms so divide by 1000\nwriteline(default,\"Sodium current\"):\nwriteline(default,\" \+ maximum conductance, m and h components \"):\nwriteline(default,\" \+ with max value and time constant as functions of voltage\"):\n gbar Na:=7.0; #default value is 7 - also use 9.3 and 4.9\n minf := v -> \+ 1/(1 + exp((24+v)/(-8))) ;\n taum := v -> (0.3+ 8/(1 + exp((v+40)/2. 0)))/1000 ; \n hinf := v -> 1/(1 + exp((29.0+v)/3.8)) ;\n tauh := v -> (2.3 + 15/(1 + exp((v+24.3)/3.8)))/1000 ;\n \nwriteline(default, \"Sustained Potassium current\"):\nwriteline(default,\" maximum con ductance, NA and NB components \"):\nwriteline(default,\" with max \+ value and time constant as functions of voltage\"):\n # maintained Po tassium Current IK NA, NB\n # all own data\n # slow and fast compone nts\n gbarKA := 1.44 ;\n NAinf := v -> 1/(1 + exp((14.9-v)/16.6)) \+ ; \n tauNA := v -> 0.0383 - 0.00041 * v ; \n \n gbarKB := 2.88 ; \n NBinf := v -> 1/(1 + exp((8.6-v)/14.6)) ; \n tauNB := v -> 0.00 57 - 0.00007 * v ; \n \nwriteline(default,\"Transient Potassium curre nt\"):\nwriteline(default,\" maximum conductance, a and b component s \"):\nwriteline(default,\" with max value and time constant as fu nctions of voltage\"): \n #Transient K current IA a b\n gbarA := 1 2; \n \n # activation (measured values)\n ainf := v -> 1/(1 + \+ exp((12.4+v)/(-14.1))) ; \n taua := v -> 0.0018 - 0.00003 * v ;\n # inactivation - some uncertainty in literature so use own\n ## v = -7 1, h = 6.6 (measured)\n ## v = -97, h = 6.2 in Alekseev & Zayzin BBA \+ 1148:100 Fig 2B \n ## v = -74, h = 6.4 in Connor & Stevens J Physiol \+ 317:27 fig 5\n ## \n binf := v -> 1/(1 + exp((v+71)/6.6)) ; \n ta ub := v -> 0.026 + 0.00022 * v ;\n \n # --------------------------- -----------------------------------\nwriteline(default,\"Initial condi tions, start from equilibrium voltage (-52.5 mV)\"):\n v0:=-52.5; # \+ approx eqm level -52.5 mV, \nwriteline(default,\" Sodium current\") :\n m0:=minf(v0);\n h0:=hinf(v0);\nwriteline(default,\" Sustain ed Potassium current\"):\n NA0:=NAinf(v0);\n NB0:=NBinf(v0);\nwrit eline(default,\" Transient Potassium current\"):\n a0:=ainf(v0); \n b0:=binf(v0);\n \n \nwriteline(default,\"Current equations\"): \nwriteline(default,\" Sodium current\"):\nwriteline(default,\" \+ Sustained Potassium current\"):\nwriteline(default,\" Transient Pot assium current\"):\nwriteline(default,\" Leak current\"):\nwritelin e(default,\" Total ionic current\"):\n INa := (v(t)-vNa) * gbarNa *m(t)^3*h(t);\n IK := (v(t)-vK) * ( (gbarKA * NA(t)^2) + (gbarKB * NB(t)) ); \n IA := (v(t)-vK) * gbarA *a(t)^4*b(t);\n ILeak:=(v( t)-vLeak)*gLeak; \n \n ITotal := INa+IK+IA+ILeak ;\n \n #\n # odes for opening and closing channels...............\nwriteline(defau lt,\"Differential equations\"):\nwriteline(default,\" ODEs for Sod ium current\"):\n odem:=diff(m(t),t)=(minf(v(t))-m(t))/taum(v(t));\n odeh:=diff(h(t),t)=(hinf(v(t))-h(t))/tauh(v(t));\nwriteline(default ,\" ODEs for Sustained Potassium current\"):\n odeNA:=diff(NA(t), t)=(NAinf(v(t))-NA(t))/tauNA(v(t));\n odeNB:=diff(NB(t),t)=(NBinf(v( t))-NB(t))/tauNB(v(t));\nwriteline(default,\" ODEs for Transient Po tassium current\"):\n odea:=diff(a(t),t)=(ainf(v(t))-a(t))/taua(v(t) );\n odeb:=diff(b(t),t)=(binf(v(t))-b(t))/taub(v(t));\n \n \n # M ain ODE deriving voltage from current \nwriteline(default,\" ODE fo r Voltage as function of current \"):\nwriteline(default,\" Sti mulus and octopamine ligand gated currents included here\"):\n odev: =diff(v(t),t)=(Istim+I_OA-ITotal)/Cm; \n \n # end of calculations o f ODEs\n \n# -------------------------------------------------------- ------ \nwriteline(default,\"Solve system of ODEs\"): \n sol100 :=dsolve( \{ odem, odeh, odeNA, odeNB, odea, odeb, odev,\n m (0)=m0, h(0)=h0, \n NA(0)=NA0, NB(0)=NB0, \n a(0)= a0, b(0)=b0, v(0) = v0\}, \n \{m(t), h(t), NA(t), NB(t), a(t), \+ b(t), v(t)\}, \n type=numeric, method=lsode ) ;\nwriteline(defa ult,\"Plotting...\"): \nwriteline(default,\" Setup plot\"): \n \+ maxT := 1.100; # max ms for plot \n maxPT := 2000 ; # points to plot \n convert(Istim,string); \n convert (gbarNa,string);\n sHead := \+ cat (\"Stimulus: \", %%, \" gNaMax: \", % );\n \nwriteline(default,\" \+ Plotting voltage vs time\"): \n with (plots, odeplot);\n \n odepl ot(sol100,[t,v(t), color=black], 0..maxT, view = [0..maxT,\n -70 ..20], numpoints=maxPT , title = sHead, labels=[\"time, s\",\"\"]) ; \+ \n \n" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}{MARK "1 0 0 " 4361 }{VIEWOPTS 1 1 0 1 1 1803 1 1 1 1 }{PAGENUMBERS 0 1 2 33 1 1 }