Project

General

Profile

Statistics
| Branch: | Tag: | Revision:

lustrec-tests / regression_tests / lustre_files / success / Simulink / src_minmax_test / minmax_test.lus @ 6c3ea955

History | View | Annotate | Download (3.31 KB)

1
-- This file has been generated by cocoSim
2

    
3

    
4
-- System nodes
5
node minmax_test (In1_1_1 : real; In2_1_1 : real; In3_1_1 : real; In3_1_2 : real; In4_1_1 : real; In4_1_2 : real; In5_1_1 : real; In5_1_2 : real; In5_1_3 : real; In5_1_4 : real; In6_1_1 : real; In6_1_2 : real; In6_1_3 : real; In6_1_4 : real; In7_1_1 : real; In7_1_2 : real; In7_1_3 : real; In8_1_1 : real; In8_1_2 : real; In8_1_3 : real; In8_1_4 : real; In8_1_5 : real; In8_1_6 : real; In8_1_7 : real)
6
returns (Out1_1_1 : real;
7
	Out2_2_1 : real;
8
	Out3_3_1 : real; Out3_3_2 : real;
9
	Out4_4_1 : real; Out4_4_2 : real;
10
	Out5_5_1 : real; Out5_5_2 : real; Out5_5_3 : real; Out5_5_4 : real;
11
	Out6_6_1 : real; Out6_6_2 : real; Out6_6_3 : real; Out6_6_4 : real;
12
	Out7_7_1 : real;
13
	Out8_8_1 : real); 
14
var
15
	max_block_1_1 : real;
16
	max_block1_1_1 : real; max_block1_1_2 : real;
17
	max_block2_1_1 : real; max_block2_1_2 : real; max_block2_1_3 : real; max_block2_1_4 : real;
18
	min_block_1_1 : real;
19
	min_block1_1_1 : real; min_block1_1_2 : real;
20
	min_block2_1_1 : real; min_block2_1_2 : real; min_block2_1_3 : real; min_block2_1_4 : real;
21
	min_block3_1_1 : real;
22
	min_block4_1_1 : real;
23
	i_virtual_local : real;
24
	min_block3_tmp_1 : real; 
25
	min_block4_tmp_1 : real; min_block4_tmp_2 : real; min_block4_tmp_3 : real; min_block4_tmp_4 : real; min_block4_tmp_5 : real; 
26
let 
27
	max_block_1_1 = if In1_1_1 >= In2_1_1 then In1_1_1 else In2_1_1;
28
	max_block1_1_1 = if In3_1_1 >= In4_1_1 then In3_1_1 else In4_1_1;
29
	max_block1_1_2 = if In3_1_2 >= In4_1_2 then In3_1_2 else In4_1_2;
30
	max_block2_1_1 = if In5_1_1 >= In6_1_1 then In5_1_1 else In6_1_1;
31
	max_block2_1_2 = if In5_1_2 >= In6_1_2 then In5_1_2 else In6_1_2;
32
	max_block2_1_3 = if In5_1_3 >= In6_1_3 then In5_1_3 else In6_1_3;
33
	max_block2_1_4 = if In5_1_4 >= In6_1_4 then In5_1_4 else In6_1_4;
34
	min_block_1_1 = if In1_1_1 <= In2_1_1 then In1_1_1 else In2_1_1;
35
	min_block1_1_1 = if In3_1_1 <= In4_1_1 then In3_1_1 else In4_1_1;
36
	min_block1_1_2 = if In3_1_2 <= In4_1_2 then In3_1_2 else In4_1_2;
37
	min_block2_1_1 = if In5_1_1 <= In6_1_1 then In5_1_1 else In6_1_1;
38
	min_block2_1_2 = if In5_1_2 <= In6_1_2 then In5_1_2 else In6_1_2;
39
	min_block2_1_3 = if In5_1_3 <= In6_1_3 then In5_1_3 else In6_1_3;
40
	min_block2_1_4 = if In5_1_4 <= In6_1_4 then In5_1_4 else In6_1_4;
41
	min_block3_tmp_1 = if In7_1_1 <= In7_1_2 then In7_1_1 else In7_1_2;
42
	min_block3_1_1 = if min_block3_tmp_1 <= In7_1_3 then min_block3_tmp_1 else In7_1_3;
43
	min_block4_tmp_1 = if In8_1_1 >= In8_1_2 then In8_1_1 else In8_1_2;
44
	min_block4_tmp_2 = if min_block4_tmp_1 >= In8_1_3 then min_block4_tmp_1 else In8_1_3;
45
	min_block4_tmp_3 = if min_block4_tmp_2 >= In8_1_4 then min_block4_tmp_2 else In8_1_4;
46
	min_block4_tmp_4 = if min_block4_tmp_3 >= In8_1_5 then min_block4_tmp_3 else In8_1_5;
47
	min_block4_tmp_5 = if min_block4_tmp_4 >= In8_1_6 then min_block4_tmp_4 else In8_1_6;
48
	min_block4_1_1 = if min_block4_tmp_5 >= In8_1_7 then min_block4_tmp_5 else In8_1_7;
49
	Out1_1_1 = min_block_1_1;
50
	Out2_2_1 = max_block_1_1;
51
	Out3_3_1 = min_block1_1_1;
52
	Out3_3_2 = min_block1_1_2;
53
	Out4_4_1 = max_block1_1_1;
54
	Out4_4_2 = max_block1_1_2;
55
	Out5_5_1 = min_block2_1_1;
56
	Out5_5_2 = min_block2_1_2;
57
	Out5_5_3 = min_block2_1_3;
58
	Out5_5_4 = min_block2_1_4;
59
	Out6_6_1 = max_block2_1_1;
60
	Out6_6_2 = max_block2_1_2;
61
	Out6_6_3 = max_block2_1_3;
62
	Out6_6_4 = max_block2_1_4;
63
	Out7_7_1 = min_block3_1_1;
64
	Out8_8_1 = min_block4_1_1;
65
	i_virtual_local= 0.0 -> 1.0;
66
tel
67