From 2df92ef8b677d1f4f3eb39148efac27090a4b2d9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Nathan=20R=C3=A9biscoul?= <nathan.rebiscoul38@gmail.com>
Date: Thu, 4 Jul 2019 13:37:52 +0200
Subject: [PATCH] forgot a file

---
 test/lustre/round.lus | 62 +++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 62 insertions(+)

diff --git a/test/lustre/round.lus b/test/lustre/round.lus
index 9f32e43b..94dfbc6b 100644
--- a/test/lustre/round.lus
+++ b/test/lustre/round.lus
@@ -68,3 +68,65 @@ let
   cpt = 0 -> pre cpt + 1;
   res = cpt <= n or x;
 tel
+
+-----------------------------------------------------------------------------
+-----------------------------------------------------------------------------
+node bool_to_int(X:int; Y:bool) returns (Z:int);
+let
+  Z = if(Y) then X+1 else X;
+tel
+
+-----------------------------------------------------------------------------
+node map_and (X,Y:bool^m) returns (Z:bool^m);
+let
+  Z = map<<and,m>>(X,Y) ;
+tel 
+
+-----------------------------------------------------------------------------
+node implies_list(A,B:bool^m) returns (res:bool^m);
+let
+  res = map<<=>,m>>(A,B) ;
+tel
+
+-----------------------------------------------------------------------------
+node add_int_true(X:int; Y:bool^m) returns (Z:int);
+let
+  Z = red<<bool_to_int,m>>(X,Y);
+tel
+
+-----------------------------------------------------------------------------
+node one_true (tab:bool^m^n) returns (res:bool);
+let
+  res = (((red<<add_int_true,n>>(0,tab)))=1);
+tel
+
+-----------------------------------------------------------------------------
+node all_true (tab_acti:bool^m^n) returns (res:bool);
+let
+  res = boolred<<m,m,m>>((red<<map_and,n>>(true^m,tab_acti))) ;
+tel
+
+-----------------------------------------------------------------------------
+node compt_move (tab_acti:bool^m^n) returns (nb_act:int);
+let
+  nb_act = 0 -> pre(nb_act) + (red<<add_int_true,n>>(0,tab_acti));    
+tel
+
+-----------------------------------------------------------------------------
+node is_distributed(acti,enab:bool^m^n) returns (res:bool);
+let
+  res = true ->  (((red<<add_int_true,n>>(0,acti))>=1) or silent<<m,n>>(enab)) and pre(res);
+tel
+
+-----------------------------------------------------------------------------
+node is_central(acti:bool^m^n) returns (res:bool);
+let
+  res = true ->  (one_true(acti)) and pre(res);
+tel
+
+-----------------------------------------------------------------------------
+node is_synchronous(enab,acti:bool^m^n) returns (res:bool);
+let
+  res = true -> all_true(map<<implies_list,n>>(enab,acti)) and pre(res);
+tel
+
-- 
GitLab