Project

General

Profile

Download (5.11 KB) Statistics
| Branch: | Tag: | Revision:
1
-- This file has been generated by CoCoSim2.
2

    
3
-- Compiler: Lustre compiler 2 (ToLustre.m)
4
-- Time: 03-Dec-2018 22:44:43
5
node  int_to_bool(x : int;)
6
returns(y : bool;);
7
let
8
	y = (x <> 0);
9
tel
10

    
11
node  real_to_bool(x : real;)
12
returns(y : bool;);
13
let
14
	y = (x <> 0.0);
15
tel
16

    
17
(*
18
Original block name: Logical
19
*)
20
node  Logical(In4_1 : real;
21
	In4_2 : real;
22
	In4_3 : real;
23
	In1_1 : int;
24
	In1_2 : int;
25
	In1_3 : int;
26
	In2_1 : real;
27
	In2_2 : real;
28
	In2_3 : real;
29
	In3_1 : real;
30
	In3_2 : real;
31
	In3_3 : real;
32
	In5_1 : real;
33
	In5_2 : real;
34
	In5_3 : real;
35
	In6_1 : real;
36
	In6_2 : real;
37
	In6_3 : real;
38
	In7_1 : real;
39
	In7_2 : real;
40
	In7_3 : real;
41
	In8_1 : real;
42
	In8_2 : real;
43
	In8_3 : real;
44
	In9_1 : real;
45
	In9_2 : real;
46
	In9_3 : real;
47
	In10_1 : real;
48
	In10_2 : real;
49
	In10_3 : real;
50
	In11_1 : real;
51
	In11_2 : real;
52
	In11_3 : real;
53
	In12_1 : real;
54
	In12_2 : real;
55
	In12_3 : real;
56
	In13_1 : real;
57
	In13_2 : real;
58
	In13_3 : real;
59
	In14_1 : real;
60
	In15_1 : int;
61
	In15_2 : int;
62
	In15_3 : int;
63
	In16_1 : real;
64
	In17_1 : int;
65
	In17_2 : int;
66
	In17_3 : int;
67
	In18_1 : int;
68
	In18_2 : int;
69
	In18_3 : int;)
70
returns(Out2_1 : bool;
71
	Out2_2 : bool;
72
	Out2_3 : bool;
73
	Out1_1 : bool;
74
	Out1_2 : bool;
75
	Out1_3 : bool;
76
	Out3_1 : bool;
77
	Out3_2 : bool;
78
	Out3_3 : bool;
79
	Out4_1 : bool;
80
	Out4_2 : bool;
81
	Out4_3 : bool;
82
	Out5_1 : bool;
83
	Out5_2 : bool;
84
	Out5_3 : bool;
85
	Out6_1 : bool;
86
	Out6_2 : bool;
87
	Out6_3 : bool;
88
	Out7_1 : bool;
89
	Out7_2 : bool;
90
	Out7_3 : bool;
91
	Out8_1 : bool;
92
	Out8_2 : bool;
93
	Out8_3 : bool;
94
	Out9_1 : bool;
95
	Out9_2 : bool;
96
	Out9_3 : bool;);
97
var LogicalOperator1_1 : bool;
98
	LogicalOperator1_2 : bool;
99
	LogicalOperator1_3 : bool;
100
	LogicalOperator2_1 : bool;
101
	LogicalOperator2_2 : bool;
102
	LogicalOperator2_3 : bool;
103
	LogicalOperator3_1 : bool;
104
	LogicalOperator3_2 : bool;
105
	LogicalOperator3_3 : bool;
106
	LogicalOperator4_1 : bool;
107
	LogicalOperator4_2 : bool;
108
	LogicalOperator4_3 : bool;
109
	LogicalOperator5_1 : bool;
110
	LogicalOperator5_2 : bool;
111
	LogicalOperator5_3 : bool;
112
	LogicalOperator6_1 : bool;
113
	LogicalOperator6_2 : bool;
114
	LogicalOperator6_3 : bool;
115
	LogicalOperator7_1 : bool;
116
	LogicalOperator7_2 : bool;
117
	LogicalOperator7_3 : bool;
118
	LogicalOperator8_1 : bool;
119
	LogicalOperator8_2 : bool;
120
	LogicalOperator8_3 : bool;
121
	LogicalOperator9_1 : bool;
122
	LogicalOperator9_2 : bool;
123
	LogicalOperator9_3 : bool;
124
	__time_step : real;
125
	__nb_step : int;
126
let
127
	LogicalOperator1_1 = ( real_to_bool(In4_1) and int_to_bool(In1_1) );
