// // Created by dominik on 8/21/24. // #include "isosmallangle.h" #include #include #include "coordinates.h" SmallAngle::SmallAngle(const double delta, const double eta, const double chi, std::mt19937_64 &rng) : Motion(std::string("Isotropic Angle Jump"), delta, eta, rng), m_chi(chi * M_PI / 180.0) {}; SmallAngle::SmallAngle(std::mt19937_64 &rng) : Motion(std::string("Isotropic Angle Jump"), rng) {} void SmallAngle::initialize() { m_prev_pos = draw_position(); }; double SmallAngle::jump() { const double gamma{2 * M_PI * m_uni_dist(m_rng)}; m_prev_pos = rotate(m_prev_pos, m_chi, gamma); return omega_q(m_prev_pos); } void SmallAngle::setParameters(const std::unordered_map ¶meters) { m_chi = parameters.at("angle") * M_PI / 180.0; Motion::setParameters(parameters); }