diff --git a/Tudat/SimulationSetup/EstimationSetup/variationalEquationsSolver.h b/Tudat/SimulationSetup/EstimationSetup/variationalEquationsSolver.h index 7fe8f9b8ca..b2348d0474 100644 --- a/Tudat/SimulationSetup/EstimationSetup/variationalEquationsSolver.h +++ b/Tudat/SimulationSetup/EstimationSetup/variationalEquationsSolver.h @@ -641,10 +641,12 @@ class SingleArcVariationalEquationsSolver: public VariationalEquationsSolver< St getStateDerivativeModelMapFromVector( stateDerivativeModels ), bodyMap, parametersToEstimate ); // Create simulation object for dynamics only. +#if( BUILD_WITH_ESTIMATION_TOOLS ) if( propagatorSettings_->getDependentVariablesToSave( ) != nullptr ) { propagatorSettings_->getDependentVariablesToSave( )->stateDerivativePartials_ = stateDerivativePartials; } +#endif dynamicsSimulator_ = std::make_shared< SingleArcDynamicsSimulator< StateScalarType, TimeType > >( bodyMap, integratorSettings, propagatorSettings_, false, clearNumericalSolution, setIntegratedResult, false,