PUBLIC INTERFACE ~ PUBLIC DATA ~ PUBLIC ROUTINES ~ NAMELIST ~ DIAGNOSTIC FIELDS ~ ERROR MESSAGES ~ REFERENCES ~ NOTES

Module diag_integral_mod

Contact:  fil
Reviewers: 
Change History: WebCVS Log


OVERVIEW

diag_integral_mod computes and outputs global and / or hemispheric physics integrals.



OTHER MODULES USED

time_manager_mod
fms_mod
constants_mod
mpp_mod

PUBLIC INTERFACE

diag_integral_init:
diag_integral_init is the constructor for diag_integral_mod.
diag_integral_field_init:
diag_integral_field_init registers and intializes an integral field
sum_field_2d:
Perform a 2 dimensional summation of named field
sum_field_3d:
Perform a 3 dimensional summation of named field
sum_field_wght_3d:
Perform a 3 dimensional weighted summation of named field
sum_field_2d_hemi:
Perform a 2 dimensional hemispherical summation of named field
diag_integral_output:
diag_integral_output determines if this is a timestep on which integrals are to be written. if not, it returns; if so, it calls write_field_averages.
diag_integral_end:
diag_integral_end is the destructor for diag_integral_mod.
set_axis_time:
Function to convert input time to a time_type
get_field_index:
get_field_index returns returns the index associated with an integral name.
write_field_averages:
Subroutine to sum multiple fields, average them and then write the result to an output file.
format_text_init:
format_text_init generates the header records to be output in the integrals file.
format_data_init:
format_text_init generates the format to be output in the integrals file.
get_axis_time:
Function to convert the time_type input variable into units of units and returns it in atime.
diag_integral_alarm:
Function to check if it is time to write integrals. if not writing integrals, return.
vert_diag_integral:
Function to perform a weighted integral in the vertical direction of a 3d data field


PUBLIC DATA

None.


PUBLIC ROUTINES

  1. diag_integral_init

    call diag_integral_init (Time_init, Time, blon, blat)
    DESCRIPTION
    diag_integral_init is the constructor for diag_integral_mod.


    INPUT
    Time_init    Initial time to start the integral
       [time_type]
    Time    current time
       [time_type]
    latb    array of model latitudes at cell boundaries [radians]
       [real]
    lonb    array of model longitudes at cell boundaries [radians]
       [real]

  2. diag_integral_field_init

    call diag_integral_field_init (name, format)
    DESCRIPTION
    diag_integral_field_init registers and intializes an integral field


    INPUT
    name    Name of the field to be integrated
       [character]
    format    Output format of the field to be integrated
       [character]

  3. sum_field_2d

    call sum_field_2d (name, data, is, js)
    DESCRIPTION
    Perform a 2 dimensional summation of named field


    INPUT
    name    Name of the field to be integrated
       [character]
    data    field of integrands to be summed over
       [real]
    is, js    starting i,j indices over which summation is to occur
       [integer]

  4. sum_field_3d

    call sum_field_3d (name, data, is, js)
    DESCRIPTION
    Perform a 3 dimensional summation of named field


    INPUT
    name    Name of the field to be integrated
       [character]
    data    field of integrands to be summed over
       [real]
    is, js    starting i,j indices over which summation is to occur
       [integer]

  5. sum_field_wght_3d

    call sum_field_wght_3d (name, data, wt, is, js)
    DESCRIPTION
    Perform a 3 dimensional weighted summation of named field


    INPUT
    name    Name of the field to be integrated
       [character]
    data    field of integrands to be summed over
       [real]
    wt    the weight function to be evaluated at summation
       [real]
    is, js    starting i,j indices over which summation is to occur
       [integer]

  6. sum_field_2d_hemi

    call sum_field_2d_hemi (name, data, is, ie, js, je)
    DESCRIPTION
    Perform a 2 dimensional hemispherical summation of named field


    INPUT
    name    Name of the field to be integrated
       [character]
    data    field of integrands to be summed over
       [real]
    is, js, ie, je    starting/ending i,j indices over which summation is to occur
       [integer]

  7. diag_integral_output

    call diag_integral_output (Time)
    DESCRIPTION
    diag_integral_output determines if this is a timestep on which integrals are to be written. if not, it returns; if so, it calls write_field_averages.


    INPUT
    Time    integral time stamp at the current time
       [time_type]

  8. diag_integral_end

    call diag_integral_end (Time)
    DESCRIPTION
    diag_integral_end is the destructor for diag_integral_mod.


    INPUT
    Time    integral time stamp at the current time
       [time_type]

  9. set_axis_time

    time = set_axis_time (atime, units)
    DESCRIPTION
    Function to convert input time to a time_type


    INPUT
    atime    integral time stamp at the current time
       [real]
    units    input units, not used
       [character]

  10. get_field_index

    index = get_field_index (name)
    DESCRIPTION
    get_field_index returns returns the index associated with an integral name.


    INPUT
    name    Name associated with an integral
       [real]

  11. write_field_averages

    call write_field_averages (Time)
    DESCRIPTION
    Subroutine to sum multiple fields, average them and then write the result to an output file.


    INPUT
    Time    integral time stamp at the current time
       [time_type]

  12. format_text_init

    call format_text_init (nst_in, nend_in)
    DESCRIPTION
    format_text_init generates the header records to be output in the integrals file.


    INPUT
    nst_in, nend_in    starting/ending integral index which will be included in this format statement
       [integer]

  13. format_data_init

    call format_data_init (nst_in, nend_in)
    DESCRIPTION
    format_text_init generates the format to be output in the integrals file.


    INPUT
    nst_in, nend_in    starting/ending integral index which will be included in this format statement
       [integer]

  14. get_axis_time

    atime = get_axis_time (Time, units)
    DESCRIPTION
    Function to convert the time_type input variable into units of units and returns it in atime.


    INPUT
    Time    integral time stamp
       [time_type]
    units    input units of time_type
       [character]

  15. diag_integral_alarm

    result = diag_integral_alarm (Time)
    DESCRIPTION
    Function to check if it is time to write integrals. if not writing integrals, return.


    INPUT
    Time    current time
       [time_type]

  16. vert_diag_integral

    data2 = vert_diag_integral (data, wt)
    DESCRIPTION
    Function to perform a weighted integral in the vertical direction of a 3d data field


    INPUT
    data    integral field data arrays
       [real]
    wt    integral field weighting functions
       [real]


DATA SETS

None.


ERROR MESSAGES

None.


top