Skip to content

Decouple random number generators from random number distributions

As we discussed at the last meeting, it is probably not a good idea to have the RandomNumbersSvc care about random number distributions. Instead, we should follow in the footsteps of the C++11 and decouple the notion of a random number generator from that of a random number distribution, with the following separation of concerns:

  • An algorithm execution (call to Algorithm::execute()) should spawn a single random number generator, if needed, reuse it for all of its random number generation needs, and pass it down to any other entity which needs random numbers (such as Tools).
  • Individual code which uses random numbers should spawn an STL-like random number distribution object and use it with the above Alg-local generator as a source of randomness.

This merge request attempts to implement this design. What do you think about it? In particular, I'm not too sure about the design of the new LandauDist, additional input would be really appreciated here.

Fixes ACTSFW-37.

Edited by Hadrien Benjamin Grasland

Merge request reports