diff --git a/src/neptuneClass.f90 b/src/neptuneClass.f90 index e65d5dd..cbf9d3c 100644 --- a/src/neptuneClass.f90 +++ b/src/neptuneClass.f90 @@ -125,7 +125,6 @@ module neptuneClass ! Variables ! !----------------------------------------------------------------------- - integer :: output_step ! output time step in seconds, 5 mins as default integer, public :: input_type_cov ! input type for covariance matrix logical, dimension(2), public :: flag_init_tolerances ! rel. and abs. tolerance initialization for numerical integration @@ -145,6 +144,7 @@ module neptuneClass type(covariance_t) :: initial_covariance !< initial covariance matrix written to output real(dp) :: progress_step !< step threshold for progress output to file + real(dp) :: output_step ! output time step that can touch double precision !======================================================================= ! @@ -286,7 +286,7 @@ type(Neptune_class) function constructor() constructor%reduction = Reduction_type() constructor%correlation_model = Correlation_class() - constructor%output_step = 300 ! output time step in seconds, 5 mins as default + constructor%output_step = 300.0 ! output time step in seconds, 5 mins as default constructor%input_type_cov = INPUT_UNDEFINED ! input type for covariance matrix constructor%flag_init_tolerances = (/.false.,.false./) ! rel. and abs. tolerance initialization for numerical integration @@ -463,7 +463,6 @@ subroutine initialize_input_array(this) ! INTEGER parameters call this%set_input(parName=C_GEOPOTENTIAL, valType='integer', initFlag=.true.) call this%set_input(parName=C_OPT_SAT_PROPERTIES, valType='integer', initFlag=.true.) - call this%set_input(parName=C_OUTPUT_STEP, valType='integer', initFlag=.true.) call this%set_input(parName=C_PAR_INT_COV_METHOD, valType='integer', initFlag=.true.) call this%set_input(parName=C_OPT_GEO_MODEL, valType='integer', initFlag=.true.) call this%set_input(parName=C_OPT_AP_FORECAST, valType='integer', initFlag=.true.) @@ -483,6 +482,7 @@ subroutine initialize_input_array(this) call this%set_input(parName=C_PAR_INT_COV_STEP, valType='double', initFlag=.true.) call this%set_input(parName=C_PAR_EARTH_RADIUS, valType='double', initFlag=.true.) call this%set_input(parName=C_OPT_SOL_FORECAST, valType='double', initFlag=.true.) + call this%set_input(parName=C_OUTPUT_STEP, valType='double', initFlag=.true.) ! this should be double for the fix ! ON/OFF parameters (also set default values, if available) do i = 1, this%derivatives_model%get_neptune_perturbation_number() @@ -1713,7 +1713,7 @@ integer function setNeptuneVar_char( & ! CASE for INTEGER parameters ! !------------------------ - case(C_GEOPOTENTIAL, C_OPT_SAT_PROPERTIES, C_OUTPUT_STEP, C_PAR_INT_COV_METHOD, & + case(C_GEOPOTENTIAL, C_OPT_SAT_PROPERTIES, C_PAR_INT_COV_METHOD, & C_OPT_GEO_MODEL, C_OPT_AP_FORECAST, C_OPT_STORE_DATA, C_COV_GEOPOTENTIAL, & C_PAR_INT_METHOD, C_OPT_ATMOSPHERE_MODEL) @@ -1761,12 +1761,6 @@ integer function setNeptuneVar_char( & call this%set_input(parName=C_OPT_STORE_DATA, val=val, set=.true.) call this%setStep(itemp) - !** Output - case(C_OUTPUT_STEP) - call this%set_input(parName=C_OUTPUT_STEP, val=val, set=.true.) - call this%output%write_to_output(C_OUTPUT_STEP, itemp) - this%output_step = itemp - !** state vector integration method case(C_PAR_INT_METHOD) call this%set_input(parName=C_PAR_INT_METHOD, val=val, set=.true.) @@ -1791,7 +1785,7 @@ integer function setNeptuneVar_char( & ! CASE for REAL parameters ! !------------------------- - case(C_PAR_MASS, C_PAR_CROSS_SECTION, C_PAR_CDRAG, & + case(C_PAR_MASS, C_PAR_CROSS_SECTION, C_PAR_CDRAG, C_OUTPUT_STEP, & C_PAR_CREFL, C_PAR_REENTRY, C_PAR_INT_RELEPS, C_PAR_INT_ABSEPS, & C_PAR_INT_COV_STEP, C_PAR_EARTH_RADIUS, & C_OPT_SOL_FORECAST) @@ -1860,6 +1854,12 @@ integer function setNeptuneVar_char( & call this%set_input(parName=C_OPT_SOL_FORECAST, val=val, set=.true.) call this%atmosphere_model%setSolarFluxForecast(dtemp) + !** Output + case(C_OUTPUT_STEP) + call this%set_input(parName=C_OUTPUT_STEP, val=val, set=.true.) + call this%output%write_to_output(C_OUTPUT_STEP, itemp) + this%output_step = dtemp + end select end if @@ -2736,7 +2736,6 @@ subroutine initializeInputArray(this) ! INTEGER parameters call this%set_input(parName=C_GEOPOTENTIAL, valType='integer', initFlag=.true.) call this%set_input(parName=C_OPT_SAT_PROPERTIES, valType='integer', initFlag=.true.) - call this%set_input(parName=C_OUTPUT_STEP, valType='integer', initFlag=.true.) call this%set_input(parName=C_PAR_INT_COV_METHOD, valType='integer', initFlag=.true.) call this%set_input(parName=C_OPT_GEO_MODEL, valType='integer', initFlag=.true.) call this%set_input(parName=C_OPT_AP_FORECAST, valType='integer', initFlag=.true.) @@ -2756,6 +2755,8 @@ subroutine initializeInputArray(this) call this%set_input(parName=C_PAR_INT_COV_STEP, valType='double', initFlag=.true.) call this%set_input(parName=C_PAR_EARTH_RADIUS, valType='double', initFlag=.true.) call this%set_input(parName=C_OPT_SOL_FORECAST, valType='double', initFlag=.true.) + call this%set_input(parName=C_OUTPUT_STEP, valType='double', initFlag=.true.) ! this should be double + ! ON/OFF parameters (also set default values, if available) do i = 1, this%derivatives_model%get_neptune_perturbation_number() diff --git a/work/input/neptune.inp b/work/input/neptune.inp index 42f4e78..e8fbeb4 100644 --- a/work/input/neptune.inp +++ b/work/input/neptune.inp @@ -200,7 +200,7 @@ # # Output time step (in seconds) # - 60 + 60.0 # # Time step for ephemerides in internal array (available via 'getNeptuneData' API) # (in seconds - IF not '0' then output time step (above) will be overwritten by this