CAM
clm_time_manager Module Reference

Functions/Subroutines

subroutine, public get_timemgr_defaults (calendar_out, start_ymd_out, start_tod_out, ref_ymd_out, ref_tod_out, stop_ymd_out, stop_tod_out, nelapse_out, dtime_out)
 
subroutine, public set_timemgr_init (calendar_in, start_ymd_in, start_tod_in, ref_ymd_in, ref_tod_in, stop_ymd_in, stop_tod_in, perpetual_run_in, perpetual_ymd_in, nelapse_in, dtime_in)
 
subroutine, public timemgr_init ()
 
subroutine, private init_clock (start_date, ref_date, curr_date, stop_date)
 
type(esmf_time) function timesetymd (ymd, tod, desc)
 
integer function, private timegetymd (date, tod)
 
subroutine, public timemgr_restart_io (ncid, flag)
 
subroutine, public timemgr_restart ()
 
subroutine, public calc_nestep ()
 
subroutine, private init_calendar ()
 
subroutine, private timemgr_print ()
 
subroutine, public advance_timestep ()
 
subroutine, public get_clock (clock)
 
type(esmf_time) function, public get_curr_esmf_time ()
 
integer function, public get_step_size ()
 
real(r8) function, public get_step_size_real ()
 
subroutine, public update_rad_dtime (doalb)
 
integer function, public get_rad_step_size ()
 
integer function, public get_nstep ()
 
subroutine, public get_curr_date (yr, mon, day, tod, offset)
 
subroutine, public get_curr_time_string (dateTimeString)
 
subroutine, public get_perp_date (yr, mon, day, tod, offset)
 
subroutine, public get_prev_date (yr, mon, day, tod)
 
subroutine, public get_start_date (yr, mon, day, tod)
 
integer function, public get_driver_start_ymd (tod)
 
subroutine, public get_ref_date (yr, mon, day, tod)
 
subroutine, public get_curr_time (days, seconds)
 
subroutine, public get_prev_time (days, seconds)
 
real(r8) function, public get_curr_calday (offset)
 
real(r8) function, public get_calday (ymd, tod)
 
character(len=esmf_maxstr) function, public get_calendar ()
 
integer function, public get_days_per_year (offset)
 
real(r8) function, public get_curr_yearfrac (offset)
 
real(r8) function, public get_prev_yearfrac ()
 
subroutine, public get_rest_date (ncid, yr)
 
subroutine, public set_nextsw_cday (nextsw_cday_in)
 
logical function, public is_beg_curr_day ()
 
logical function, public is_end_curr_day ()
 
logical function, public is_end_curr_month ()
 
logical function, public is_beg_curr_year ()
 
logical function, public is_end_curr_year ()
 
logical function, public is_first_step ()
 
logical function, public is_first_restart_step ()
 
logical function, public is_last_step ()
 
logical function, public is_perpetual ()
 
subroutine, public timemgr_datediff (ymd1, tod1, ymd2, tod2, days)
 
subroutine chkrc (rc, mes)
 
character(len=len(str)) function to_upper (str)
 
logical function, public is_restart ()
 
subroutine, private timemgr_spmdbcast ()
 
subroutine, private check_timemgr_initialized (caller)
 
subroutine, public timemgr_reset ()
 
subroutine for_test_set_curr_date (yr, mon, day, tod)
 

Variables

character(len= *), parameter, public no_leap_c = 'NO_LEAP'
 
character(len= *), parameter, public gregorian_c = 'GREGORIAN'
 
character(len=esmf_maxstr), save calendar = NO_LEAP_C
 
integer, parameter uninit_int = -999999999
 
real(r8), parameter uninit_r8 = -999999999.0
 
integer, save dtime = uninit_int
 
integer, save dtime_rad = uninit_int
 
integer, save nstep_rad_prev = uninit_int
 
integer, save nelapse = uninit_int
 
integer, save start_ymd = uninit_int
 
integer, save start_tod = 0
 
integer, save stop_ymd = uninit_int
 
integer, save stop_tod = 0
 
integer, save ref_ymd = uninit_int
 
integer, save ref_tod = 0
 
type(esmf_calendar), target, save tm_cal
 
type(esmf_clock), save tm_clock
 
