FV3DYCORE  Version 2.0.0
fv_grid_utils.F90 File Reference
#include <fms_platform.h>

Go to the source code of this file.

Data Types

interface  fv_grid_utils_mod::fill_ghost
 

Modules

module  fv_grid_utils_mod
 The module 'fv_grid_utils' contains routines for setting up and computing grid-related quantities.
 

Functions/Subroutines

subroutine, public fv_grid_utils_mod::grid_utils_init (Atm, npx, npy, npz, non_ortho, grid_type, c2l_order)
 
subroutine, public fv_grid_utils_mod::grid_utils_end
 
subroutine, public fv_grid_utils_mod::direct_transform (c, i1, i2, j1, j2, lon_p, lat_p, n, lon, lat)
 The subroutine 'direct_transform' performs a direct transformation of the standard (symmetrical) cubic grid to a locally enhanced high-res grid on the sphere. More...
 
subroutine, public fv_grid_utils_mod::cube_transform (c, i1, i2, j1, j2, lon_p, lat_p, n, lon, lat)
 
real function, public fv_grid_utils_mod::inner_prod (v1, v2)
 
subroutine fv_grid_utils_mod::efactor_a2c_v (edge_vect_s, edge_vect_n, edge_vect_w, edge_vect_e, non_ortho, grid, agrid, npx, npy, bounded_domain, bd)
 The subroutine 'efactor_a2c_v' initializes interpolation factors at face edges for interpolating vectors from A to C grid. More...
 
subroutine fv_grid_utils_mod::edge_factors (edge_s, edge_n, edge_w, edge_e, non_ortho, grid, agrid, npx, npy, bd)
 The subroutine 'edge_factors' initializes interpolation factors at face edges for interpolation from A to B grid. More...
 
subroutine, public fv_grid_utils_mod::gnomonic_grids (grid_type, im, lon, lat)
 
subroutine fv_grid_utils_mod::gnomonic_ed (im, lamda, theta)
 The subroutine 'gnomonic_ed' computes the equal distances along the 4 edges of the cubed sphere. More...
 
subroutine fv_grid_utils_mod::gnomonic_ed_limited (im, in, nghost, lL, lR, uL, uR, lamda, theta)
 The subroutine 'gnomonic_ed_limited' creates a limited-area equidistant gnomonic grid with corners given by lL (lower-left), lR (lower-right), uL (upper-left),and uR (upper-right) with im by in cells. More...
 
subroutine fv_grid_utils_mod::gnomonic_angl (im, lamda, theta)
 
subroutine fv_grid_utils_mod::gnomonic_dist (im, lamda, theta)
 
subroutine fv_grid_utils_mod::symm_ed (im, lamda, theta)
 
subroutine fv_grid_utils_mod::latlon2xyz2 (lon, lat, p3)
 
subroutine, public fv_grid_utils_mod::latlon2xyz (p, e, id)
 The subroutine 'latlon2xyz' maps (lon, lat) to (x,y,z) More...
 
subroutine fv_grid_utils_mod::mirror_xyz (p1, p2, p0, p)
 The subroutine 'mirror_xyz' computes the mirror image of p0(x0, y0, z0) as p(x, y, z) given the "mirror" as defined by p1(x1, y1, z1), p2(x2, y2, z2), and the center of the sphere. More...
 
subroutine fv_grid_utils_mod::mirror_latlon (lon1, lat1, lon2, lat2, lon0, lat0, lon3, lat3)
 The subroutine 'mirror_latlon' computes the mirror image of (lon0, lat0) as (lon3, lat3) given the "mirror" as defined by (lon1, lat1), (lon2, lat2), and center of the sphere. More...
 
subroutine, public fv_grid_utils_mod::cart_to_latlon (np, q, xs, ys)
 
subroutine, public fv_grid_utils_mod::vect_cross (e, p1, p2)
 The subroutine 'vect_cross performs cross products of 3D vectors: e = P1 X P2. More...
 
subroutine fv_grid_utils_mod::get_center_vect (npx, npy, pp, u1, u2, bd)
 
subroutine, public fv_grid_utils_mod::get_unit_vect2 (e1, e2, uc)
 
subroutine fv_grid_utils_mod::get_unit_vect3 (p1, p2, uc)
 
subroutine, public fv_grid_utils_mod::normalize_vect (e)
 The subroutine 'normalize_vect' makes 'e' a unit vector. More...
 
subroutine, public fv_grid_utils_mod::intp_great_circle (beta, p1, p2, x_o, y_o)
 
subroutine, public fv_grid_utils_mod::spherical_linear_interpolation (beta, p1, p2, pb)
 The subroutine 'spherical_linear_interpolation' interpolates along the great circle connecting points p1 and p2. More...
 
subroutine, public fv_grid_utils_mod::mid_pt_sphere (p1, p2, pm)
 
subroutine fv_grid_utils_mod::mid_pt3_cart (p1, p2, e)
 
subroutine, public fv_grid_utils_mod::mid_pt_cart (p1, p2, e3)
 
real function, public fv_grid_utils_mod::great_circle_dist (q1, q2, radius)
 
real(kind=r_grid) function fv_grid_utils_mod::great_circle_dist_cart (v1, v2, radius)
 The function 'great_circle_dist_cart' calculates the normalized great circle distance between 'v1' and 'v2'. More...
 
subroutine fv_grid_utils_mod::intersect (a1, a2, b1, b2, radius, x_inter, local_a, local_b)
 The subroutine 'intersect' calculates the intersection of two great circles. More...
 
