23 TEST_CASE(
"StdRandom mt19937 determinism",
"[utilities]")
28 std::vector<double> expected = {0.7777024102, 0.6073413305, 0.237541216};
29 for (
auto i = 0; i < expected.size(); ++i)
30 CHECK(our_rng() == Approx(expected[i]));
40 std::vector<double> rng_doubles(100,0.0);
41 for(
auto& elem : rng_doubles)
44 std::vector<DoubleRNG::uint_type> state;
48 CHECK(state.size() == rng.state_size());
54 CHECK(rng2() == rng());
63 std::vector<double> rng_doubles(100, 0.0);
64 for (
auto& elem : rng_doubles)
67 std::vector<DoubleRNG::uint_type> state1;
70 std::stringstream stream1;
73 auto rng2 = rng.makeClone();
74 std::vector<DoubleRNG::uint_type> state2;
77 CHECK(state1.size() == state2.size());
78 CHECK(state1 == state2);
80 std::stringstream stream2;
83 CHECK(stream1.str() == stream2.str());
85 CHECK((*rng2)() == rng());
86 CHECK((*rng2)() == rng());
helper functions for EinsplineSetBuilder
TEST_CASE("complex_helper", "[type_traits]")
A minimally functional wrapper for the since c++11 <random>
void init(int iseed_in) override
CHECK(log_values[0]==ComplexApprox(std::complex< double >{ 5.603777579195571, -6.1586603331188225 }))