Advertisement
Guest User

Untitled

a guest
Dec 21st, 2014
151
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.31 KB | None | 0 0
  1. import scipy as sp
  2. import pylab as plt
  3. from scipy.integrate import odeint
  4. from scipy import stats
  5. import scipy.linalg as lin
  6.  
  7. ## Hodgkin-Huxley Model For L-Type Voltage-dependent Ca2+ Channel EGL-19
  8. ## Jospin M. et.al V.S. Boyle and Cohen
  9.  
  10. # Constants
  11. g_Ca1 = 220.0 # maximum conducances, in mS/cm^2
  12. g_Ca = 199
  13. #g_Ca = 127
  14. a_Ca = 0.283
  15. E_Ca1 = 49.1 # Nernst reversal potentials, in mV
  16. E_Ca = 50.0
  17. #E_Ca = 59.0
  18. E_half_Ca = 0.9
  19. #E_half_Ca = 6.4
  20. E_half_e = -3.4
  21. E_half_f = 25.2 #5.2 is much better
  22. Ca_half_h = 64.1 * sp.power(10,-9)
  23. k_Ca = 4.9 #mV
  24. #k_Ca = 7.9 #mV
  25. k_e = 6.7
  26. k_f = 5.0 #
  27. k_h = -0.01 #mM
  28. Ca_Con = 2.39 * sp.power(10,-6)
  29.  
  30.  
  31. # Channel currents (in mA/cm^2)
  32. def I_Ca_boyle(V): return g_Ca1 * e(V)**2 * f(V) * (1 + (h - 1) * a_Ca) * (V - E_Ca1) / 1000
  33. def I_Ca(V): return g_Ca * (V - E_Ca) / ((1 + sp.exp((E_half_Ca - V) / k_Ca)) * 1000)
  34.  
  35. # The voltage to integrate over
  36. V = sp.arange(-70, 80, 1)
  37.  
  38. # Gating Kinetics
  39. def X_inf(V, V_half_x, k_x): return 1 / (1 + sp.exp((V_half_x - V) / k_x))
  40.  
  41. def e(V): return X_inf(V, E_half_e, k_e)
  42. def f(V): return X_inf(V, E_half_f, k_f)
  43.  
  44. h = X_inf(Ca_Con, Ca_half_h, k_h)
  45.  
  46. icab = I_Ca_boyle(V)
  47. ica = I_Ca(V)
  48.  
  49. plt.figure()
  50.  
  51. plt.subplot(1,1,1)
  52. plt.plot(V, ica, 'r', label='$I_{Ca}$')
  53. plt.plot(V, icab, 'y', label='$I_{Ca}-Boyle$')
  54. plt.ylabel('I (A/F)')
  55. plt.xlabel('Em (mV)')
  56. plt.legend()
  57.  
  58. plt.show()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement