Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Exclude max from range for xbt::random::uniform_real.
[simgrid.git] / include / xbt / random.hpp
index 3386f1dd2e36a2c555688ff4927248c711d8d383..c55ba8b7132cde81b035c9fc70ef2d770f96115c 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2019. The SimGrid Team. All rights reserved.               */
+/* Copyright (c) 2019-2020. 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. */
@@ -14,35 +14,40 @@ namespace random {
  * @brief Tells xbt/random to use the ad-hoc distribution implementation.
  */
 void set_implem_xbt();
+
 /**
  * @brief Tells xbt/random to use the standard library distribution implementation.
  */
 void set_implem_std();
+
 /**
  * @brief Sets the seed of the Mersenne-Twister RNG
  */
 void set_mersenne_seed(int);
 
 /**
- * @brief Draws an integer number uniformly between min and max included
+ * @brief Draws an integer number uniformly in range [min, max] (min and max included)
  *
  * @param min Minimum value
  * @param max Maximum value
  */
 int uniform_int(int min, int max);
+
 /**
- * @brief Draws a real number uniformly between min and max included
+ * @brief Draws a real number uniformly in range [min, max) (min included, and max excluded)
  *
  * @param min Minimum value
  * @param max Maximum value
  */
 double uniform_real(double min, double max);
+
 /**
  * @brief Draws a real number according to the given exponential distribution
  *
  * @param lambda Parameter of the exponential law
  */
 double exponential(double lambda);
+
 /**
  * @brief Draws a real number according to the given normal distribution
  *