subroutine get_nearest ()
 
subroutine check_local (x1, x2, local)
 
subroutine fv_grid_utils_mod::intersect_cross (a1, a2, b1, b2, radius, x_inter, local_a, local_b)
 The subroutine 'intersect_cross' calculates the intersection of two great circles. More...
 
subroutine, public fv_grid_utils_mod::unit_vect_latlon (pp, elon, elat)
 
real(kind=r_grid) function, public fv_grid_utils_mod::v_prod (v1, v2)
 
subroutine fv_grid_utils_mod::init_cubed_to_latlon (gridstruct, hydrostatic, agrid, grid_type, ord, bd)
 
subroutine, public fv_grid_utils_mod::cubed_to_latlon (u, v, ua, va, gridstruct, npx, npy, km, mode, grid_type, domain, bounded_domain, c2l_ord, bd)
 
subroutine fv_grid_utils_mod::c2l_ord4 (u, v, ua, va, gridstruct, npx, npy, km, grid_type, domain, bounded_domain, mode, bd)
 
subroutine, public fv_grid_utils_mod::c2l_ord2 (u, v, ua, va, gridstruct, km, grid_type, bd, do_halo)
 
subroutine, public fv_grid_utils_mod::expand_cell (q1, q2, q3, q4, a1, a2, a3, a4, fac)
 
subroutine, public fv_grid_utils_mod::cell_center2 (q1, q2, q3, q4, e2)
 
subroutine fv_grid_utils_mod::cell_center3 (p1, p2, p3, p4, ec)
 The subroutine 'cell_center3' gets the center position of a cell. More...
 
real(kind=r_grid) function, public fv_grid_utils_mod::get_area (p1, p4, p2, p3, radius)
 
real(kind=r_grid) function fv_grid_utils_mod::dist2side (v1, v2, point)
 The function 'dist2side' calculates the shortest normalized distance on a sphere from point to straight line defined by 'v1' and 'v2'. More...
 
real(kind=r_grid) function, public fv_grid_utils_mod::dist2side_latlon (v1, v2, point)
 The function 'dist2side_latlon' is the version of 'dist2side' that takes points in latitude-longitude coordinates. More...
 
real(kind=r_grid) function, public fv_grid_utils_mod::spherical_angle (p1, p2, p3)
 
real(kind=r_grid) function, public fv_grid_utils_mod::cos_angle (p1, p2, p3)
 
real function, public fv_grid_utils_mod::g_sum (domain, p, ifirst, ilast, jfirst, jlast, ngc, area, mode, reproduce)
 The function 'g_sum' is the fast version of 'globalsum'. More...
 
real function, public fv_grid_utils_mod::global_qsum (p, ifirst, ilast, jfirst, jlast)
 The function 'global_qsum' computes the quick global sum without area weighting. More...
 
subroutine, public fv_grid_utils_mod::global_mx (q, n_g, qmin, qmax, bd)
 
subroutine fv_grid_utils_mod::global_mx_c (q, i1, i2, j1, j2, qmin, qmax)
 The subroutine 'global_mx_c' computes the global max and min at the cell corners. More...
 
subroutine fv_grid_utils_mod::fill_ghost_r4 (q, npx, npy, value, bd)
 
subroutine fv_grid_utils_mod::fill_ghost_r8 (q, npx, npy, value, bd)
 
subroutine, public fv_grid_utils_mod::make_eta_level (km, pe, area, kks, ak, bk, ptop, domain, bd)
 
subroutine fv_grid_utils_mod::invert_matrix (n, a, x)
 
subroutine fv_grid_utils_mod::elgs (a, n, indx)
 The subroutine 'elgs' performs the partial-pivoting gaussian elimination. More...
 
subroutine, public fv_grid_utils_mod::get_latlon_vector (pp, elon, elat)
 
subroutine, public fv_grid_utils_mod::project_sphere_v (np, f, e)
 
subroutine, public fv_grid_utils_mod::update_dwinds_phys (is, ie, js, je, isd, ied, jsd, jed, dt, u_dt, v_dt, u, v, gridstruct, npx, npy, npz, domain)
 The subroutine 'update_dwinds_phys' transforms the wind tendencies from the A grid to the D grid for the final update. More...
 
subroutine, public fv_grid_utils_mod::update2d_dwinds_phys (is, ie, js, je, isd, ied, jsd, jed, dt, u_dt, v_dt, u, v, gridstruct, npx, npy, npz, domain)
 The subroutine 'update2d_dwinds_phys' transforms the wind tendencies. More...
 
subroutine fv_grid_utils_mod::init_mq (phis, gridstruct, npx, npy, is, ie, js, je, ng)
 

Variables

logical, public fv_grid_utils_mod::symm_grid
 
integer, parameter, public fv_grid_utils_mod::f_p = selected_real_kind(20)
 
real, parameter, public fv_grid_utils_mod::big_number =1.d8
 
real, parameter fv_grid_utils_mod::tiny_number =1.d-8
 
real(kind=r_grid) fv_grid_utils_mod::radius =cnst_radius
 
real, parameter, public fv_grid_utils_mod::ptop_min =1.d-8
 

Function/Subroutine Documentation

◆ check_local()

subroutine check_local ( real(kind=r_grid), dimension(3), intent(in)  x1,
real(kind=r_grid), dimension(3), intent(in)  x2,
logical, intent(out)  local 
)
private

Definition at line 2199 of file fv_grid_utils.F90.

◆ get_nearest()

subroutine get_nearest ( )
private

Definition at line 2185 of file fv_grid_utils.F90.