Advertisement
Guest User

calciumregMatlab3

a guest
Apr 21st, 2013
197
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function [xp] = f(t,x)
  2.  
  3. ca = x(1);
  4. pth = x(2);
  5. dthh = x(3);
  6. ctn = x(4);
  7.  
  8. IC50 = 46.8;
  9. EC50 = 53.2;
  10.  
  11. PTHmax = 1.27e-4;
  12. dpth = log(2)/(4/(60*24));
  13. dctn = log(2)/(10/(24*60));
  14. CTNmax = 1e-5;
  15. DHCCmean = 2.1632e-2;
  16. ddhcc = log(2)/(5/24);
  17. pth_mean = 3.58e-5;
  18.  
  19. K_PTH = PTHmax*dpth;
  20. K_CTN = CTNmax*dctn;
  21. K_DHCC = (DHCCmean*ddhcc)/pth_mean;
  22.  
  23. K1 = 10000; %pth
  24. K2 = 1; %ctn
  25. K3 = (9.245e-5)*K2 - 0.00165*K1 + 2323.62; %dthh
  26. K4 = 10;
  27. K5 = 0.1;
  28.  
  29. pthp = K_PTH * (1/(1+(ca/IC50))) - dpth*pth;
  30. dthhp = K_DHCC*pth - ddhcc*dthh;
  31. ctnp = K_CTN * ((ca/EC50)/(1+(ca/EC50))) - dctn * ctn;
  32. cap = K1*pth - K2*ctn + K3*dthh - ca*K4*((ctn/pth)/(1+(ctn/pth))) - K5*ca;
  33.  
  34. xp = [cap;pthp;dthhp;ctnp];
  35.  
  36. ------- different file: ode_driver.m ---------
  37. [t,y] = ode45(@f,[0,10],[95,35.8e-6,2.163e-2,2e-6]);
  38. subplot(4,1,1);
  39. plot(t,y(:,1));
  40. legend('cap');
  41. subplot(4,1,2);
  42. plot(t,y(:,2));
  43. legend('PTH');
  44. subplot(4,1,3);
  45. plot(t,y(:,3));
  46. legend('dthh');
  47. subplot(4,1,4);
  48. plot(t,y(:,4));
  49. legend('ctn');
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement