2024-08-16 17:55:27 +00:00
|
|
|
//
|
|
|
|
// Created by dominik on 8/12/24.
|
|
|
|
//
|
|
|
|
#include "base.h"
|
|
|
|
|
2024-09-16 17:52:51 +00:00
|
|
|
Distribution::Distribution(const double tau, std::mt19937_64 &rng) : m_tau(tau), m_tau_jump(tau), m_rng(rng) {}
|
2024-08-16 17:55:27 +00:00
|
|
|
|
|
|
|
Distribution::Distribution(std::mt19937_64 &rng) : m_rng(rng) {}
|
|
|
|
|
|
|
|
double Distribution::tau_wait() const {
|
2024-09-16 17:52:51 +00:00
|
|
|
return std::exponential_distribution(1./m_tau_jump)(m_rng);
|
2024-08-16 17:55:27 +00:00
|
|
|
}
|
|
|
|
|