sfc_climo_gen 1.14.0
All Namespaces Files Functions Variables Pages
search_frac_cats.f90 File Reference

Replace undefined values on the model grid. More...

Go to the source code of this file.

Functions/Subroutines

subroutine search_frac_cats (field, mask, idim, jdim, num_categories, tile, field_name)
 Replace undefined values on the model grid with valid values at a nearby neighbor.
 

Detailed Description

Replace undefined values on the model grid.

Author
George Gayno
Date
2022

Definition in file search_frac_cats.f90.

Function/Subroutine Documentation

◆ search_frac_cats()

subroutine search_frac_cats ( real(esmf_kind_r4), dimension(idim,jdim,num_categories), intent(inout) field,
integer(esmf_kind_i4), dimension(idim,jdim), intent(in) mask,
integer, intent(in) idim,
integer, intent(in) jdim,
integer, intent(in) num_categories,
integer, intent(in) tile,
character(len=*) field_name )

Replace undefined values on the model grid with valid values at a nearby neighbor.

Undefined values are typically associated with isolated islands where there is no source data. Routine searches a neighborhood with a radius of 100 grid points. If no valid values are found, a default value is used. This routine works for one tile of a cubed sphere grid. It does not consider valid values at adjacent faces. This routine works for fractional categorical fields, such as soil type.

Parameters
[in,out]field- input: Field before missing values are replaced.
  • output: Field after missing values are replaced.
[in]maskField bitmap. Field defined where mask=1.
[in]idimi dimension of tile.
[in]jdimj dimension of tile.
[in]num_categoriesNumber of veg/soil categories.
[in]tileTile number.
[in]field_nameField name.
Author
George Gayno
Date
2022

Definition at line 24 of file search_frac_cats.f90.

Referenced by interp_frac_cats().