type(esmf_time), save tm_perp_date
 
integer, save rst_step_sec = uninit_int
 
integer, save rst_start_ymd = uninit_int
 
integer, save rst_start_tod = uninit_int
 
integer, save rst_ref_ymd = uninit_int
 
integer, save rst_ref_tod = uninit_int
 
integer, save rst_curr_ymd = uninit_int
 
integer, save rst_curr_tod = uninit_int
 
integer, save rst_nstep_rad_prev
 
integer, save perpetual_ymd = uninit_int
 
logical, save tm_first_restart_step = .false.
 
logical, save tm_perp_calendar = .false.
 
logical, save timemgr_set = .false.
 
integer, save, public nestep = uninit_int
 
integer, save, public nsstep = 0
 
real(r8) nextsw_cday = uninit_r8
 

Function/Subroutine Documentation

◆ advance_timestep()

subroutine, public clm_time_manager::advance_timestep ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ calc_nestep()

subroutine, public clm_time_manager::calc_nestep ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ check_timemgr_initialized()

subroutine, private clm_time_manager::check_timemgr_initialized ( character(len=*), intent(in)  caller)
private
Here is the caller graph for this function:

◆ chkrc()

subroutine clm_time_manager::chkrc ( integer, intent(in)  rc,
character(len=*), intent(in)  mes 
)
private
Here is the caller graph for this function:

◆ for_test_set_curr_date()

subroutine clm_time_manager::for_test_set_curr_date ( integer, intent(in)  yr,
integer, intent(in)  mon,
integer, intent(in)  day,
integer, intent(in)  tod 
)
private
Here is the call graph for this function:

◆ get_calday()

