Tudat/Astrodynamics/BasicAstrodynamics/astrodynamicsFunctions.cpp
//! Compute two-body radial distance.
Compute two-body radial distance.
Compute two - body radial distance .
double computeKeplerRadialDistance( const Eigen::Vector6d& keplerianElements )
{
    return ( keplerianElements[ orbital_element_conversions::semiMajorAxisIndex ] *
            ( 1.0 - keplerianElements[ orbital_element_conversions::eccentricityIndex ] *
            keplerianElements[ orbital_element_conversions::eccentricityIndex ] ) ) /
            ( 1.0 + keplerianElements[ orbital_element_conversions::eccentricityIndex ] *
            std::cos( keplerianElements[ orbital_element_conversions::trueAnomalyIndex ] ) );
}
double computeKeplerRadialDistance ( const Eigen :: Vector6d & keplerianElements ) { return ( keplerianElements [ orbital_element_conversions :: semiMajorAxisIndex ] * ( 1.0 - keplerianElements [ orbital_element_conversions :: eccentricityIndex ] * keplerianElements [ orbital_element_conversions :: eccentricityIndex ] ) ) / ( 1.0 + keplerianElements [ orbital_element_conversions :: eccentricityIndex ] * std :: cos ( keplerianElements [ orbital_element_conversions :: trueAnomalyIndex ] ) ) ; }
Compute two-body radial distance.
Compute two - body radial distance .