ESP32 MQTT IoT Communication
Loading...
Searching...
No Matches
random_walk.hh
Go to the documentation of this file.
1
11#ifndef RANDOM_WALK_HH
12#define RANDOM_WALK_HH
13#pragma once
14
15#include <cmath>
16#include <random>
17
22namespace random_walk
23{
28{
29 public:
33 RandomWalk();
38 RandomWalk(double _price);
47 double get_price() const;
51 void iteration();
52
53 private:
54 double price;
55 double u_bound;
56 double l_bound;
57 std::random_device rd;
58 std::mt19937 mt;
59 std::normal_distribution<double> dist;
60};
61}; // namespace random_walk
62#endif // RANDOM_WALK_HPP
A class containing the logic and data for a Random Walk.
Definition random_walk.hh:28
RandomWalk()
Constructor For the random Walk.
Definition random_walk.cc:17
~RandomWalk()
Destructor.
Definition random_walk.cc:13
void iteration()
Iterates forward one step.
Definition random_walk.cc:39
double get_price() const
Gets the internal price.
Definition random_walk.cc:34
Functions and classes for simulating Sensor Outputs.
Definition random_walk.cc:12