NCEPLIBS-ip 5.2.0
|
GDS wizard for mercator cylindrical. More...
Data Types | |
type | ip_mercator_grid |
Functions/Subroutines | |
subroutine | gdswzd_mercator (self, iopt, npts, fill, xpts, ypts, rlon, rlat, nret, crot, srot, xlon, xlat, ylon, ylat, area) |
GDS wizard for mercator cylindrical. | |
subroutine | init_grib1 (self, g1_desc) |
Initializes a mercator grid given a grib1_descriptor object. | |
subroutine | init_grib2 (self, g2_desc) |
Init GRIB2. | |
subroutine | mercator_grid_area (rlat, area) |
Grid box area for mercator cylindrical grids. | |
subroutine | mercator_map_jacob (rlat, xlon, xlat, ylon, ylat) |
Map jacobians for mercator cylindrical grids. | |
subroutine | mercator_vect_rot (crot, srot) |
Vector rotation fields for mercator cylindrical grids. | |
Variables | |
real | dlon |
Longitudinal direction grid length. | |
real | dphi |
Latitudinal direction grid length. | |
real | rerth |
Radius of the Earth. | |
GDS wizard for mercator cylindrical.
Octet numbers refer to GRIB2 - GRID DEFINITION TEMPLATE 3.10 - Mercator.
|
private |
GDS wizard for mercator cylindrical.
This routine decodes the grib 2 grid definition template (passed in integer form as decoded by the ncep g2 library) and returns one of the following:
Works for mercator cylindrical projections.
If the selected coordinates are more than one gridpoint beyond the the edges of the grid domain, then the relevant output elements are set to fill values.
The actual number of valid points computed is returned too.
Optionally, the vector rotations, map jacobians and the grid box areas may be returned. To compute the vector rotations, the optional arguments 'srot' and 'crot' must be present. To compute the map jacobians, the optional arguments 'xlon', 'xlat', 'ylon', 'ylat' must be present. to compute the grid box areas, the optional argument 'area' must be present.
Date | Programmer | Comments |
---|---|---|
96-04-10 | iredell | Initial |
96-10-01 | iredell | protected against unresolvable points |
97-10-20 | iredell | include map options |
2015-01-21 | gayno | merger of gdswiz01() and gdswzd01(). Make crot,sort,xlon,xlat,ylon,ylat and area optional arguments. Make part of a module. move vector rotation, map jacobian and grid box area computations to separate subroutines. |
2015-07-13 | gayno | convert to grib 2. replace grib 1 kgds array with grib 2 grid definition template array. Rename. |
2018-07-20 | wesley | add threads. |
[in] | self | grid descriptor. |
[in] | iopt | option flag
|
[in] | npts | maximum number of coordinates |
[in] | fill | fill value to set invalid output data (must be impossible value; suggested value: -9999.) |
[in,out] | xpts | (npts) grid x point coordinates if iopt>0 |
[in,out] | ypts | (npts) grid y point coordinates if iopt>0 |
[in,out] | rlon | (npts) earth longitudes in degrees e if iopt<0 (acceptable range: -360. to 360.) |
[in,out] | rlat | (npts) earth latitudes in degrees n if iopt<0 (acceptable range: -90. to 90.) |
[out] | nret | number of valid points computed |
[out] | crot | optional (npts) clockwise vector rotation cosines |
[out] | srot | optional (npts) clockwise vector rotation sines (ugrid=crot*uearth-srot*vearth; vgrid=srot*uearth+crot*vearth) |
[out] | xlon | optional (npts) dx/dlon in 1/degrees |
[out] | xlat | optional (npts) dx/dlat in 1/degrees |
[out] | ylon | optional (npts) dy/dlon in 1/degrees |
[out] | ylat | optional (npts) dy/dlat in 1/degrees |
[out] | area | optional (npts) area weights in m**2 (proportional to the square of the map factor) |
Definition at line 201 of file ip_mercator_grid_mod.F90.
References dlon, dphi, mercator_grid_area(), mercator_map_jacob(), mercator_vect_rot(), and rerth.
|
private |
Initializes a mercator grid given a grib1_descriptor object.
[in,out] | self | ip_mercator_grid object. |
[in] | g1_desc | GRIB1 descriptor. |
Definition at line 55 of file ip_mercator_grid_mod.F90.
References ip_constants_mod::dpr.
|
private |
Init GRIB2.
[in,out] | self | ip_mercator_grid object. |
[in] | g2_desc | GRIB2 descriptor. |
Definition at line 103 of file ip_mercator_grid_mod.F90.
|
private |
Grid box area for mercator cylindrical grids.
This subprogram computes the grid box area for a mercator cylindrical grid.
Date | Programmer | Comments |
---|---|---|
2015-01-21 | gayno | initial version |
2015-09-17 | gayno | rename as "mercator_grid_area" |
[in] | rlat | latitude of grid point in degrees (real) |
[out] | area | area weights in m**2 (real) |
Definition at line 390 of file ip_mercator_grid_mod.F90.
References dlon, dphi, and rerth.
Referenced by gdswzd_mercator().
|
private |
Map jacobians for mercator cylindrical grids.
This subprogram computes the map jacobians for a mercator cylindrical grid.
Date | Programmer | Comments |
---|---|---|
2015-01-21 | gayno | initial version |
2015-09-17 | gayno | rename as "mercator_map_jacob" |
[in] | rlat | latitude in degrees (real) |
[out] | xlon | dx/dlon in 1/degrees (real) |
[out] | xlat | dx/dlat in 1/degrees (real) |
[out] | ylon | dy/dlon in 1/degrees (real) |
[out] | ylat | dy/dlat in 1/degrees (real) |
Definition at line 362 of file ip_mercator_grid_mod.F90.
Referenced by gdswzd_mercator().
|
private |
Vector rotation fields for mercator cylindrical grids.
This subprogram computes the vector rotation sines and cosines for a mercator cylindrical grid.
Date | Programmer | Comments |
---|---|---|
2015-01-21 | gayno | initial version |
2015-09-17 | gayno | rename as "mercator_vect_rot". |
[in] | crot | clockwise vector rotation cosines (real) |
[in] | srot | clockwise vector rotation sines (real) (ugrid=crot*uearth-srot*vearth; vgrid=srot*uearth+crot*vearth) |
Definition at line 334 of file ip_mercator_grid_mod.F90.
Referenced by gdswzd_mercator().
real ip_mercator_grid_mod::dlon |
Longitudinal direction grid length.
Definition at line 43 of file ip_mercator_grid_mod.F90.
Referenced by gdswzd_mercator(), mercator_grid_area(), and mercator_map_jacob().
|
private |
Latitudinal direction grid length.
Definition at line 44 of file ip_mercator_grid_mod.F90.
Referenced by gdswzd_mercator(), mercator_grid_area(), and mercator_map_jacob().
|
private |
Radius of the Earth.
Definition at line 45 of file ip_mercator_grid_mod.F90.
Referenced by gdswzd_mercator(), and mercator_grid_area().