cppyabm  1.0.17
An agent-based library to integrate C++ and Python
tools.h
Go to the documentation of this file.
1 
2 #pragma once
3 #include <iostream>
4 #include <iomanip>
5 #include <string>
6 #include <map>
7 #include <random>
8 #include <cmath>
9 #include <algorithm>
10 //! Tools commonly used in CppyABM
11 namespace tools{
12  //! Generate random numbers
13  auto randomly_seeded_MT () ;
14 }
15 
16 inline auto tools::randomly_seeded_MT () {
17  std::vector<unsigned int> random_data(624);
18  std::random_device source;
19  std::generate(begin(random_data), end(random_data), [&](){return source();});
20  std::seed_seq seeds(begin(random_data), end(random_data));
21  std::mt19937 seededEngine (seeds);
22  return seededEngine;
23 }
tools::randomly_seeded_MT
auto randomly_seeded_MT()
Generate random numbers.
Definition: tools.h:16
script.begin
begin
Definition: script.py:184
tools
Tools commonly used in CppyABM.
Definition: tools.h:11
script.end
end
Definition: script.py:188