128
	LogicalOperator1_2 = ( real_to_bool(In4_2) and int_to_bool(In1_2) );
129
	LogicalOperator1_3 = ( real_to_bool(In4_3) and int_to_bool(In1_3) );
130
	LogicalOperator2_1 = ( real_to_bool(In2_1) or real_to_bool(In3_1) );
131
	LogicalOperator2_2 = ( real_to_bool(In2_2) or real_to_bool(In3_2) );
132
	LogicalOperator2_3 = ( real_to_bool(In2_3) or real_to_bool(In3_3) );
133
	LogicalOperator3_1 = (not ( real_to_bool(In5_1) and real_to_bool(In6_1) ));
134
	LogicalOperator3_2 = (not ( real_to_bool(In5_2) and real_to_bool(In6_2) ));
135
	LogicalOperator3_3 = (not ( real_to_bool(In5_3) and real_to_bool(In6_3) ));
136
	LogicalOperator4_1 = (not ( real_to_bool(In7_1) or real_to_bool(In8_1) ));
137
	LogicalOperator4_2 = (not ( real_to_bool(In7_2) or real_to_bool(In8_2) ));
138
	LogicalOperator4_3 = (not ( real_to_bool(In7_3) or real_to_bool(In8_3) ));
139
	LogicalOperator5_1 = ( real_to_bool(In9_1) xor real_to_bool(In10_1) );
140
	LogicalOperator5_2 = ( real_to_bool(In9_2) xor real_to_bool(In10_2) );
141
	LogicalOperator5_3 = ( real_to_bool(In9_3) xor real_to_bool(In10_3) );
142
	LogicalOperator6_1 = (not ( real_to_bool(In11_1) xor real_to_bool(In12_1) ));
143
	LogicalOperator6_2 = (not ( real_to_bool(In11_2) xor real_to_bool(In12_2) ));
144
	LogicalOperator6_3 = (not ( real_to_bool(In11_3) xor real_to_bool(In12_3) ));
145
	LogicalOperator7_1 = (not real_to_bool(In13_1));
146
	LogicalOperator7_2 = (not real_to_bool(In13_2));
147
	LogicalOperator7_3 = (not real_to_bool(In13_3));
148
	LogicalOperator8_1 = ( real_to_bool(In14_1) and int_to_bool(In15_1) );
149
	LogicalOperator8_2 = ( real_to_bool(In14_1) and int_to_bool(In15_2) );
150
	LogicalOperator8_3 = ( real_to_bool(In14_1) and int_to_bool(In15_3) );
151
	LogicalOperator9_1 = ( real_to_bool(In16_1) and int_to_bool(In17_1) and int_to_bool(In18_1) );
152
	LogicalOperator9_2 = ( real_to_bool(In16_1) and int_to_bool(In17_2) and int_to_bool(In18_2) );
153
	LogicalOperator9_3 = ( real_to_bool(In16_1) and int_to_bool(In17_3) and int_to_bool(In18_3) );
154
	Out2_1 = LogicalOperator1_1;
155
	Out2_2 = LogicalOperator1_2;
156
	Out2_3 = LogicalOperator1_3;
157
	Out1_1 = LogicalOperator2_1;
158
	Out1_2 = LogicalOperator2_2;
159
	Out1_3 = LogicalOperator2_3;
160
	Out3_1 = LogicalOperator3_1;
161
	Out3_2 = LogicalOperator3_2;
162
	Out3_3 = LogicalOperator3_3;
163
	Out4_1 = LogicalOperator4_1;
164
	Out4_2 = LogicalOperator4_2;
165
	Out4_3 = LogicalOperator4_3;
166
	Out5_1 = LogicalOperator5_1;
167
	Out5_2 = LogicalOperator5_2;
168
	Out5_3 = LogicalOperator5_3;
169
	Out6_1 = LogicalOperator6_1;
170
	Out6_2 = LogicalOperator6_2;
171
	Out6_3 = LogicalOperator6_3;
172
	Out7_1 = LogicalOperator7_1;
173
	Out7_2 = LogicalOperator7_2;
174
	Out7_3 = LogicalOperator7_3;
175
	Out8_1 = LogicalOperator8_1;
176
	Out8_2 = LogicalOperator8_2;
177
	Out8_3 = LogicalOperator8_3;
178
	Out9_1 = LogicalOperator9_1;
179
	Out9_2 = LogicalOperator9_2;
180
	Out9_3 = LogicalOperator9_3;
181
	__time_step = (0.0 -> ((pre __time_step) + 0.200000000000000));
182
	__nb_step = (0 -> ((pre __nb_step) + 1));
183
tel
184

    
(805-805/1153)