A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Get rid of all these nasty _im_.
[simgrid.git]
/
src
/
include
/
surf
/
random_mgr.h
diff --git
a/src/include/surf/random_mgr.h
b/src/include/surf/random_mgr.h
index
d02ec3d
..
55ff757
100644
(file)
--- a/
src/include/surf/random_mgr.h
+++ b/
src/include/surf/random_mgr.h
@@
-1,3
+1,9
@@
+/* Copyright (c) 2007, 2008, 2009, 2010. The SimGrid Team.
+ * All rights reserved. */
+
+/* This program is free software; you can redistribute it and/or modify it
+ * under the terms of the license (GNU LGPL) which comes with this package. */
+
#ifndef _SURF_RMGR_H
#define _SURF_RMGR_H
#ifndef _SURF_RMGR_H
#define _SURF_RMGR_H
@@
-5,22
+11,24
@@
#include "xbt/dict.h"
#include <stdlib.h>
#include <math.h>
#include "xbt/dict.h"
#include <stdlib.h>
#include <math.h>
-#include <stdio.h>
SG_BEGIN_DECL()
SG_BEGIN_DECL()
-typedef enum {
NONE, DRAND48, RAND
} Generator;
+typedef enum {
NONE, DRAND48, RAND, RNGSTREAM
} Generator;
typedef struct random_data_desc {
typedef struct random_data_desc {
- double max, min, mean, stdDeviation;
+ long int seed;
+ double max, min;
+ double mean, std; /* note: mean and standard deviation are normalized */
Generator generator;
} s_random_data_t, *random_data_t;
XBT_PUBLIC_DATA(xbt_dict_t) random_data_list;
XBT_PUBLIC(double) random_generate(random_data_t random);
Generator generator;
} s_random_data_t, *random_data_t;
XBT_PUBLIC_DATA(xbt_dict_t) random_data_list;
XBT_PUBLIC(double) random_generate(random_data_t random);
-XBT_PUBLIC(random_data_t) random_new(Generator generator, double min, double max, double mean, double stdDeviation);
+XBT_PUBLIC(random_data_t) random_new(Generator generator, long int seed,
+ double min, double max, double mean,
+ double stdDeviation);
SG_END_DECL()
SG_END_DECL()
-
-#endif /* _SURF_RMGR_H */
+#endif /* _SURF_RMGR_H */