-
Notifications
You must be signed in to change notification settings - Fork 0
/
cellmodel_Driver_nk02.m
167 lines (141 loc) · 3.33 KB
/
cellmodel_Driver_nk02.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
%% Whole cell model initial values of species
% define initial conditions
rmr_0; em_0; rmq_0; rmt_0; et_0; rmm_0; mt_0; mm_0; q_0; si_0; mq_0; mr_0 = 0;
r_0= 10.0;
a_0= 1000.0;
init= [rmr_0 em_0 rmq_0 rmt_0 et_0 rmm_0 mt_0 mm_0 q_0 si_0 mq_0 mr_0 r_0 a_0];
%% Synthetic gene circuit initial values of species
% initial amounts of species:
mp_0= 0;
rmp_0= 0;
p_0= 0;
% add initial amounts of species into the init array (includes initial amounts of species of whole cell model)
init = [init mp_0 rmp_0 p_0];
%% call solver routine
t0= 0;
tf= 1e9;
[t,y]= ode15s(@(t,y) cellmodel_odes_nk02(t, y), [t0 tf], init);
% whole cell model molecular species
rmr= y(:,1); % mrna-ribo complex of ribosomal proteins
em= y(:,2); % protein metabolic enzyme
rmq= y(:,3); % mrna-ribo complex of housekeeping proteins
rmt= y(:,4); % mrna-ribo complex of transporter enzyme proteins
et= y(:,5); % protein transporter enzyme
rmm= y(:,6); % mrna-ribo complex of metabolic enzyme proteins
mt= y(:,7); % mrna of transporter enzyme
mm= y(:,8); % mrna of metabolic enzyme
q= y(:,9); % protein housekeeping
si= y(:,10); % internal nutrients
mq= y(:,11); % mrna of house-keeping protein
mr= y(:,12); % mrna of ribosomal proteins
r= y(:,13); % free ribosomes
a= y(:,14); % energy
% synthetic gene circuits molecular species
mp= y(:,15);
rmp= y(:,16);
p= y(:,17);
%% plotting
close all;
f1 = figure;
subplot(3,3,1);
loglog(t,si);
xlabel('time');
ylabel('internal nutrients');
title('Whole cell model species');
ylim([1e-15 1e5]);
xlim([1e-5 1e510]);
hold on
subplot(3,3,2);
loglog(t,a);
xlabel('time');
ylabel('energy');
title('Whole cell model species');
ylim([1e-15 1e5]);
xlim([1e-5 1e510]);
hold on
subplot(3,3,3);
loglog(t,r);
xlabel('time');
ylabel('free ribosomes');
title('Whole cell model species');
ylim([1e-15 1e5]);
xlim([1e-5 1e510]);
hold on
subplot(3,3,4);
loglog(t,et);
xlabel('time');
ylabel('transporter enzymes');
title('Whole cell model species');
ylim([1e-15 1e5]);
xlim([1e-5 1e510]);
hold on
subplot(3,3,5);
loglog(t,em);
xlabel('time');
ylabel('metabolic enzymes');
title('Whole cell model species');
ylim([1e-15 1e5]);
xlim([1e-5 1e510]);
hold on
subplot(3,3,6);
loglog(t,q);
xlabel('time');
ylabel('housekeping proteins');
title('Whole cell model species');
ylim([1e-15 1e10]);
xlim([1e-5 1e510]);
hold on
subplot(3,3,7);
loglog(t,mm);
xlabel('time');
ylabel('mRNAs of m, t & q');
title('Whole cell model species');
ylim([1e-15 1e5]);
xlim([1e-5 1e510]);
hold on
loglog(t,mt);
hold on
loglog(t,mq);
hold on
subplot(3,3,8);
loglog(t,mr);
xlabel('time');
ylabel('mRNA of ribosomal proteins');
title('Whole cell model species');
ylim([1e-15 1e5]);
xlim([1e-5 1e510]);
hold on
act_tl_r = rmr + rmq + rmt + rmm;
subplot(3,3,9);
loglog(t,act_tl_r);
xlabel('time');
ylabel('translating ribosomes');
title('Whole cell model species');
ylim([1e-15 1e5]);
xlim([1e-5 1e510]);
hold off
f2 = figure;
subplot(3,3,1);
loglog(t,mp);
xlabel('time');
ylabel('mRNA');
title('synthetic circuit species');
ylim([1e-15 1e5]);
xlim([1e-5 1e510]);
hold on
subplot(3,3,2);
loglog(t,rmp);
xlabel('time');
ylabel('ribocomplex');
title('synthetic circuit species');
ylim([1e-15 1e5]);
xlim([1e-5 1e510]);
hold on
subplot(3,3,3);
loglog(t,p);
xlabel('time');
ylabel('protein');
title('synthetic circuit species');
ylim([1e-15 1e10]);
xlim([1e-5 1e510]);
hold off