This commit is contained in:
Timur A. Fatkhullin
2026-01-30 22:20:42 +03:00
parent 9aea122b08
commit a686731c0a
111 changed files with 27707 additions and 50 deletions

35
mcc_constants.h Normal file
View File

@@ -0,0 +1,35 @@
#pragma once
/****************************************************************************************
* *
* MOUNT CONTROL COMPONENTS LIBRARY *
* *
* *
* LIBRARY-WIDE CONSTANTS *
* *
****************************************************************************************/
#include <numbers>
#include "mcc_traits.h"
namespace mcc
{
constexpr double MCC_HALF_PI = std::numbers::pi / 2.0;
constexpr double MCC_TWO_PI = std::numbers::pi * 2.0;
static constexpr double MCC_SIDERAL_TO_UT1_RATIO = 1.002737909350795; // sideral/UT1
// a value to represent of infinite time duration according to type of duration representation
template <traits::mcc_time_duration_c DT>
static constexpr DT MCC_INFINITE_DURATION_V =
std::floating_point<typename DT::rep> ? DT{std::numeric_limits<typename DT::rep>::infinity()}
: DT{std::numeric_limits<typename DT::rep>::max()};
} // namespace mcc