real(r8) function, public clm_time_manager::get_calday ( integer, intent(in)  ymd,
integer, intent(in)  tod 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_calendar()

character(len=esmf_maxstr) function, public clm_time_manager::get_calendar ( )
Here is the caller graph for this function:

◆ get_clock()

subroutine, public clm_time_manager::get_clock ( type(esmf_clock), intent(inout)  clock)
Here is the call graph for this function:

◆ get_curr_calday()

real(r8) function, public clm_time_manager::get_curr_calday ( integer, intent(in), optional  offset)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_curr_date()

subroutine, public clm_time_manager::get_curr_date ( integer, intent(out)  yr,
integer, intent(out)  mon,
integer, intent(out)  day,
integer, intent(out)  tod,
integer, intent(in), optional  offset 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_curr_esmf_time()

type(esmf_time) function, public clm_time_manager::get_curr_esmf_time ( )
Here is the call graph for this function:

◆ get_curr_time()

subroutine, public clm_time_manager::get_curr_time ( integer, intent(out)  days,
integer, intent(out)  seconds 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_curr_time_string()

subroutine, public clm_time_manager::get_curr_time_string ( character(len=*), intent(out)  dateTimeString)
Here is the call graph for this function:

◆ get_curr_yearfrac()

real(r8) function, public clm_time_manager::get_curr_yearfrac ( integer, intent(in), optional  offset)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_days_per_year()

integer function, public clm_time_manager::get_days_per_year ( integer, intent(in), optional  offset)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_driver_start_ymd()

integer function, public clm_time_manager::get_driver_start_ymd ( integer, intent(out), optional  tod)
Here is the caller graph for this function:

◆ get_nstep()

integer function, public clm_time_manager::get_nstep ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_perp_date()

subroutine, public clm_time_manager::get_perp_date ( integer, intent(out)  yr,
integer, intent(out)  mon,
integer, intent(out)  day,
integer, intent(out)  tod,
integer, intent(in), optional  offset 
)
Here is the call graph for this function:

◆ get_prev_date()

subroutine, public clm_time_manager::get_prev_date ( integer, intent(out)  yr,
integer, intent(out)  mon,
integer, intent(out)  day,
integer, intent(out)  tod 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_prev_time()

subroutine, public clm_time_manager::get_prev_time ( integer, intent(out)  days,
integer, intent(out)  seconds 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_prev_yearfrac()

real(r8) function, public clm_time_manager::get_prev_yearfrac ( )
Here is the call graph for this function:

◆ get_rad_step_size()

integer function, public clm_time_manager::get_rad_step_size ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_ref_date()

subroutine, public clm_time_manager::get_ref_date ( integer, intent(out)  yr,
integer, intent(out)  mon,
integer, intent(out)  day,
integer, intent(out)  tod 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_rest_date()

subroutine, public clm_time_manager::get_rest_date ( type(file_desc_t), intent(inout)  ncid,
integer, intent(out)  yr 
)
Here is the caller graph for this function:

◆ get_start_date()

subroutine, public clm_time_manager::get_start_date ( integer, intent(out)  yr,
integer, intent(out)  mon,
integer, intent(out)  day,
integer, intent(out)  tod 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_step_size()

integer function, public clm_time_manager::get_step_size ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_step_size_real()

real(r8) function, public clm_time_manager::get_step_size_real ( )

◆ get_timemgr_defaults()

subroutine, public clm_time_manager::get_timemgr_defaults ( character(len=*), intent(out), optional  calendar_out,
integer, intent(out), optional  start_ymd_out,
integer, intent(out), optional  start_tod_out,
integer, intent(out), optional  ref_ymd_out,
integer, intent(out), optional  ref_tod_out,
integer, intent(out), optional  stop_ymd_out,
integer, intent(out), optional  stop_tod_out,
integer, intent(out), optional  nelapse_out,
integer, intent(out), optional  dtime_out 
)
Here is the caller graph for this function:

◆ init_calendar()

subroutine, private clm_time_manager::init_calendar ( )
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ init_clock()

subroutine, private clm_time_manager::init_clock ( type(esmf_time), intent(in)  start_date,
type(esmf_time), intent(in)  ref_date,
type(esmf_time), intent(in)  curr_date,
type(esmf_time), intent(in)  stop_date 
)
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ is_beg_curr_day()

logical function, public clm_time_manager::is_beg_curr_day ( )
Here is the call graph for this function:

◆ is_beg_curr_year()

logical function, public clm_time_manager::is_beg_curr_year ( )
Here is the call graph for this function:

◆ is_end_curr_day()

logical function, public clm_time_manager::is_end_curr_day ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ is_end_curr_month()

logical function, public clm_time_manager::is_end_curr_month ( )
Here is the call graph for this function:

◆ is_end_curr_year()

logical function, public clm_time_manager::is_end_curr_year ( )
Here is the call graph for this function:

◆ is_first_restart_step()

logical function, public clm_time_manager::is_first_restart_step ( )
Here is the caller graph for this function:

◆ is_first_step()

logical function, public clm_time_manager::is_first_step ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ is_last_step()

logical function, public clm_time_manager::is_last_step ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ is_perpetual()

logical function, public clm_time_manager::is_perpetual ( )

◆ is_restart()

logical function, public clm_time_manager::is_restart ( )
Here is the caller graph for this function:

◆ set_nextsw_cday()

subroutine, public clm_time_manager::set_nextsw_cday ( real(r8), intent(in)  nextsw_cday_in)
Here is the caller graph for this function:

◆ set_timemgr_init()

subroutine, public clm_time_manager::set_timemgr_init ( character(len=*), intent(in), optional  calendar_in,
integer, intent(in), optional  start_ymd_in,
integer, intent(in), optional  start_tod_in,
integer, intent(in), optional  ref_ymd_in,
integer, intent(in), optional  ref_tod_in,
integer, intent(in), optional  stop_ymd_in,
integer, intent(in), optional  stop_tod_in,
logical, intent(in), optional  perpetual_run_in,
integer, intent(in), optional  perpetual_ymd_in,
integer, intent(in), optional  nelapse_in,
integer, intent(in), optional  dtime_in 
)
Here is the caller graph for this function:

◆ timegetymd()

integer function, private clm_time_manager::timegetymd ( type(esmf_time), intent(inout)  date,
integer, intent(out), optional  tod 
)
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ timemgr_datediff()

subroutine, public clm_time_manager::timemgr_datediff ( integer, intent(in)  ymd1,
integer, intent(in)  tod1,
integer, intent(in)  ymd2,
integer, intent(in)  tod2,
real(r8)  days 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ timemgr_init()

subroutine, public clm_time_manager::timemgr_init ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ timemgr_print()

subroutine, private clm_time_manager::timemgr_print ( )
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ timemgr_reset()

subroutine, public clm_time_manager::timemgr_reset ( )
Here is the call graph for this function:

◆ timemgr_restart()

subroutine, public clm_time_manager::timemgr_restart ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ timemgr_restart_io()

subroutine, public clm_time_manager::timemgr_restart_io ( type(file_desc_t), intent(inout)  ncid,
character(len=*), intent(in)  flag 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ timemgr_spmdbcast()

subroutine, private clm_time_manager::timemgr_spmdbcast ( )
private
Here is the caller graph for this function:

◆ timesetymd()

type(esmf_time) function clm_time_manager::timesetymd ( integer, intent(in)  ymd,
integer, intent(in)  tod,
character(len=*), intent(in)  desc 
)
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ to_upper()

character(len=len(str)) function clm_time_manager::to_upper ( character(len=*), intent(in)  str)
private
Here is the caller graph for this function:

◆ update_rad_dtime()

subroutine, public clm_time_manager::update_rad_dtime ( logical, intent(in)  doalb)
Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ calendar

character(len=esmf_maxstr), save clm_time_manager::calendar = NO_LEAP_C
private

◆ dtime

integer, save clm_time_manager::dtime = uninit_int
private

◆ dtime_rad

integer, save clm_time_manager::dtime_rad = uninit_int
private

◆ gregorian_c

character(len=*), parameter, public clm_time_manager::gregorian_c = 'GREGORIAN'

◆ nelapse

integer, save clm_time_manager::nelapse = uninit_int
private

◆ nestep

integer, save, public clm_time_manager::nestep = uninit_int

◆ nextsw_cday

real(r8) clm_time_manager::nextsw_cday = uninit_r8
private

◆ no_leap_c

character(len=*), parameter, public clm_time_manager::no_leap_c = 'NO_LEAP'

◆ nsstep

integer, save, public clm_time_manager::nsstep = 0

◆ nstep_rad_prev

integer, save clm_time_manager::nstep_rad_prev = uninit_int
private

◆ perpetual_ymd

integer, save clm_time_manager::perpetual_ymd = uninit_int
private

◆ ref_tod

integer, save clm_time_manager::ref_tod = 0
private

◆ ref_ymd

integer, save clm_time_manager::ref_ymd = uninit_int
private

◆ rst_curr_tod

integer, save clm_time_manager::rst_curr_tod = uninit_int
private

◆ rst_curr_ymd

integer, save clm_time_manager::rst_curr_ymd = uninit_int
private

◆ rst_nstep_rad_prev

integer, save clm_time_manager::rst_nstep_rad_prev
private

◆ rst_ref_tod

integer, save clm_time_manager::rst_ref_tod = uninit_int
private

◆ rst_ref_ymd

integer, save clm_time_manager::rst_ref_ymd = uninit_int
private

◆ rst_start_tod

integer, save clm_time_manager::rst_start_tod = uninit_int
private

◆ rst_start_ymd

integer, save clm_time_manager::rst_start_ymd = uninit_int
private

◆ rst_step_sec

integer, save clm_time_manager::rst_step_sec = uninit_int
private

◆ start_tod

integer, save clm_time_manager::start_tod = 0
private

◆ start_ymd

integer, save clm_time_manager::start_ymd = uninit_int
private

◆ stop_tod

integer, save clm_time_manager::stop_tod = 0
private

◆ stop_ymd

integer, save clm_time_manager::stop_ymd = uninit_int
private

◆ timemgr_set

logical, save clm_time_manager::timemgr_set = .false.
private

◆ tm_cal

type(esmf_calendar), target, save clm_time_manager::tm_cal
private

◆ tm_clock

type(esmf_clock), save clm_time_manager::tm_clock
private

◆ tm_first_restart_step

logical, save clm_time_manager::tm_first_restart_step = .false.
private

◆ tm_perp_calendar

logical, save clm_time_manager::tm_perp_calendar = .false.
private

◆ tm_perp_date

type(esmf_time), save clm_time_manager::tm_perp_date
private

◆ uninit_int

integer, parameter clm_time_manager::uninit_int = -999999999
private

◆ uninit_r8

real(r8), parameter clm_time_manager::uninit_r8 = -999999999.0
private