atlas::grid::ComputeHorizontalStencil class

Compute stencil in horizontal direction (i,j)

Given a stencil width, the stencil for a given P{x,y} is:

i[0]     i[1]     i[2]    i[3]
 x        x        x         x       j + 0
  x       x       x        x         j + 1
             P
  x       x       x        x         j + 2
 x        x        x         x       j + 3

In case the x-component of P is aligned with any stencil, gridpoint, the stencil will assume the grid point is on the point P's left side:

i[0]     i[1]     i[2]    i[3]
 x        x        x         x       j + 0
  x       x       x        x         j + 1
          P
  x       x       x        x         j + 2
 x        x        x         x       j + 3

Constructors, destructors, conversion operators

ComputeHorizontalStencil() defaulted
ComputeHorizontalStencil(const StructuredGrid& grid, idx_t stencil_width)

Public functions

template<typename stencil_t>
void operator()(const double& x, const double& y, stencil_t& stencil) const