Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Random number in Uppaal

How can I create a random number when I define a global declaration in an Uppaal program?

I want to have a variable that contains a random number as in a C program:

int x = rand (100);
like image 759
user2791940 Avatar asked Oct 22 '13 15:10

user2791940


1 Answers

According to folks at Uppaal mailing list , this code snippet select: i : int[0,3]

will non-deterministically bind i to an integer in the range 0 to 3.

So, in Your case just use select: x : int[0, 100].

like image 185
Kamiccolo Avatar answered Jan 03 '23 22:01

Kamiccolo