FV3 Bundle
interpolator.F90 File Reference
#include <fms_platform.h>
#include <file_version.h>
Include dependency graph for interpolator.F90:

Go to the source code of this file.

Data Types

interface  interpolator_mod::interpolator
 
interface  interpolator_mod::assignment(=)
 
interface  interpolator_mod::interp_weighted_scalar
 
type  interpolator_mod::interpolate_type
 Redundant climatology data between fields. More...
 

Modules

module  interpolator_mod
 interpolator_mod is a module to interpolate climatology data to model the grid.
 

Functions/Subroutines

subroutine, public interpolator_mod::interpolate_type_eq (Out, In)
 interpolator_type_eq receives the variable In and Out as input and returns Out. More...
 
subroutine, public interpolator_mod::interpolator_init (clim_type, file_name, lonb_mod, latb_mod, data_names, data_out_of_bounds, vert_interp, clim_units, single_year_file)
 interpolator_init receives various data as input in order to initialize interpolating. More...
 
subroutine interpolator_mod::cell_center2 (q1, q2, q3, q4, e2)
 cell_center2 receives the variables q1, q2, q3, and q4 as inputs and returns e2. More...
 
subroutine interpolator_mod::cart_to_latlon (np, q, xs, ys)
 car_to_latlon receives the variables np, q, xs, and ys as inputs and returns q, xs, and ys. More...
 
subroutine interpolator_mod::latlon2xyz (p, e)
 latlon2xyz receives the variable p as input and returns e as output in order to map (lon, lat) to (x,y,z). More...
 
integer function interpolator_mod::check_climo_units (units)
 check_climo_units checks the units that the climatology data is using. This is needed to allow for conversion of datasets to mixing ratios which is what the vertical interpolation scheme requires. The default is to assume no conversion is needed. If the units are those of a column burden (kg/m2) then conversion to mixing ratio is flagged. More...
 
subroutine, public interpolator_mod::init_clim_diag (clim_type, mod_axes, init_time)
 init_clim_diag is a routine to register diagnostic fields for the climatology file. This routine calculates the domain decompostion of the climatology fields for later export through send_data. The ids created here are for column burdens that will diagnose the vertical interpolation routine. More...
 
subroutine, public interpolator_mod::obtain_interpolator_time_slices (clim_type, Time)
 obtain_interpolator_time_slices makes sure that the appropriate time slices are available for interpolation on this time step. More...
 
subroutine, public interpolator_mod::unset_interpolator_time_flag (clim_type)
 unset_interpolator_time_flag sets a flag in clim_type to false. More...
 
subroutine interpolator_mod::interpolator_4d (clim_type, Time, phalf, interp_data, field_name, is, js, clim_units)
 interpolator_4D receives a field name as input and interpolates the field to model a 4D grid and time axis. More...
 
subroutine interpolator_mod::interpolator_3d (clim_type, Time, phalf, interp_data, field_name, is, js, clim_units)
 interpolator_3D receives a field name as input and interpolates the field to model a 3D grid and time axis. More...
 
subroutine interpolator_mod::interpolator_2d (clim_type, Time, interp_data, field_name, is, js, clim_units)
 interpolator_2D receives a field name as input and interpolates the field to model a 2D grid and time axis. More...
 
subroutine interpolator_mod::interpolator_4d_no_time_axis (clim_type, phalf, interp_data, field_name, is, js, clim_units)
 interpolator_4D_no_time_axis receives a field name as input and interpolates the field to model a 4D grid. More...
 
subroutine interpolator_mod::interpolator_3d_no_time_axis (clim_type, phalf, interp_data, field_name, is, js, clim_units)
 interpolator_3D_no_time_axis receives a field name as input and interpolates the field to model a 3D grid. More...
 
subroutine interpolator_mod::interpolator_2d_no_time_axis (clim_type, interp_data, field_name, is, js, clim_units)
 interpolator_2D_no_time_axis receives a field name as input and interpolates the field to model a 2D grid. More...
 
subroutine, public interpolator_mod::interpolator_end (clim_type)
 interpolator_end receives interpolate data as input and deallocates its memory. More...
 
subroutine, public interpolator_mod::read_data (clim_type, src_field, hdata, nt, i, Time)
 read_data receives various climate data as inputs and returns a horizontally interpolated climatology field. More...
 
subroutine interpolator_mod::read_data_no_time_axis (clim_type, src_field, hdata, i)
 read_data_no_time_axis receives various climate data as inputs and returns a horizontally interpolated climatology field without the time axis. More...
 
subroutine interpolator_mod::diag_read_data (clim_type, model_data, i, Time)
 diag_read_data receives the data read in by read_data as inputs and runs a diagnosis. More...
 
subroutine, public interpolator_mod::query_interpolator (clim_type, nfields, field_names)
 query_interpolator receives an interpolate type as input and returns the number of fields and field names. More...
 
character(len=64) function interpolator_mod::chomp (string)
 chomp receives a string from NetCDF files and removes CHAR(0) from the end of this string. More...
 
subroutine interpolator_mod::interp_weighted_scalar_2d (grdin, grdout, datin, datout)
 interp_weighted_scalar_2D receives the variables grdin, grdout, and datin as inputs and returns datout. More...
 
subroutine interpolator_mod::interp_weighted_scalar_1d (grdin, grdout, datin, datout)
 interp_weighted_scalar_1D receives the variables grdin, grdout, and datin as inputs and returns datout. More...
 
subroutine interpolator_mod::interp_linear (grdin, grdout, datin, datout)
 interp_linear receives the variables grdin, grdout, and datin as inputs and returns a linear interpolation. More...
 
program test
 
subroutine sulfate_init (aerosol, lonb, latb, names, data_out_of_bounds, vert_interp, units)
 
subroutine get_anthro_sulfate (sulfate, model_time, p_half, name, model_data, is, js, clim_units)
 
subroutine ozone_init (o3, lonb, latb, axes, model_time, data_out_of_bounds, vert_interp)
 
subroutine get_ozone (o3, model_time, p_half, model_data, is, js)
 

Variables

logical interpolator_mod::module_is_initialized = .false.
 
logical interpolator_mod::clim_diag_initialized = .false.
 
integer interpolator_mod::ndim
 No description. More...
 
integer interpolator_mod::nvar
 No description. More...
 
integer interpolator_mod::natt
 No description. More...
 
integer interpolator_mod::ntime
 No description. More...
 
integer interpolator_mod::nlat
 No description. More...
 
integer interpolator_mod::nlatb
 No description. More...
 
integer interpolator_mod::nlon
 No description. More...
 
integer interpolator_mod::nlonb
 No description. More...
 
integer interpolator_mod::nlev
 No description. More...
 
integer interpolator_mod::nlevh
 No description. More...
 
integer interpolator_mod::len
 
integer interpolator_mod::ntime_in
 
integer interpolator_mod::num_fields
 No description. More...
 
type(axistype), dimension(:), allocatable interpolator_mod::axes
 No description. More...
 
type(axistype), save interpolator_mod::time_axis
 No description. More...
 
type(fieldtype), dimension(:), allocatable interpolator_mod::varfields
 No description. More...
 
character(len=32) interpolator_mod::name
 
character(len=32) interpolator_mod::units
 No description. More...
 
integer interpolator_mod::sense
 No description. More...
 
integer, parameter interpolator_mod::max_diag_fields = 30
 No description. More...
 
integer, parameter interpolator_mod::increasing_downward = 1
 
integer, parameter interpolator_mod::increasing_upward = -1
 Flags to indicate direction of vertical axis in data file. More...
 
integer, parameter interpolator_mod::linear = 1
 
integer, parameter interpolator_mod::seasonal = 2
 
integer, parameter interpolator_mod::bilinear = 3
 
integer, parameter interpolator_mod::notime = 4
 Flags to indicate whether the time interpolation should be linear or some other scheme for seasonal data. NOTIME indicates that data file has no time axis. More...
 
integer, parameter interpolator_mod::pressure = 1
 
integer, parameter interpolator_mod::sigma = 2
 Flags to indicate where climatology pressure levels are pressure or sigma levels. More...
 
integer, parameter interpolator_mod::no_conv = 1
 
integer, parameter interpolator_mod::kg_m2 = 2
 Flags to indicate whether the climatology units are mixing ratio (kg/kg) or column integral (kg/m2). Vertical interpolation scheme requires mixing ratio at this time. More...
 
integer, parameter, public interpolator_mod::constant = 1
 
integer, parameter, public interpolator_mod::zero = 2
 Flags to indicate what to do when the model surface pressure exceeds the climatology surface pressure level. More...
 
integer, parameter, public interpolator_mod::interp_weighted_p = 10
 
integer, parameter, public interpolator_mod::interp_linear_p = 20
 
integer, parameter, public interpolator_mod::interp_log_p = 30
 Flags to indicate the type of vertical interpolation. More...
 
integer interpolator_mod::num_clim_diag = 0
 No description. More...
 
character(len=64), dimension(max_diag_fields) interpolator_mod::climo_diag_name
 No description. More...
 
integer, dimension(max_diag_fields) interpolator_mod::climo_diag_id
 
integer, dimension(max_diag_fields) interpolator_mod::hinterp_id
 No description. More...
 
real interpolator_mod::missing_value = -1.e10
 No description. More...
 
integer, parameter interpolator_mod::f_p = selected_real_kind(20)
 Higher precision (kind=16) for grid geometrical factors. More...
 
logical interpolator_mod::read_all_on_init = .false.
 No description. More...
 
integer interpolator_mod::verbose = 0
 No description. More...
 
logical interpolator_mod::conservative_interp = .true.
 No description. More...
 
logical interpolator_mod::retain_cm3_bug = .true.
 No description. More...
 

Function/Subroutine Documentation

◆ get_anthro_sulfate()

subroutine test::get_anthro_sulfate ( type(interpolate_type), intent(inout)  sulfate,
type(time_type), intent(in)  model_time,
real, dimension(:,:,:), intent(in)  p_half,
character(len=*), intent(in)  name,
real, dimension(:,:,:), intent(out)  model_data,
integer, intent(in), optional  is,
integer, intent(in), optional  js,
character(len=*), intent(out), optional  clim_units 
)

Definition at line 4183 of file interpolator.F90.

Here is the caller graph for this function:

◆ get_ozone()

subroutine test::get_ozone ( type(interpolate_type), intent(inout)  o3,
type(time_type), intent(in)  model_time,
real, dimension(:,:,:), intent(in)  p_half,
real, dimension(:,:,:), intent(out)  model_data,
integer, intent(in), optional  is,
integer, intent(in), optional  js 
)

Definition at line 4214 of file interpolator.F90.

Here is the caller graph for this function:

◆ ozone_init()

subroutine test::ozone_init ( type(interpolate_type), intent(inout)  o3,
real, dimension(:,:), intent(in)  lonb,
real, dimension(:,:), intent(in)  latb,
integer, dimension(:), intent(in)  axes,
type(time_type), intent(in)  model_time,
integer, dimension(:), intent(in)  data_out_of_bounds,
integer, dimension(:), intent(in), optional  vert_interp 
)

Definition at line 4198 of file interpolator.F90.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ sulfate_init()

subroutine test::sulfate_init ( type(interpolate_type), intent(inout)  aerosol,
real, dimension(:,:), intent(in)  lonb,
real, dimension(:,:), intent(in)  latb,
character(len=64), dimension(:), intent(in)  names,
integer, dimension(:), intent(in)  data_out_of_bounds,
integer, dimension(:), intent(in), optional  vert_interp,
character(len=*), dimension(:), intent(out), optional  units 
)

Definition at line 4166 of file interpolator.F90.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ test()

program test ( )

Definition at line 3919 of file interpolator.F90.

Here is the call graph for this function: