Function navtk::experimental::set_global_rng(not_null<std::shared_ptr<RandomNumberGenerator>>)

Function Documentation

void navtk::experimental::set_global_rng(not_null<std::shared_ptr<RandomNumberGenerator>> randomness)

Replace the current global random number generator.

This method allows you to choose a different algorithm for navtk’s default random number generator, used by the global rand() and rand_n() functions when their randomness parameter is not supplied.

To change the seed, rather than the algorithm, of the current global random number generator, use s_rand() instead.

Parameters

randomness – Your desired RandomNumberGenerator instance.