2023-11-17 21:57:28 +01:00
|
|
|
#include <stdlib.h>
|
2023-11-17 22:39:39 +01:00
|
|
|
#include "la_random.h"
|
2023-11-17 21:57:28 +01:00
|
|
|
|
|
|
|
namespace LA {
|
|
|
|
|
|
|
|
WEAK_SYMBOL double randdouble() {return random()/(1.+RAND_MAX);}
|
|
|
|
WEAK_SYMBOL double randdoublesigned() {return 2.*random()/(1.+RAND_MAX)-1.;}
|
|
|
|
WEAK_SYMBOL int randint32() {return random();}
|
2023-12-27 23:24:13 +01:00
|
|
|
WEAK_SYMBOL uint64_t randint64() {uint64_t r = random(); r<<=32; r|= random(); return r; }
|
2023-11-17 21:57:28 +01:00
|
|
|
}//namespace
|
|
|
|
|