1
|
-- This file has been generated by CoCoSim2.
|
2
|
|
3
|
-- Compiler: Lustre compiler 2 (ToLustre.m)
|
4
|
-- Time: 28-Jun-2018 10:59:12
|
5
|
--external libraries
|
6
|
node int_to_bool (x: int)
|
7
|
returns(y:bool);
|
8
|
let
|
9
|
y= (x <> 0);
|
10
|
tel
|
11
|
|
12
|
--Simulink code
|
13
|
|
14
|
|
15
|
|
16
|
|
17
|
|
18
|
|
19
|
|
20
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/require3 pre Population = environmentCapacity/arrow
|
21
|
node arrow_2967_000 (initialvalue_1: bool;
|
22
|
nextvalue_1: bool;
|
23
|
__time_step:real;)
|
24
|
returns (output_1: bool;);
|
25
|
|
26
|
var Memory_1: bool;Switch_1: bool;false_1: bool;
|
27
|
let
|
28
|
Memory_1 = int_to_bool(1) -> pre( false_1 ) ;
|
29
|
Switch_1 = if Memory_1 then initialvalue_1 else nextvalue_1;
|
30
|
false_1 = false;
|
31
|
output_1 = Switch_1;
|
32
|
|
33
|
tel
|
34
|
|
35
|
|
36
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/require3 pre Population = environmentCapacity
|
37
|
node require3prePopulation_equal_environmentCapacity_2964_001 (environmentCapacity_1: real;
|
38
|
prePopulation_1: real;
|
39
|
__time_step:real;)
|
40
|
returns (require_1: bool;);
|
41
|
|
42
|
var arrow_1: bool;equals_1: bool;true_1: bool;
|
43
|
let
|
44
|
(arrow_1) = arrow_2967_000(true_1,
|
45
|
equals_1,
|
46
|
__time_step);
|
47
|
equals_1 = prePopulation_1 = environmentCapacity_1;
|
48
|
true_1 = true;
|
49
|
require_1 = arrow_1;
|
50
|
|
51
|
tel
|
52
|
|
53
|
|
54
|
|
55
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/require2 pre Population > environmentCapacity
|
56
|
node require2prePopulation_environmentCapacity_2956_000 (environmentCapacity_1: real;
|
57
|
prePopulation_1: real;
|
58
|
__time_step:real;)
|
59
|
returns (require_1: bool;);
|
60
|
|
61
|
var RelationalOperator_1: bool;
|
62
|
let
|
63
|
RelationalOperator_1 = prePopulation_1 > environmentCapacity_1;
|
64
|
require_1 = RelationalOperator_1;
|
65
|
|
66
|
tel
|
67
|
|
68
|
|
69
|
|
70
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/require1 pre Population < environmentCapacity
|
71
|
node require1prePopulation_environmentCapacity_2948_000 (environmentCapacity_1: real;
|
72
|
prePopulation_1: real;
|
73
|
__time_step:real;)
|
74
|
returns (require_1: bool;);
|
75
|
|
76
|
var RelationalOperator_1: bool;
|
77
|
let
|
78
|
RelationalOperator_1 = prePopulation_1 < environmentCapacity_1;
|
79
|
require_1 = RelationalOperator_1;
|
80
|
|
81
|
tel
|
82
|
|
83
|
|
84
|
|
85
|
|
86
|
|
87
|
|
88
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/initialPopulation/arrow
|
89
|
node arrow_2928_000 (initialvalue_1: real;
|
90
|
nextvalue_1: real;
|
91
|
__time_step:real;)
|
92
|
returns (output_1: real;);
|
93
|
|
94
|
var Memory_1: bool;Switch_1: real;false_1: bool;
|
95
|
let
|
96
|
Memory_1 = int_to_bool(1) -> pre( false_1 ) ;
|
97
|
Switch_1 = if Memory_1 then initialvalue_1 else nextvalue_1;
|
98
|
false_1 = false;
|
99
|
output_1 = Switch_1;
|
100
|
|
101
|
tel
|
102
|
|
103
|
|
104
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/initialPopulation
|
105
|
node initialPopulation_2926_000 (input_1: real;
|
106
|
__time_step:real;)
|
107
|
returns (output_1: real;);
|
108
|
|
109
|
var arrow_1: real;preoutput_1: real;
|
110
|
let
|
111
|
(arrow_1) = arrow_2928_000(input_1,
|
112
|
preoutput_1,
|
113
|
__time_step);
|
114
|
preoutput_1 = 1.000000000000000 -> pre( arrow_1 ) ;
|
115
|
output_1 = arrow_1;
|
116
|
|
117
|
tel
|
118
|
|
119
|
|
120
|
|
121
|
|
122
|
|
123
|
|
124
|
|
125
|
|
126
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee4/sofar/arrow
|
127
|
node arrow_2866_001 (initialvalue_1: bool;
|
128
|
nextvalue_1: bool;
|
129
|
__time_step:real;)
|
130
|
returns (output_1: bool;);
|
131
|
|
132
|
var Memory_1: bool;Switch_1: bool;false_1: bool;
|
133
|
let
|
134
|
Memory_1 = int_to_bool(1) -> pre( false_1 ) ;
|
135
|
Switch_1 = if Memory_1 then initialvalue_1 else nextvalue_1;
|
136
|
false_1 = false;
|
137
|
output_1 = Switch_1;
|
138
|
|
139
|
tel
|
140
|
|
141
|
|
142
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee4/sofar
|
143
|
node sofar_2863_001 (input_1: bool;
|
144
|
__time_step:real;)
|
145
|
returns (output_1: bool;);
|
146
|
|
147
|
var and_1: bool;arrow_1: bool;preoutput_1: bool;
|
148
|
let
|
149
|
and_1 = input_1 and preoutput_1;
|
150
|
(arrow_1) = arrow_2866_001(input_1,
|
151
|
and_1,
|
152
|
__time_step);
|
153
|
preoutput_1 = int_to_bool(1) -> pre( arrow_1 ) ;
|
154
|
output_1 = arrow_1;
|
155
|
|
156
|
tel
|
157
|
|
158
|
|
159
|
|
160
|
|
161
|
|
162
|
|
163
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee4/hasHappened/arrow
|
164
|
node arrow_2839_000 (initialvalue_1: bool;
|
165
|
nextvalue_1: bool;
|
166
|
__time_step:real;)
|
167
|
returns (output_1: bool;);
|
168
|
|
169
|
var Memory_1: bool;Switch_1: bool;false_1: bool;
|
170
|
let
|
171
|
Memory_1 = int_to_bool(1) -> pre( false_1 ) ;
|
172
|
Switch_1 = if Memory_1 then initialvalue_1 else nextvalue_1;
|
173
|
false_1 = false;
|
174
|
output_1 = Switch_1;
|
175
|
|
176
|
tel
|
177
|
|
178
|
|
179
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee4/hasHappened
|
180
|
node hasHappened_2837_001 (input_1: bool;
|
181
|
__time_step:real;)
|
182
|
returns (output_1: bool;);
|
183
|
|
184
|
var arrow_1: bool;false_1: bool;or_1: bool;preoutput_1: bool;
|
185
|
let
|
186
|
(arrow_1) = arrow_2839_000(false_1,
|
187
|
preoutput_1,
|
188
|
__time_step);
|
189
|
false_1 = false;
|
190
|
or_1 = input_1 or arrow_1;
|
191
|
preoutput_1 = int_to_bool(1) -> pre( or_1 ) ;
|
192
|
output_1 = or_1;
|
193
|
|
194
|
tel
|
195
|
|
196
|
|
197
|
|
198
|
|
199
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee4/arrow1
|
200
|
node arrow1_700_000 (initialvalue_1: bool;
|
201
|
nextvalue_1: bool;
|
202
|
__time_step:real;)
|
203
|
returns (output_1: bool;);
|
204
|
|
205
|
var Memory_1: bool;Switch_1: bool;false_1: bool;
|
206
|
let
|
207
|
Memory_1 = int_to_bool(1) -> pre( false_1 ) ;
|
208
|
Switch_1 = if Memory_1 then initialvalue_1 else nextvalue_1;
|
209
|
false_1 = false;
|
210
|
output_1 = Switch_1;
|
211
|
|
212
|
tel
|
213
|
|
214
|
|
215
|
|
216
|
|
217
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee4/arrow
|
218
|
node arrow_688_001 (initialvalue_1: bool;
|
219
|
nextvalue_1: bool;
|
220
|
__time_step:real;)
|
221
|
returns (output_1: bool;);
|
222
|
|
223
|
var Memory_1: bool;Switch_1: bool;false_1: bool;
|
224
|
let
|
225
|
Memory_1 = int_to_bool(1) -> pre( false_1 ) ;
|
226
|
Switch_1 = if Memory_1 then initialvalue_1 else nextvalue_1;
|
227
|
false_1 = false;
|
228
|
output_1 = Switch_1;
|
229
|
|
230
|
tel
|
231
|
|
232
|
|
233
|
|
234
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee4/Implication
|
235
|
node Implication_674_001 (A1_1: bool;
|
236
|
B1_1: bool;
|
237
|
__time_step:real;)
|
238
|
returns (A_equal__equal__B_1: bool;);
|
239
|
|
240
|
var LogicalOperator_1: bool;LogicalOperator1_1: bool;
|
241
|
let
|
242
|
LogicalOperator_1 = LogicalOperator1_1 or B1_1;
|
243
|
LogicalOperator1_1 = not A1_1;
|
244
|
A_equal__equal__B_1 = LogicalOperator_1;
|
245
|
|
246
|
tel
|
247
|
|
248
|
|
249
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee4
|
250
|
node guarantee4_671_001 (population_1: real;
|
251
|
environmentCapacity_1: real;
|
252
|
__time_step:real;)
|
253
|
returns (guarantee_1: bool;);
|
254
|
|
255
|
var Implication_1: bool;LogicalOperator_1: bool;RelationalOperator_1: bool;RelationalOperator1_1: bool;RelationalOperator2_1: bool;arrow_1: bool;arrow1_1: bool;hasHappened_1: bool;prepopulation_1: real;sofar_1: bool;true_1: bool;true1_1: bool;
|
256
|
let
|
257
|
(Implication_1) = Implication_674_001(LogicalOperator_1,
|
258
|
sofar_1,
|
259
|
__time_step);
|
260
|
LogicalOperator_1 = hasHappened_1 and RelationalOperator1_1 and RelationalOperator2_1;
|
261
|
RelationalOperator_1 = population_1 < prepopulation_1;
|
262
|
RelationalOperator1_1 = prepopulation_1 > environmentCapacity_1;
|
263
|
RelationalOperator2_1 = population_1 > environmentCapacity_1;
|
264
|
(arrow_1) = arrow_688_001(true_1,
|
265
|
Implication_1,
|
266
|
__time_step);
|
267
|
(arrow1_1) = arrow1_700_000(true1_1,
|
268
|
RelationalOperator_1,
|
269
|
__time_step);
|
270
|
(hasHappened_1) = hasHappened_2837_001(RelationalOperator_1,
|
271
|
__time_step);
|
272
|
prepopulation_1 = 0.000000000000000 -> pre( population_1 ) ;
|
273
|
(sofar_1) = sofar_2863_001(arrow1_1,
|
274
|
__time_step);
|
275
|
true_1 = true;
|
276
|
true1_1 = true;
|
277
|
guarantee_1 = arrow_1;
|
278
|
|
279
|
tel
|
280
|
|
281
|
|
282
|
|
283
|
|
284
|
|
285
|
|
286
|
|
287
|
|
288
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee3/sofar/arrow
|
289
|
node arrow_622_000 (initialvalue_1: bool;
|
290
|
nextvalue_1: bool;
|
291
|
__time_step:real;)
|
292
|
returns (output_1: bool;);
|
293
|
|
294
|
var Memory_1: bool;Switch_1: bool;false_1: bool;
|
295
|
let
|
296
|
Memory_1 = int_to_bool(1) -> pre( false_1 ) ;
|
297
|
Switch_1 = if Memory_1 then initialvalue_1 else nextvalue_1;
|
298
|
false_1 = false;
|
299
|
output_1 = Switch_1;
|
300
|
|
301
|
tel
|
302
|
|
303
|
|
304
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee3/sofar
|
305
|
node sofar_619_000 (input_1: bool;
|
306
|
__time_step:real;)
|
307
|
returns (output_1: bool;);
|
308
|
|
309
|
var and_1: bool;arrow_1: bool;preoutput_1: bool;
|
310
|
let
|
311
|
and_1 = input_1 and preoutput_1;
|
312
|
(arrow_1) = arrow_622_000(input_1,
|
313
|
and_1,
|
314
|
__time_step);
|
315
|
preoutput_1 = int_to_bool(1) -> pre( arrow_1 ) ;
|
316
|
output_1 = arrow_1;
|
317
|
|
318
|
tel
|
319
|
|
320
|
|
321
|
|
322
|
|
323
|
|
324
|
|
325
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee3/hasHappened/arrow
|
326
|
node arrow_595_000 (initialvalue_1: bool;
|
327
|
nextvalue_1: bool;
|
328
|
__time_step:real;)
|
329
|
returns (output_1: bool;);
|
330
|
|
331
|
var Memory_1: bool;Switch_1: bool;false_1: bool;
|
332
|
let
|
333
|
Memory_1 = int_to_bool(1) -> pre( false_1 ) ;
|
334
|
Switch_1 = if Memory_1 then initialvalue_1 else nextvalue_1;
|
335
|
false_1 = false;
|
336
|
output_1 = Switch_1;
|
337
|
|
338
|
tel
|
339
|
|
340
|
|
341
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee3/hasHappened
|
342
|
node hasHappened_593_000 (input_1: bool;
|
343
|
__time_step:real;)
|
344
|
returns (output_1: bool;);
|
345
|
|
346
|
var arrow_1: bool;false_1: bool;or_1: bool;preoutput_1: bool;
|
347
|
let
|
348
|
(arrow_1) = arrow_595_000(false_1,
|
349
|
preoutput_1,
|
350
|
__time_step);
|
351
|
false_1 = false;
|
352
|
or_1 = input_1 or arrow_1;
|
353
|
preoutput_1 = int_to_bool(1) -> pre( or_1 ) ;
|
354
|
output_1 = or_1;
|
355
|
|
356
|
tel
|
357
|
|
358
|
|
359
|
|
360
|
|
361
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee3/arrow1
|
362
|
node arrow1_581_001 (initialvalue_1: bool;
|
363
|
nextvalue_1: bool;
|
364
|
__time_step:real;)
|
365
|
returns (output_1: bool;);
|
366
|
|
367
|
var Memory_1: bool;Switch_1: bool;false_1: bool;
|
368
|
let
|
369
|
Memory_1 = int_to_bool(1) -> pre( false_1 ) ;
|
370
|
Switch_1 = if Memory_1 then initialvalue_1 else nextvalue_1;
|
371
|
false_1 = false;
|
372
|
output_1 = Switch_1;
|
373
|
|
374
|
tel
|
375
|
|
376
|
|
377
|
|
378
|
|
379
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee3/arrow
|
380
|
node arrow_569_000 (initialvalue_1: bool;
|
381
|
nextvalue_1: bool;
|
382
|
__time_step:real;)
|
383
|
returns (output_1: bool;);
|
384
|
|
385
|
var Memory_1: bool;Switch_1: bool;false_1: bool;
|
386
|
let
|
387
|
Memory_1 = int_to_bool(1) -> pre( false_1 ) ;
|
388
|
Switch_1 = if Memory_1 then initialvalue_1 else nextvalue_1;
|
389
|
false_1 = false;
|
390
|
output_1 = Switch_1;
|
391
|
|
392
|
tel
|
393
|
|
394
|
|
395
|
|
396
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee3/Implication
|
397
|
node Implication_555_000 (A1_1: bool;
|
398
|
B1_1: bool;
|
399
|
__time_step:real;)
|
400
|
returns (A_equal__equal__B_1: bool;);
|
401
|
|
402
|
var LogicalOperator_1: bool;LogicalOperator1_1: bool;
|
403
|
let
|
404
|
LogicalOperator_1 = LogicalOperator1_1 or B1_1;
|
405
|
LogicalOperator1_1 = not A1_1;
|
406
|
A_equal__equal__B_1 = LogicalOperator_1;
|
407
|
|
408
|
tel
|
409
|
|
410
|
|
411
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee3
|
412
|
node guarantee3_552_000 (population_1: real;
|
413
|
environmentCapacity_1: real;
|
414
|
__time_step:real;)
|
415
|
returns (guarantee_1: bool;);
|
416
|
|
417
|
var Implication_1: bool;LogicalOperator_1: bool;RelationalOperator_1: bool;RelationalOperator1_1: bool;RelationalOperator2_1: bool;arrow_1: bool;arrow1_1: bool;hasHappened_1: bool;prepopulation_1: real;sofar_1: bool;true_1: bool;true1_1: bool;
|
418
|
let
|
419
|
(Implication_1) = Implication_555_000(LogicalOperator_1,
|
420
|
sofar_1,
|
421
|
__time_step);
|
422
|
LogicalOperator_1 = hasHappened_1 and RelationalOperator1_1 and RelationalOperator2_1;
|
423
|
RelationalOperator_1 = population_1 > prepopulation_1;
|
424
|
RelationalOperator1_1 = prepopulation_1 < environmentCapacity_1;
|
425
|
RelationalOperator2_1 = population_1 < environmentCapacity_1;
|
426
|
(arrow_1) = arrow_569_000(true_1,
|
427
|
Implication_1,
|
428
|
__time_step);
|
429
|
(arrow1_1) = arrow1_581_001(true1_1,
|
430
|
RelationalOperator_1,
|
431
|
__time_step);
|
432
|
(hasHappened_1) = hasHappened_593_000(RelationalOperator_1,
|
433
|
__time_step);
|
434
|
prepopulation_1 = 0.000000000000000 -> pre( population_1 ) ;
|
435
|
(sofar_1) = sofar_619_000(arrow1_1,
|
436
|
__time_step);
|
437
|
true_1 = true;
|
438
|
true1_1 = true;
|
439
|
guarantee_1 = arrow_1;
|
440
|
|
441
|
tel
|
442
|
|
443
|
|
444
|
|
445
|
|
446
|
|
447
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee1/arrow
|
448
|
node arrow_533_000 (initialvalue_1: bool;
|
449
|
nextvalue_1: bool;
|
450
|
__time_step:real;)
|
451
|
returns (output_1: bool;);
|
452
|
|
453
|
var Memory_1: bool;Switch_1: bool;false_1: bool;
|
454
|
let
|
455
|
Memory_1 = int_to_bool(1) -> pre( false_1 ) ;
|
456
|
Switch_1 = if Memory_1 then initialvalue_1 else nextvalue_1;
|
457
|
false_1 = false;
|
458
|
output_1 = Switch_1;
|
459
|
|
460
|
tel
|
461
|
|
462
|
|
463
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee1
|
464
|
node guarantee1_529_001 (population_1: real;
|
465
|
initialPopulation_1: real;
|
466
|
__time_step:real;)
|
467
|
returns (guarantee_1: bool;);
|
468
|
|
469
|
var RelationalOperator_1: bool;arrow_1: bool;true_1: bool;
|
470
|
let
|
471
|
RelationalOperator_1 = population_1 = initialPopulation_1;
|
472
|
(arrow_1) = arrow_533_000(RelationalOperator_1,
|
473
|
true_1,
|
474
|
__time_step);
|
475
|
true_1 = true;
|
476
|
guarantee_1 = arrow_1;
|
477
|
|
478
|
tel
|
479
|
|
480
|
|
481
|
|
482
|
|
483
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee population > 0/Compare--To Zero1
|
484
|
node CompareToZero1_518_001 (u_1: real;
|
485
|
__time_step:real;)
|
486
|
returns (y_1: bool;);
|
487
|
|
488
|
var Compare_1: bool;Constant_1: real;
|
489
|
let
|
490
|
Compare_1 = u_1 > Constant_1;
|
491
|
Constant_1 = 0.000000000000000;
|
492
|
y_1 = Compare_1;
|
493
|
|
494
|
tel
|
495
|
|
496
|
|
497
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/guarantee population > 0
|
498
|
node guaranteepopulation_0_516_001 (population_1: real;
|
499
|
__time_step:real;)
|
500
|
returns (guarantee_1: bool;);
|
501
|
|
502
|
var CompareToZero1_1: bool;
|
503
|
let
|
504
|
(CompareToZero1_1) = CompareToZero1_518_001(population_1,
|
505
|
__time_step);
|
506
|
guarantee_1 = CompareToZero1_1;
|
507
|
|
508
|
tel
|
509
|
|
510
|
|
511
|
|
512
|
|
513
|
|
514
|
|
515
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/ensure3/arrow
|
516
|
node arrow_493_000 (initialvalue_1: bool;
|
517
|
nextvalue_1: bool;
|
518
|
__time_step:real;)
|
519
|
returns (output_1: bool;);
|
520
|
|
521
|
var Memory_1: bool;Switch_1: bool;false_1: bool;
|
522
|
let
|
523
|
Memory_1 = int_to_bool(1) -> pre( false_1 ) ;
|
524
|
Switch_1 = if Memory_1 then initialvalue_1 else nextvalue_1;
|
525
|
false_1 = false;
|
526
|
output_1 = Switch_1;
|
527
|
|
528
|
tel
|
529
|
|
530
|
|
531
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/ensure3
|
532
|
node ensure3_490_000 (population_1: real;
|
533
|
__time_step:real;)
|
534
|
returns (ensure_1: bool;);
|
535
|
|
536
|
var RelationalOperator1_1: bool;arrow_1: bool;prepopulation_1: real;true_1: bool;
|
537
|
let
|
538
|
RelationalOperator1_1 = population_1 = prepopulation_1;
|
539
|
(arrow_1) = arrow_493_000(true_1,
|
540
|
RelationalOperator1_1,
|
541
|
__time_step);
|
542
|
prepopulation_1 = 0.000000000000000 -> pre( population_1 ) ;
|
543
|
true_1 = true;
|
544
|
ensure_1 = arrow_1;
|
545
|
|
546
|
tel
|
547
|
|
548
|
|
549
|
|
550
|
|
551
|
|
552
|
|
553
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/ensure2/arrow
|
554
|
node arrow_468_001 (initialvalue_1: bool;
|
555
|
nextvalue_1: bool;
|
556
|
__time_step:real;)
|
557
|
returns (output_1: bool;);
|
558
|
|
559
|
var Memory_1: bool;Switch_1: bool;false_1: bool;
|
560
|
let
|
561
|
Memory_1 = int_to_bool(1) -> pre( false_1 ) ;
|
562
|
Switch_1 = if Memory_1 then initialvalue_1 else nextvalue_1;
|
563
|
false_1 = false;
|
564
|
output_1 = Switch_1;
|
565
|
|
566
|
tel
|
567
|
|
568
|
|
569
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/ensure2
|
570
|
node ensure2_465_001 (population_1: real;
|
571
|
__time_step:real;)
|
572
|
returns (ensure_1: bool;);
|
573
|
|
574
|
var RelationalOperator1_1: bool;arrow_1: bool;prepopulation_1: real;true_1: bool;
|
575
|
let
|
576
|
RelationalOperator1_1 = population_1 < prepopulation_1;
|
577
|
(arrow_1) = arrow_468_001(true_1,
|
578
|
RelationalOperator1_1,
|
579
|
__time_step);
|
580
|
prepopulation_1 = 0.000000000000000 -> pre( population_1 ) ;
|
581
|
true_1 = true;
|
582
|
ensure_1 = arrow_1;
|
583
|
|
584
|
tel
|
585
|
|
586
|
|
587
|
|
588
|
|
589
|
|
590
|
|
591
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/ensure1/arrow
|
592
|
node arrow_442_000 (initialvalue_1: bool;
|
593
|
nextvalue_1: bool;
|
594
|
__time_step:real;)
|
595
|
returns (output_1: bool;);
|
596
|
|
597
|
var Memory_1: bool;Switch_1: bool;false_1: bool;
|
598
|
let
|
599
|
Memory_1 = int_to_bool(1) -> pre( false_1 ) ;
|
600
|
Switch_1 = if Memory_1 then initialvalue_1 else nextvalue_1;
|
601
|
false_1 = false;
|
602
|
output_1 = Switch_1;
|
603
|
|
604
|
tel
|
605
|
|
606
|
|
607
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/ensure1
|
608
|
node ensure1_440_000 (population_1: real;
|
609
|
__time_step:real;)
|
610
|
returns (ensure_1: bool;);
|
611
|
|
612
|
var arrow_1: bool;greaterthan_1: bool;prepopulation_1: real;true_1: bool;
|
613
|
let
|
614
|
(arrow_1) = arrow_442_000(true_1,
|
615
|
greaterthan_1,
|
616
|
__time_step);
|
617
|
greaterthan_1 = population_1 > prepopulation_1;
|
618
|
prepopulation_1 = 0.000000000000000 -> pre( population_1 ) ;
|
619
|
true_1 = true;
|
620
|
ensure_1 = arrow_1;
|
621
|
|
622
|
tel
|
623
|
|
624
|
|
625
|
|
626
|
|
627
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/assume initialPopulation > 0/Compare--To Zero
|
628
|
node CompareToZero_418_000 (u_1: real;
|
629
|
__time_step:real;)
|
630
|
returns (y_1: bool;);
|
631
|
|
632
|
var Compare_1: bool;Constant_1: real;
|
633
|
let
|
634
|
Compare_1 = u_1 > Constant_1;
|
635
|
Constant_1 = 0.000000000000000;
|
636
|
y_1 = Compare_1;
|
637
|
|
638
|
tel
|
639
|
|
640
|
|
641
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec/assume initialPopulation > 0
|
642
|
node assumeinitialPopulation_0_416_000 (initialPopulation_1: real;
|
643
|
__time_step:real;)
|
644
|
returns (assume_1: bool;);
|
645
|
|
646
|
var CompareToZero_1: bool;
|
647
|
let
|
648
|
(CompareToZero_1) = CompareToZero_418_000(initialPopulation_1,
|
649
|
__time_step);
|
650
|
assume_1 = CompareToZero_1;
|
651
|
|
652
|
tel
|
653
|
|
654
|
|
655
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulationSpec
|
656
|
(*@
|
657
|
contract bacteriaPopulationSpec_412_000 (population0_1: real;
|
658
|
__time_step:real;)
|
659
|
returns (population_1: real;);
|
660
|
|
661
|
|
662
|
let
|
663
|
assume "assumeinitialPopulation_0_416_000" assumeinitialPopulation_0_416_000(initialPopulation_1,
|
664
|
__time_step);
|
665
|
mode decreasing_429_000(
|
666
|
require require2prePopulation_environmentCapacity_1;
|
667
|
ensure ensure2_1;
|
668
|
);
|
669
|
var ensure1_1: bool = ensure1_440_000(population_1,
|
670
|
__time_step);
|
671
|
var ensure2_1: bool = ensure2_465_001(population_1,
|
672
|
__time_step);
|
673
|
var ensure3_1: bool = ensure3_490_000(population_1,
|
674
|
__time_step);
|
675
|
var environmentCapacity_1: real = 32.000000000000000;
|
676
|
guarantee "guaranteepopulation_0_516_001" guaranteepopulation_0_516_001(population_1,
|
677
|
__time_step);
|
678
|
guarantee "guarantee1_529_001" guarantee1_529_001(population_1,
|
679
|
initialPopulation_1,
|
680
|
__time_step);
|
681
|
guarantee "guarantee3_552_000" guarantee3_552_000(population_1,
|
682
|
environmentCapacity_1,
|
683
|
__time_step);
|
684
|
guarantee "guarantee4_671_001" guarantee4_671_001(population_1,
|
685
|
environmentCapacity_1,
|
686
|
__time_step);
|
687
|
mode increasing_2915_001(
|
688
|
require require1prePopulation_environmentCapacity_1;
|
689
|
ensure ensure1_1;
|
690
|
);
|
691
|
var initialPopulation_1: real = initialPopulation_2926_000(population0_1,
|
692
|
__time_step);
|
693
|
var prepopulation_1: real = 0.000000000000000 -> pre( population_1 ) ;
|
694
|
var require1prePopulation_environmentCapacity_1: bool = require1prePopulation_environmentCapacity_2948_000(environmentCapacity_1,
|
695
|
prepopulation_1,
|
696
|
__time_step);
|
697
|
var require2prePopulation_environmentCapacity_1: bool = require2prePopulation_environmentCapacity_2956_000(environmentCapacity_1,
|
698
|
prepopulation_1,
|
699
|
__time_step);
|
700
|
var require3prePopulation_equal_environmentCapacity_1: bool = require3prePopulation_equal_environmentCapacity_2964_001(environmentCapacity_1,
|
701
|
prepopulation_1,
|
702
|
__time_step);
|
703
|
mode stable_2987_000(
|
704
|
require require3prePopulation_equal_environmentCapacity_1;
|
705
|
ensure ensure3_1;
|
706
|
);
|
707
|
|
708
|
tel
|
709
|
*)
|
710
|
|
711
|
|
712
|
|
713
|
|
714
|
|
715
|
|
716
|
|
717
|
|
718
|
|
719
|
|
720
|
|
721
|
|
722
|
|
723
|
|
724
|
|
725
|
-- Entry action for state :bacteriaPopulation_stable65
|
726
|
node bacteriaPopulation_stable65_en(idbacteriaPopulation_bacteriaPopulation63_1:int;
|
727
|
population_1:real;
|
728
|
prePopulation_1:real;
|
729
|
isInner:bool)
|
730
|
|
731
|
returns (idbacteriaPopulation_bacteriaPopulation63:int;
|
732
|
population:real;
|
733
|
prePopulation:real);
|
734
|
|
735
|
|
736
|
var idbacteriaPopulation_bacteriaPopulation63_2:int;
|
737
|
prePopulation_2:real;
|
738
|
|
739
|
|
740
|
let
|
741
|
|
742
|
|
743
|
|
744
|
-- set state as active
|
745
|
idbacteriaPopulation_bacteriaPopulation63_2
|
746
|
= 65;
|
747
|
|
748
|
|
749
|
prePopulation_2
|
750
|
= if (not isInner) then population_1
|
751
|
else prePopulation_1;
|
752
|
|
753
|
|
754
|
(idbacteriaPopulation_bacteriaPopulation63, population, prePopulation)
|
755
|
= (idbacteriaPopulation_bacteriaPopulation63_2, population_1, prePopulation_2);
|
756
|
|
757
|
|
758
|
tel
|
759
|
|
760
|
|
761
|
|
762
|
|
763
|
|
764
|
-- Exit action for state :bacteriaPopulation_stable65
|
765
|
node bacteriaPopulation_stable65_ex(idbacteriaPopulation_bacteriaPopulation63_1:int;
|
766
|
isInner:bool)
|
767
|
|
768
|
returns (idbacteriaPopulation_bacteriaPopulation63:int);
|
769
|
|
770
|
|
771
|
var idbacteriaPopulation_bacteriaPopulation63_2:int;
|
772
|
|
773
|
|
774
|
let
|
775
|
|
776
|
|
777
|
|
778
|
-- set state as inactive
|
779
|
idbacteriaPopulation_bacteriaPopulation63_2
|
780
|
= if (not isInner) then 0 else idbacteriaPopulation_bacteriaPopulation63_1;
|
781
|
|
782
|
|
783
|
(idbacteriaPopulation_bacteriaPopulation63)
|
784
|
= (idbacteriaPopulation_bacteriaPopulation63_1);
|
785
|
|
786
|
|
787
|
tel
|
788
|
|
789
|
|
790
|
|
791
|
|
792
|
|
793
|
|
794
|
-- Entry action for state :bacteriaPopulation_increasing64
|
795
|
node bacteriaPopulation_increasing64_en(idbacteriaPopulation_bacteriaPopulation63_1:int;
|
796
|
population_1:real;
|
797
|
prePopulation_1:real;
|
798
|
isInner:bool)
|
799
|
|
800
|
returns (idbacteriaPopulation_bacteriaPopulation63:int;
|
801
|
population:real;
|
802
|
prePopulation:real);
|
803
|
|
804
|
|
805
|
var idbacteriaPopulation_bacteriaPopulation63_2:int;
|
806
|
population_2:real;
|
807
|
prePopulation_2:real;
|
808
|
|
809
|
|
810
|
let
|
811
|
|
812
|
|
813
|
|
814
|
-- set state as active
|
815
|
idbacteriaPopulation_bacteriaPopulation63_2
|
816
|
= 64;
|
817
|
|
818
|
|
819
|
prePopulation_2
|
820
|
= if (not isInner) then population_1
|
821
|
else prePopulation_1;
|
822
|
|
823
|
|
824
|
population_2
|
825
|
= if (not isInner) then prePopulation_2 *2.0
|
826
|
else population_1;
|
827
|
|
828
|
|
829
|
(idbacteriaPopulation_bacteriaPopulation63, population, prePopulation)
|
830
|
= (idbacteriaPopulation_bacteriaPopulation63_2, population_2, prePopulation_2);
|
831
|
|
832
|
|
833
|
tel
|
834
|
|
835
|
|
836
|
|
837
|
|
838
|
|
839
|
-- Exit action for state :bacteriaPopulation_increasing64
|
840
|
node bacteriaPopulation_increasing64_ex(idbacteriaPopulation_bacteriaPopulation63_1:int;
|
841
|
isInner:bool)
|
842
|
|
843
|
returns (idbacteriaPopulation_bacteriaPopulation63:int);
|
844
|
|
845
|
|
846
|
var idbacteriaPopulation_bacteriaPopulation63_2:int;
|
847
|
|
848
|
|
849
|
let
|
850
|
|
851
|
|
852
|
|
853
|
-- set state as inactive
|
854
|
idbacteriaPopulation_bacteriaPopulation63_2
|
855
|
= if (not isInner) then 0 else idbacteriaPopulation_bacteriaPopulation63_1;
|
856
|
|
857
|
|
858
|
(idbacteriaPopulation_bacteriaPopulation63)
|
859
|
= (idbacteriaPopulation_bacteriaPopulation63_1);
|
860
|
|
861
|
|
862
|
tel
|
863
|
|
864
|
|
865
|
|
866
|
|
867
|
|
868
|
|
869
|
-- Entry action for state :bacteriaPopulation_decreasing67
|
870
|
node bacteriaPopulation_decreasing67_en(idbacteriaPopulation_bacteriaPopulation63_1:int;
|
871
|
population_1:real;
|
872
|
prePopulation_1:real;
|
873
|
isInner:bool)
|
874
|
|
875
|
returns (idbacteriaPopulation_bacteriaPopulation63:int;
|
876
|
population:real;
|
877
|
prePopulation:real);
|
878
|
|
879
|
|
880
|
var idbacteriaPopulation_bacteriaPopulation63_2:int;
|
881
|
population_2:real;
|
882
|
prePopulation_2:real;
|
883
|
|
884
|
|
885
|
let
|
886
|
|
887
|
|
888
|
|
889
|
-- set state as active
|
890
|
idbacteriaPopulation_bacteriaPopulation63_2
|
891
|
= 67;
|
892
|
|
893
|
|
894
|
prePopulation_2
|
895
|
= if (not isInner) then population_1
|
896
|
else prePopulation_1;
|
897
|
|
898
|
|
899
|
population_2
|
900
|
= if (not isInner) then prePopulation_2 /2.0
|
901
|
else population_1;
|
902
|
|
903
|
|
904
|
(idbacteriaPopulation_bacteriaPopulation63, population, prePopulation)
|
905
|
= (idbacteriaPopulation_bacteriaPopulation63_2, population_2, prePopulation_2);
|
906
|
|
907
|
|
908
|
tel
|
909
|
|
910
|
|
911
|
|
912
|
|
913
|
|
914
|
-- Exit action for state :bacteriaPopulation_decreasing67
|
915
|
node bacteriaPopulation_decreasing67_ex(idbacteriaPopulation_bacteriaPopulation63_1:int;
|
916
|
isInner:bool)
|
917
|
|
918
|
returns (idbacteriaPopulation_bacteriaPopulation63:int);
|
919
|
|
920
|
|
921
|
var idbacteriaPopulation_bacteriaPopulation63_2:int;
|
922
|
|
923
|
|
924
|
let
|
925
|
|
926
|
|
927
|
|
928
|
-- set state as inactive
|
929
|
idbacteriaPopulation_bacteriaPopulation63_2
|
930
|
= if (not isInner) then 0 else idbacteriaPopulation_bacteriaPopulation63_1;
|
931
|
|
932
|
|
933
|
(idbacteriaPopulation_bacteriaPopulation63)
|
934
|
= (idbacteriaPopulation_bacteriaPopulation63_1);
|
935
|
|
936
|
|
937
|
tel
|
938
|
|
939
|
|
940
|
|
941
|
|
942
|
|
943
|
|
944
|
-- Entry action for state :bacteriaPopulation_start66
|
945
|
node bacteriaPopulation_start66_en(idbacteriaPopulation_bacteriaPopulation63_1:int;
|
946
|
population0:real;
|
947
|
prePopulation_1:real;
|
948
|
population_1:real;
|
949
|
isInner:bool)
|
950
|
|
951
|
returns (idbacteriaPopulation_bacteriaPopulation63:int;
|
952
|
prePopulation:real;
|
953
|
population:real);
|
954
|
|
955
|
|
956
|
var idbacteriaPopulation_bacteriaPopulation63_2:int;
|
957
|
prePopulation_2:real;
|
958
|
population_2:real;
|
959
|
|
960
|
|
961
|
let
|
962
|
|
963
|
|
964
|
|
965
|
-- set state as active
|
966
|
idbacteriaPopulation_bacteriaPopulation63_2
|
967
|
= 66;
|
968
|
|
969
|
|
970
|
prePopulation_2
|
971
|
= if (not isInner) then population0
|
972
|
else prePopulation_1;
|
973
|
|
974
|
|
975
|
population_2
|
976
|
= if (not isInner) then population0
|
977
|
else population_1;
|
978
|
|
979
|
|
980
|
(idbacteriaPopulation_bacteriaPopulation63, prePopulation, population)
|
981
|
= (idbacteriaPopulation_bacteriaPopulation63_2, prePopulation_2, population_2);
|
982
|
|
983
|
|
984
|
tel
|
985
|
|
986
|
|
987
|
|
988
|
|
989
|
|
990
|
-- Exit action for state :bacteriaPopulation_start66
|
991
|
node bacteriaPopulation_start66_ex(idbacteriaPopulation_bacteriaPopulation63_1:int;
|
992
|
isInner:bool)
|
993
|
|
994
|
returns (idbacteriaPopulation_bacteriaPopulation63:int);
|
995
|
|
996
|
|
997
|
var idbacteriaPopulation_bacteriaPopulation63_2:int;
|
998
|
|
999
|
|
1000
|
let
|
1001
|
|
1002
|
|
1003
|
|
1004
|
-- set state as inactive
|
1005
|
idbacteriaPopulation_bacteriaPopulation63_2
|
1006
|
= if (not isInner) then 0 else idbacteriaPopulation_bacteriaPopulation63_1;
|
1007
|
|
1008
|
|
1009
|
(idbacteriaPopulation_bacteriaPopulation63)
|
1010
|
= (idbacteriaPopulation_bacteriaPopulation63_1);
|
1011
|
|
1012
|
|
1013
|
tel
|
1014
|
|
1015
|
|
1016
|
--***************************************************State :bacteriaPopulation_bacteriaPopulation63 Automaton***************************************************
|
1017
|
|
1018
|
node bacteriaPopulation_bacteriaPopulation63_node(idbacteriaPopulation_bacteriaPopulation63_1:int;
|
1019
|
population_1:real;
|
1020
|
population0:real;
|
1021
|
prePopulation_1:real)
|
1022
|
|
1023
|
returns (idbacteriaPopulation_bacteriaPopulation63:int;
|
1024
|
population:real;
|
1025
|
prePopulation:real);
|
1026
|
|
1027
|
|
1028
|
let
|
1029
|
|
1030
|
automaton bacteriapopulation_bacteriapopulation63
|
1031
|
|
1032
|
state POINTbacteriaPopulation_bacteriaPopulation63:
|
1033
|
unless (idbacteriaPopulation_bacteriaPopulation63_1=0) restart POINT__TO__BACTERIAPOPULATION_START66_1
|
1034
|
|
1035
|
|
1036
|
|
1037
|
unless (idbacteriaPopulation_bacteriaPopulation63_1=64) restart BACTERIAPOPULATION_INCREASING64__TO__BACTERIAPOPULATION_BACTERIAPOPULATION63JUNCTION79_1
|
1038
|
|
1039
|
|
1040
|
|
1041
|
unless (idbacteriaPopulation_bacteriaPopulation63_1=66) restart BACTERIAPOPULATION_START66__TO__BACTERIAPOPULATION_BACTERIAPOPULATION63JUNCTION79_1
|
1042
|
|
1043
|
|
1044
|
|
1045
|
unless (idbacteriaPopulation_bacteriaPopulation63_1=67) restart BACTERIAPOPULATION_DECREASING67__TO__BACTERIAPOPULATION_BACTERIAPOPULATION63JUNCTION79_1
|
1046
|
|
1047
|
|
1048
|
|
1049
|
unless (idbacteriaPopulation_bacteriaPopulation63_1=64) restart BACTERIAPOPULATION_INCREASING64_IDL
|
1050
|
|
1051
|
unless (idbacteriaPopulation_bacteriaPopulation63_1=65) restart BACTERIAPOPULATION_STABLE65_IDL
|
1052
|
|
1053
|
unless (idbacteriaPopulation_bacteriaPopulation63_1=66) restart BACTERIAPOPULATION_START66_IDL
|
1054
|
|
1055
|
unless (idbacteriaPopulation_bacteriaPopulation63_1=67) restart BACTERIAPOPULATION_DECREASING67_IDL
|
1056
|
|
1057
|
let
|
1058
|
|
1059
|
(idbacteriaPopulation_bacteriaPopulation63, population, prePopulation)
|
1060
|
= (idbacteriaPopulation_bacteriaPopulation63_1, population_1, prePopulation_1);
|
1061
|
|
1062
|
|
1063
|
tel
|
1064
|
|
1065
|
|
1066
|
|
1067
|
state POINT__TO__BACTERIAPOPULATION_START66_1:
|
1068
|
|
1069
|
var idbacteriaPopulation_bacteriaPopulation63_2:int;
|
1070
|
population_2:real;
|
1071
|
prePopulation_2:real;
|
1072
|
let
|
1073
|
|
1074
|
-- transition trace :
|
1075
|
--POINT__To__bacteriaPopulation_start66_1
|
1076
|
(idbacteriaPopulation_bacteriaPopulation63_2, prePopulation_2, population_2)
|
1077
|
= bacteriaPopulation_start66_en(idbacteriaPopulation_bacteriaPopulation63_1, population0, prePopulation_1, population_1, false);
|
1078
|
|
1079
|
|
1080
|
(idbacteriaPopulation_bacteriaPopulation63, population, prePopulation)
|
1081
|
= (idbacteriaPopulation_bacteriaPopulation63_2, population_2, prePopulation_2);
|
1082
|
|
1083
|
|
1084
|
tel
|
1085
|
|
1086
|
until true restart POINTbacteriaPopulation_bacteriaPopulation63
|
1087
|
|
1088
|
|
1089
|
|
1090
|
state BACTERIAPOPULATION_INCREASING64__TO__BACTERIAPOPULATION_BACTERIAPOPULATION63JUNCTION79_1:
|
1091
|
|
1092
|
var idbacteriaPopulation_bacteriaPopulation63_2, idbacteriaPopulation_bacteriaPopulation63_3, idbacteriaPopulation_bacteriaPopulation63_4, idbacteriaPopulation_bacteriaPopulation63_5, idbacteriaPopulation_bacteriaPopulation63_6, idbacteriaPopulation_bacteriaPopulation63_7:int;
|
1093
|
population_2, population_3, population_4:real;
|
1094
|
prePopulation_2, prePopulation_3, prePopulation_4:real;
|
1095
|
let
|
1096
|
|
1097
|
|
1098
|
|
1099
|
-- transition trace :
|
1100
|
--bacteriaPopulation_increasing64__To__Junction79_1, Junction79__To__bacteriaPopulation_increasing64_1
|
1101
|
(idbacteriaPopulation_bacteriaPopulation63_2)
|
1102
|
=
|
1103
|
if (( population_1 <32.0 )) then
|
1104
|
bacteriaPopulation_increasing64_ex(idbacteriaPopulation_bacteriaPopulation63_1, false)
|
1105
|
else (idbacteriaPopulation_bacteriaPopulation63_1);
|
1106
|
|
1107
|
|
1108
|
(idbacteriaPopulation_bacteriaPopulation63_3, population_2, prePopulation_2)
|
1109
|
=
|
1110
|
if (( population_1 <32.0 )) then
|
1111
|
bacteriaPopulation_increasing64_en(idbacteriaPopulation_bacteriaPopulation63_2, population_1, prePopulation_1, false)
|
1112
|
else (idbacteriaPopulation_bacteriaPopulation63_2, population_1, prePopulation_1);
|
1113
|
|
1114
|
|
1115
|
|
1116
|
-- transition trace :
|
1117
|
--bacteriaPopulation_increasing64__To__Junction79_1, Junction79__To__bacteriaPopulation_decreasing67_2
|
1118
|
(idbacteriaPopulation_bacteriaPopulation63_4)
|
1119
|
=
|
1120
|
if (( population_1 >32.0 )) then
|
1121
|
bacteriaPopulation_increasing64_ex(idbacteriaPopulation_bacteriaPopulation63_1, false)
|
1122
|
else (idbacteriaPopulation_bacteriaPopulation63_1);
|
1123
|
|
1124
|
|
1125
|
(idbacteriaPopulation_bacteriaPopulation63_5, population_3, prePopulation_3)
|
1126
|
=
|
1127
|
if (( population_1 >32.0 )) then
|
1128
|
bacteriaPopulation_decreasing67_en(idbacteriaPopulation_bacteriaPopulation63_4, population_1, prePopulation_1, false)
|
1129
|
else (idbacteriaPopulation_bacteriaPopulation63_4, population_1, prePopulation_1);
|
1130
|
|
1131
|
|
1132
|
|
1133
|
-- transition trace :
|
1134
|
--bacteriaPopulation_increasing64__To__Junction79_1, Junction79__To__bacteriaPopulation_stable65_3
|
1135
|
(idbacteriaPopulation_bacteriaPopulation63_6)
|
1136
|
=
|
1137
|
if (( population_1 =32.0 )) then
|
1138
|
bacteriaPopulation_increasing64_ex(idbacteriaPopulation_bacteriaPopulation63_1, false)
|
1139
|
else (idbacteriaPopulation_bacteriaPopulation63_1);
|
1140
|
|
1141
|
|
1142
|
(idbacteriaPopulation_bacteriaPopulation63_7, population_4, prePopulation_4)
|
1143
|
=
|
1144
|
if (( population_1 =32.0 )) then
|
1145
|
bacteriaPopulation_stable65_en(idbacteriaPopulation_bacteriaPopulation63_6, population_1, prePopulation_1, false)
|
1146
|
else (idbacteriaPopulation_bacteriaPopulation63_6, population_1, prePopulation_1);
|
1147
|
|
1148
|
|
1149
|
(idbacteriaPopulation_bacteriaPopulation63, population, prePopulation)
|
1150
|
=
|
1151
|
if (( population_1 <32.0 )) then
|
1152
|
(idbacteriaPopulation_bacteriaPopulation63_3, population_2, prePopulation_2)
|
1153
|
else
|
1154
|
if (( population_1 >32.0 )) then
|
1155
|
(idbacteriaPopulation_bacteriaPopulation63_5, population_3, prePopulation_3)
|
1156
|
else
|
1157
|
if (( population_1 =32.0 )) then
|
1158
|
(idbacteriaPopulation_bacteriaPopulation63_7, population_4, prePopulation_4)
|
1159
|
else (idbacteriaPopulation_bacteriaPopulation63_1, population_1, prePopulation_1);
|
1160
|
|
1161
|
|
1162
|
tel
|
1163
|
|
1164
|
until true restart POINTbacteriaPopulation_bacteriaPopulation63
|
1165
|
|
1166
|
|
1167
|
|
1168
|
state BACTERIAPOPULATION_START66__TO__BACTERIAPOPULATION_BACTERIAPOPULATION63JUNCTION79_1:
|
1169
|
|
1170
|
var idbacteriaPopulation_bacteriaPopulation63_2, idbacteriaPopulation_bacteriaPopulation63_3, idbacteriaPopulation_bacteriaPopulation63_4, idbacteriaPopulation_bacteriaPopulation63_5, idbacteriaPopulation_bacteriaPopulation63_6, idbacteriaPopulation_bacteriaPopulation63_7:int;
|
1171
|
population_2, population_3, population_4:real;
|
1172
|
prePopulation_2, prePopulation_3, prePopulation_4:real;
|
1173
|
let
|
1174
|
|
1175
|
|
1176
|
|
1177
|
-- transition trace :
|
1178
|
--bacteriaPopulation_start66__To__Junction79_1, Junction79__To__bacteriaPopulation_increasing64_1
|
1179
|
(idbacteriaPopulation_bacteriaPopulation63_2)
|
1180
|
=
|
1181
|
if (( population_1 <32.0 )) then
|
1182
|
bacteriaPopulation_start66_ex(idbacteriaPopulation_bacteriaPopulation63_1, false)
|
1183
|
else (idbacteriaPopulation_bacteriaPopulation63_1);
|
1184
|
|
1185
|
|
1186
|
(idbacteriaPopulation_bacteriaPopulation63_3, population_2, prePopulation_2)
|
1187
|
=
|
1188
|
if (( population_1 <32.0 )) then
|
1189
|
bacteriaPopulation_increasing64_en(idbacteriaPopulation_bacteriaPopulation63_2, population_1, prePopulation_1, false)
|
1190
|
else (idbacteriaPopulation_bacteriaPopulation63_2, population_1, prePopulation_1);
|
1191
|
|
1192
|
|
1193
|
|
1194
|
-- transition trace :
|
1195
|
--bacteriaPopulation_start66__To__Junction79_1, Junction79__To__bacteriaPopulation_decreasing67_2
|
1196
|
(idbacteriaPopulation_bacteriaPopulation63_4)
|
1197
|
=
|
1198
|
if (( population_1 >32.0 )) then
|
1199
|
bacteriaPopulation_start66_ex(idbacteriaPopulation_bacteriaPopulation63_1, false)
|
1200
|
else (idbacteriaPopulation_bacteriaPopulation63_1);
|
1201
|
|
1202
|
|
1203
|
(idbacteriaPopulation_bacteriaPopulation63_5, population_3, prePopulation_3)
|
1204
|
=
|
1205
|
if (( population_1 >32.0 )) then
|
1206
|
bacteriaPopulation_decreasing67_en(idbacteriaPopulation_bacteriaPopulation63_4, population_1, prePopulation_1, false)
|
1207
|
else (idbacteriaPopulation_bacteriaPopulation63_4, population_1, prePopulation_1);
|
1208
|
|
1209
|
|
1210
|
|
1211
|
-- transition trace :
|
1212
|
--bacteriaPopulation_start66__To__Junction79_1, Junction79__To__bacteriaPopulation_stable65_3
|
1213
|
(idbacteriaPopulation_bacteriaPopulation63_6)
|
1214
|
=
|
1215
|
if (( population_1 =32.0 )) then
|
1216
|
bacteriaPopulation_start66_ex(idbacteriaPopulation_bacteriaPopulation63_1, false)
|
1217
|
else (idbacteriaPopulation_bacteriaPopulation63_1);
|
1218
|
|
1219
|
|
1220
|
(idbacteriaPopulation_bacteriaPopulation63_7, population_4, prePopulation_4)
|
1221
|
=
|
1222
|
if (( population_1 =32.0 )) then
|
1223
|
bacteriaPopulation_stable65_en(idbacteriaPopulation_bacteriaPopulation63_6, population_1, prePopulation_1, false)
|
1224
|
else (idbacteriaPopulation_bacteriaPopulation63_6, population_1, prePopulation_1);
|
1225
|
|
1226
|
|
1227
|
(idbacteriaPopulation_bacteriaPopulation63, population, prePopulation)
|
1228
|
=
|
1229
|
if (( population_1 <32.0 )) then
|
1230
|
(idbacteriaPopulation_bacteriaPopulation63_3, population_2, prePopulation_2)
|
1231
|
else
|
1232
|
if (( population_1 >32.0 )) then
|
1233
|
(idbacteriaPopulation_bacteriaPopulation63_5, population_3, prePopulation_3)
|
1234
|
else
|
1235
|
if (( population_1 =32.0 )) then
|
1236
|
(idbacteriaPopulation_bacteriaPopulation63_7, population_4, prePopulation_4)
|
1237
|
else (idbacteriaPopulation_bacteriaPopulation63_1, population_1, prePopulation_1);
|
1238
|
|
1239
|
|
1240
|
tel
|
1241
|
|
1242
|
until true restart POINTbacteriaPopulation_bacteriaPopulation63
|
1243
|
|
1244
|
|
1245
|
|
1246
|
state BACTERIAPOPULATION_DECREASING67__TO__BACTERIAPOPULATION_BACTERIAPOPULATION63JUNCTION79_1:
|
1247
|
|
1248
|
var idbacteriaPopulation_bacteriaPopulation63_2, idbacteriaPopulation_bacteriaPopulation63_3, idbacteriaPopulation_bacteriaPopulation63_4, idbacteriaPopulation_bacteriaPopulation63_5, idbacteriaPopulation_bacteriaPopulation63_6, idbacteriaPopulation_bacteriaPopulation63_7:int;
|
1249
|
population_2, population_3, population_4:real;
|
1250
|
prePopulation_2, prePopulation_3, prePopulation_4:real;
|
1251
|
let
|
1252
|
|
1253
|
|
1254
|
|
1255
|
-- transition trace :
|
1256
|
--bacteriaPopulation_decreasing67__To__Junction79_1, Junction79__To__bacteriaPopulation_increasing64_1
|
1257
|
(idbacteriaPopulation_bacteriaPopulation63_2)
|
1258
|
=
|
1259
|
if (( population_1 <32.0 )) then
|
1260
|
bacteriaPopulation_decreasing67_ex(idbacteriaPopulation_bacteriaPopulation63_1, false)
|
1261
|
else (idbacteriaPopulation_bacteriaPopulation63_1);
|
1262
|
|
1263
|
|
1264
|
(idbacteriaPopulation_bacteriaPopulation63_3, population_2, prePopulation_2)
|
1265
|
=
|
1266
|
if (( population_1 <32.0 )) then
|
1267
|
bacteriaPopulation_increasing64_en(idbacteriaPopulation_bacteriaPopulation63_2, population_1, prePopulation_1, false)
|
1268
|
else (idbacteriaPopulation_bacteriaPopulation63_2, population_1, prePopulation_1);
|
1269
|
|
1270
|
|
1271
|
|
1272
|
-- transition trace :
|
1273
|
--bacteriaPopulation_decreasing67__To__Junction79_1, Junction79__To__bacteriaPopulation_decreasing67_2
|
1274
|
(idbacteriaPopulation_bacteriaPopulation63_4)
|
1275
|
=
|
1276
|
if (( population_1 >32.0 )) then
|
1277
|
bacteriaPopulation_decreasing67_ex(idbacteriaPopulation_bacteriaPopulation63_1, false)
|
1278
|
else (idbacteriaPopulation_bacteriaPopulation63_1);
|
1279
|
|
1280
|
|
1281
|
(idbacteriaPopulation_bacteriaPopulation63_5, population_3, prePopulation_3)
|
1282
|
=
|
1283
|
if (( population_1 >32.0 )) then
|
1284
|
bacteriaPopulation_decreasing67_en(idbacteriaPopulation_bacteriaPopulation63_4, population_1, prePopulation_1, false)
|
1285
|
else (idbacteriaPopulation_bacteriaPopulation63_4, population_1, prePopulation_1);
|
1286
|
|
1287
|
|
1288
|
|
1289
|
-- transition trace :
|
1290
|
--bacteriaPopulation_decreasing67__To__Junction79_1, Junction79__To__bacteriaPopulation_stable65_3
|
1291
|
(idbacteriaPopulation_bacteriaPopulation63_6)
|
1292
|
=
|
1293
|
if (( population_1 =32.0 )) then
|
1294
|
bacteriaPopulation_decreasing67_ex(idbacteriaPopulation_bacteriaPopulation63_1, false)
|
1295
|
else (idbacteriaPopulation_bacteriaPopulation63_1);
|
1296
|
|
1297
|
|
1298
|
(idbacteriaPopulation_bacteriaPopulation63_7, population_4, prePopulation_4)
|
1299
|
=
|
1300
|
if (( population_1 =32.0 )) then
|
1301
|
bacteriaPopulation_stable65_en(idbacteriaPopulation_bacteriaPopulation63_6, population_1, prePopulation_1, false)
|
1302
|
else (idbacteriaPopulation_bacteriaPopulation63_6, population_1, prePopulation_1);
|
1303
|
|
1304
|
|
1305
|
(idbacteriaPopulation_bacteriaPopulation63, population, prePopulation)
|
1306
|
=
|
1307
|
if (( population_1 <32.0 )) then
|
1308
|
(idbacteriaPopulation_bacteriaPopulation63_3, population_2, prePopulation_2)
|
1309
|
else
|
1310
|
if (( population_1 >32.0 )) then
|
1311
|
(idbacteriaPopulation_bacteriaPopulation63_5, population_3, prePopulation_3)
|
1312
|
else
|
1313
|
if (( population_1 =32.0 )) then
|
1314
|
(idbacteriaPopulation_bacteriaPopulation63_7, population_4, prePopulation_4)
|
1315
|
else (idbacteriaPopulation_bacteriaPopulation63_1, population_1, prePopulation_1);
|
1316
|
|
1317
|
|
1318
|
tel
|
1319
|
|
1320
|
until true restart POINTbacteriaPopulation_bacteriaPopulation63
|
1321
|
|
1322
|
|
1323
|
|
1324
|
state BACTERIAPOPULATION_INCREASING64_IDL:
|
1325
|
|
1326
|
let
|
1327
|
|
1328
|
|
1329
|
|
1330
|
(idbacteriaPopulation_bacteriaPopulation63, population, prePopulation)
|
1331
|
= (idbacteriaPopulation_bacteriaPopulation63_1, population_1, prePopulation_1);
|
1332
|
|
1333
|
|
1334
|
tel
|
1335
|
|
1336
|
until true restart POINTbacteriaPopulation_bacteriaPopulation63
|
1337
|
|
1338
|
|
1339
|
|
1340
|
state BACTERIAPOPULATION_STABLE65_IDL:
|
1341
|
|
1342
|
let
|
1343
|
|
1344
|
|
1345
|
|
1346
|
(idbacteriaPopulation_bacteriaPopulation63, population, prePopulation)
|
1347
|
= (idbacteriaPopulation_bacteriaPopulation63_1, population_1, prePopulation_1);
|
1348
|
|
1349
|
|
1350
|
tel
|
1351
|
|
1352
|
until true restart POINTbacteriaPopulation_bacteriaPopulation63
|
1353
|
|
1354
|
|
1355
|
|
1356
|
state BACTERIAPOPULATION_START66_IDL:
|
1357
|
|
1358
|
let
|
1359
|
|
1360
|
|
1361
|
|
1362
|
(idbacteriaPopulation_bacteriaPopulation63, population, prePopulation)
|
1363
|
= (idbacteriaPopulation_bacteriaPopulation63_1, population_1, prePopulation_1);
|
1364
|
|
1365
|
|
1366
|
tel
|
1367
|
|
1368
|
until true restart POINTbacteriaPopulation_bacteriaPopulation63
|
1369
|
|
1370
|
|
1371
|
|
1372
|
state BACTERIAPOPULATION_DECREASING67_IDL:
|
1373
|
|
1374
|
let
|
1375
|
|
1376
|
|
1377
|
|
1378
|
(idbacteriaPopulation_bacteriaPopulation63, population, prePopulation)
|
1379
|
= (idbacteriaPopulation_bacteriaPopulation63_1, population_1, prePopulation_1);
|
1380
|
|
1381
|
|
1382
|
tel
|
1383
|
|
1384
|
until true restart POINTbacteriaPopulation_bacteriaPopulation63
|
1385
|
|
1386
|
|
1387
|
|
1388
|
tel
|
1389
|
|
1390
|
|
1391
|
--***************************************************State :bacteriaPopulation_bacteriaPopulation63 Automaton***************************************************
|
1392
|
|
1393
|
node bacteriaPopulationStateflow_PP_bacteriaPopulation_bacteriaPopulation_bacteriaPopulation(population0:real)
|
1394
|
|
1395
|
returns (population:real);
|
1396
|
|
1397
|
|
1398
|
var population_1: real;
|
1399
|
|
1400
|
prePopulation, prePopulation_1: real;
|
1401
|
|
1402
|
dummyEvent, dummyEvent_1: bool;
|
1403
|
|
1404
|
idbacteriaPopulation_bacteriaPopulation63, idbacteriaPopulation_bacteriaPopulation63_1: int;
|
1405
|
|
1406
|
let
|
1407
|
|
1408
|
population_1 = 0.0 -> pre population;
|
1409
|
|
1410
|
prePopulation_1 = 0.0 -> pre prePopulation;
|
1411
|
|
1412
|
dummyEvent_1 = false -> pre dummyEvent;
|
1413
|
|
1414
|
idbacteriaPopulation_bacteriaPopulation63_1 = 0 -> pre idbacteriaPopulation_bacteriaPopulation63;
|
1415
|
|
1416
|
|
1417
|
|
1418
|
|
1419
|
|
1420
|
(idbacteriaPopulation_bacteriaPopulation63, population, prePopulation)
|
1421
|
= bacteriaPopulation_bacteriaPopulation63_node(idbacteriaPopulation_bacteriaPopulation63_1, population_1, population0, prePopulation_1);
|
1422
|
|
1423
|
|
1424
|
--unused outputs
|
1425
|
dummyEvent = false;
|
1426
|
|
1427
|
|
1428
|
|
1429
|
tel
|
1430
|
|
1431
|
|
1432
|
|
1433
|
|
1434
|
|
1435
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulation/bacteriaPopulation
|
1436
|
node bacteriaPopulation_397_000 (In1_1: real;
|
1437
|
__time_step:real;)
|
1438
|
returns (Out1_1: real;);
|
1439
|
|
1440
|
var bacteriaPopulation_1: real;
|
1441
|
let
|
1442
|
(bacteriaPopulation_1) = bacteriaPopulationStateflow_PP_bacteriaPopulation_bacteriaPopulation_bacteriaPopulation(In1_1);
|
1443
|
Out1_1 = bacteriaPopulation_1;
|
1444
|
|
1445
|
tel
|
1446
|
|
1447
|
|
1448
|
-- Original block name: bacteriaPopulationStateflow_PP/bacteriaPopulation
|
1449
|
node bacteriaPopulation_3513_001 (In1_1: real;
|
1450
|
__time_step:real;)
|
1451
|
returns (Out1_1: real;);
|
1452
|
(*@contract
|
1453
|
import bacteriaPopulationSpec_412_000( In1_1, __time_step ) returns (Out1_1);
|
1454
|
*)
|
1455
|
var bacteriaPopulation_1: real;
|
1456
|
let
|
1457
|
(bacteriaPopulation_1) = bacteriaPopulation_397_000(In1_1,
|
1458
|
__time_step);
|
1459
|
Out1_1 = bacteriaPopulation_1;
|
1460
|
|
1461
|
tel
|
1462
|
|
1463
|
|
1464
|
-- Original block name: bacteriaPopulationStateflow_PP
|
1465
|
node bacteriaPopulationStateflow_PP (population0_1: real;)
|
1466
|
returns (population_1: real;);
|
1467
|
|
1468
|
var bacteriaPopulation_1: real;
|
1469
|
__time_step:real;
|
1470
|
let
|
1471
|
__time_step = 0.0 -> pre __time_step + 1.000000000000000;
|
1472
|
(bacteriaPopulation_1) = bacteriaPopulation_3513_001(population0_1,
|
1473
|
__time_step);
|
1474
|
population_1 = bacteriaPopulation_1;
|
1475
|
|
1476
|
tel
|