Tudat/Astrodynamics/OrbitDetermination/RotationalDynamicsPartials/secondDegreeGravitationalTorquePartial.cpp
//! Function to calculate central gravity partial w.r.t. central body gravitational parameter

Function to calculate central gravity partial w.r.t. central body gravitational parameter
Function to calculate central gravity partial w . r . t . central body gravitational parameter
void SecondDegreeGravitationalTorquePartial::wrtGravitationalParameterOfCentralBody(
        Eigen::MatrixXd& gravitationalParameterPartial )
{
    if( torqueModel_->getCurrentGravitationalParameterOfAttractingBody( ) == 0.0 )
    {
        throw std::runtime_error( "Error when calculating partial of SecondDegreeGravitationalTorquePartial w.r.t. mu: mu=0." );
    }
    gravitationalParameterPartial =
            torqueModel_->getTorque( ) / torqueModel_->getCurrentGravitationalParameterOfAttractingBody( );
}
void SecondDegreeGravitationalTorquePartial :: wrtGravitationalParameterOfCentralBody ( Eigen :: MatrixXd & gravitationalParameterPartial ) { if ( torqueModel_ -> getCurrentGravitationalParameterOfAttractingBody ( ) == 0.0 ) { throw std :: runtime_error ( " " ) ; } gravitationalParameterPartial = torqueModel_ -> getTorque ( ) / torqueModel_ -> getCurrentGravitationalParameterOfAttractingBody ( ) ; }
Function to calculate central gravity partial w.r.t.
Function to calculate central gravity partial w . r . t .