Tudat/Astrodynamics/BasicAstrodynamics/astrodynamicsFunctions.cpp
//! Compute two-body orbital velocity with vis-viva equation.
Compute two-body orbital velocity with vis-viva equation.
Compute two - body orbital velocity with vis - viva equation .
double computeKeplerOrbitalVelocity( const double semiMajorAxis,
                                     const double eccentricity,
                                     const double trueAnomaly,
                                     const double gravitationalParameterOfCentralBody,
                                     const double massOfOrbitingBody )
{
    return std::sqrt( ( ( physical_constants::GRAVITATIONAL_CONSTANT * massOfOrbitingBody ) +
                        gravitationalParameterOfCentralBody ) * (
                          2.0 / computeKeplerRadialDistance( semiMajorAxis, eccentricity, trueAnomaly ) -
                          1.0 / semiMajorAxis ) );
}
double computeKeplerOrbitalVelocity ( const double semiMajorAxis , const double eccentricity , const double trueAnomaly , const double gravitationalParameterOfCentralBody , const double massOfOrbitingBody ) { return std :: sqrt ( ( ( physical_constants :: GRAVITATIONAL_CONSTANT * massOfOrbitingBody ) + gravitationalParameterOfCentralBody ) * ( 2.0 / computeKeplerRadialDistance ( semiMajorAxis , eccentricity , trueAnomaly ) - 1.0 / semiMajorAxis ) ) ; }
Compute two-body orbital velocity with vis-viva equation.
Compute two - body orbital velocity with vis - viva equation .