m_time¶
Inctime is the main program.
Module
Description
- Description
- This module contains routines and functions to manipulate time periods, e.g, functions to calculate total number of hours, days, months and years between two dates, also contains routines to convert julian days to gregorian day and vice and versa.
- History
- 15 Jun 2005 - J. G. de Mattos - Initial Version
- 18 Mar 2010 - J. G. de Mattos - Include Time calculation:
- End day of Month [eom]
- Number of hours [noh]
- Number of days [nod]
- Number of months [nom]
- Number of year [moy]
- 23 Mar 2010 - J. G. de Mattos - Modified the call for Cal2Jul routine
- was created the interface block for use of this new Cal2Jul
- 09 May 2013 - J. G. de Mattos - Removed Bug in Number of Hours
- 05 Feb 2014 - J. G. de Mattos - Include day of year calculation
Quick access
Variables: | cal2jul |
---|---|
Routines: | jul2cal() , cal2jul_() , noy() , nod() , noh() , nom() , doy() , eom() , cal2jul__() |
Variables
-
time_module/
cal2jul
¶
type: attrs: public Convert from gregorian to julian day
-
Subroutines and functions
-
function
time_module/
eom
(year, month)¶ - Description
- This function calculate the end day of month.
- History
- 18 Mar 2010 - J. G. de Mattos - Initial Version
Parameters: - year [integer,in]
- month [integer,in]
Return: day [integer]
-
function
time_module/
noh
(di, df)¶ - Description
- This function calculate the total number of hours between two dates.
- History
- 18 Mar 2010 - J. G. de Mattos - Initial Version
Parameters: - di [integer,in] :: Starting Date
- df [integer,in] :: Ending Date
Return: nhour [integer]
-
function
time_module/
nod
(di, df)¶ - Description
- This function calculate the total number of days between two dates.
- History
- 18 Mar 2010 - J. G. de Mattos - Initial Version
Parameters: - di [integer,in] :: Starting Date
- df [integer,in] :: Ending Date
Return: nday [integer]
-
function
time_module/
nom
(di, df)¶ - Description
- This function calculate the total number of months between two dates.
- History
- 18 Mar 2010 - J. G. de Mattos - Initial Version
Parameters: - di [integer,in] :: Starting Date
- df [integer,in] :: Ending Date
Return: nmonth [integer]
-
function
time_module/
noy
(di, df)¶ - Description
- This function calculate the total number of Years between two dates.
- History
- 18 Mar 2010 - J. G. de Mattos - Initial Version
Parameters: - di [integer,in] :: Starting Date
- df [integer,in] :: Ending Date
Return: nyear [integer]
-
function
time_module/
doy
(nymd, nhms)¶ - Description
- This function calculate the day of the year
- History
- 05 Feb 2014 - J. G. de Mattos - Initial Version
Parameters: - nymd [integer,in] :: year month day (yyyymmdd)
- nhms [integer,in] :: hour minute second (hhmnsd)
Return: day [real]
Called from: Call to:
-
function
time_module/
cal2jul_
(caldate)¶ - Description
- This function calculate the julian day from gregorian day.
- History
- 15 Jun 2005 - J. G. de Mattos - Initial Version
Parameters: caldate [integer,in] Return: julian [real] Call to: cal2jul__()
-
function
time_module/
cal2jul__
(ymd, hms)¶ - Description
- This function calculate the julian day from gregorian day
- History
- 15 Jun 2005 - J. G. de Mattos - Initial Version
Parameters: - ymd [integer,in]
- hms [integer,in]
Return: julian [real]
Called from:
-
subroutine
time_module/
jul2cal
(jd, ymd, hms)¶ - Description
- This function calculate the gregorian date from julian day.
- History
- 15 Jun 2005 - J. G. de Mattos - Initial Version
- 23 Mar 2011 - J. G. de Mattos - Modified Interface
- to a subroutine call
- Remarks
- This algorithm was adopted from Press et al.
Parameters: - jd [real,in]
- ymd [integer] :: year month day (yyyymmdd)
- hms [integer] :: hour minute second (hhmnsd)
Called from: