NCEPLIBS-ip  5.0.0
ipxetas.F90 File Reference

Expand or contract eta grids using linear interpolation. More...

Go to the source code of this file.

Functions/Subroutines

subroutine ipxetas (IDIR, IGDTNUMI, IGDTLEN, IGDTMPLI, NPTS_INPUT, BITMAP_INPUT, DATA_INPUT, IGDTNUMO, IGDTMPLO, NPTS_OUTPUT, BITMAP_OUTPUT, DATA_OUTPUT, IRET)
 Expand or contract eta grids using linear interpolation. More...
 

Detailed Description

Expand or contract eta grids using linear interpolation.

Author
Iredell
Date
96-04-10

Definition in file ipxetas.F90.

Function/Subroutine Documentation

◆ ipxetas()

subroutine ipxetas ( integer, intent(in)  IDIR,
integer, intent(in)  IGDTNUMI,
integer, intent(in)  IGDTLEN,
integer, dimension(igdtlen), intent(in)  IGDTMPLI,
integer, intent(in)  NPTS_INPUT,
logical(kind=1), dimension(npts_input), intent(in)  BITMAP_INPUT,
real, dimension(npts_input), intent(in)  DATA_INPUT,
integer, intent(out)  IGDTNUMO,
integer, dimension(igdtlen), intent(out)  IGDTMPLO,
integer, intent(in)  NPTS_OUTPUT,
logical(kind=1), dimension(npts_output), intent(out)  BITMAP_OUTPUT,
real, dimension(npts_output), intent(out)  DATA_OUTPUT,
integer, intent(out)  IRET 
)

Expand or contract eta grids using linear interpolation.

This subprogram transforms between the staggered eta grids as used in the eta model and for native grid transmission and their full expansion as used for general interpolation and graphics. The eta grids are rotated latitude-longitude grids staggered as defined by the arakawa e-grid, that is with mass data points alternating with wind data points.

This is similar to:

  • ipxwafs2() which uses linear interpolation and accounts for
  • bitmapped data.
  • ipxwafs2() which uses neighbor interpolation and accounts for
  • bitmapped data.

Program History Log

Date Programmer Comments
96-04-10 Iredell Initial
2015-07-14 Gayno Make grib 2 compliant. Replace 4-pt interpolation with call to ipolates.
2022-11-09 Engle Made ibi and ibo scalars.
Parameters
[in]idirinteger transform option.
  • 0 to expand staggered fields to full fields
  • -1 to contract full mass fields to staggered fields
  • -2 to contract full wind fields to staggered fields
[in]igdtnumiinteger grid definition template number - input grid. Corresponds to the gfldigdtnum component of the ncep g2 library gridmod data structure. Must be = 1 (for a rotated lat/lon grid.)
[in]igdtleninteger number of elements of the grid definition template array - same for input and output grids (=22) which are both rotated lat/lon grids. corresponds to the gfldigdtlen component of the ncep g2 library gridmod data structure.
[in]igdtmpliinteger (igdtlen) grid definition template array - input grid. Corresponds to the gfldigdtmpl component of the ncep g2 library gridmod data structure (section 3 info):
  • 1 shape of earth, octet 15
    • 2 scale factor of spherical earth radius, octet 16
    • 3 scaled value of radius of spherical earth, octets 17-20
    • 4 scale factor of major axis of elliptical earth, octet 21
    • 5 scaled value of major axis of elliptical earth, octets 22-25
    • 6 scale factor of minor axis of elliptical earth, octet 26
    • 7 scaled value of minor axis of elliptical earth, octets 27-30
    • 8 number of points along a parallel, octs 31-34
    • 9 number of points along a meridian, octs 35-38
    • 10 basic angle of initial production domain, octets 39-42
    • 11 subdivisions of basic angle, octets 43-46
    • 12 latitude of first grid point, octets 47-50
    • 13 longitude of first grid point, octets 51-54
    • 14 resolution and component flags, octet 55
    • 15 latitude of last grid point, octets 56-59
    • 16 longitude of last grid point, octets 60-63
    • 17 i-direction increment, octets 64-67
    • 18 j-direction increment, octets 68-71
    • 19 scanning mode, octet 72
    • 20 latitude of southern pole of projection, octets 73-76
    • 21 longitude of southern pole of projection, octets 77-80
    • 22 angle of rotation of projection, octs 81-84
[in]npts_inputinteger number points input grid
[in]bitmap_inputlogical (npts_input) input grid bitmap
[in]data_inputreal (npts_input) input grid data
[out]igdtnumointeger grid definition template number - output grid. Corresponds to the gfldigdtnum component of the ncep g2 library gridmod data structure. Same as igdtnumi (=1 for a rotated lat/lon grid).
[out]igdtmplointeger (igdtlen) grid definition template array - output grid. Corresponds to the gfldigdtmpl component of the ncep g2 library gridmod data structure. Array definitions same as "igdtmpli".
[out]npts_outputinteger number points output grid. the j-dimension of the input and output grids are the same. When going from a staggered to a full grid the i-dimension increases to idim*2-1. When going from full to staggered the i-dimension decreases to (idim+1)/2.
[out]bitmap_outputlogical (npts_outut) output grid bitmap
[out]data_outputreal (npts_output) output grid data
[out]iretinteger return code
  • 0 successful transformation
  • non-0 invalid grid specs or problem in ipolates().

Definition at line 90 of file ipxetas.F90.