I'm glad I'm not alone in finding this subroutine somewhat incomprehensible.
 -dave


On Mar 10, 2014, at 10:26 AM, "Jonathan J. Helmus" <notifications@github.com> wrote:

> In aoslib/awips.py:
> 
> > +
> > +    Parameters
> > +    ----------
> > +    z : array_like, 2D
> > +        Height field, missing/bad values are indicated by a value of 99998.0.
> > +    f : array_like, 2D
> > +        Coriolis parameter, must be the same shape as z.
> > +    spax : array_like, 2D
> > +        Grid spacing in the X direction, must be the same shape as z.
> > +    spay : array_like, 2D
> > +        Grid spacing in the Y direction, must be the same shape as z.
> > +    nx : int
> > +        First dimension of the spax and spay grids.
> > +    ny : int
> > +        Last dimension of the spax and spay grids.
> > +
> The first and last dimension are still valid Python dimensions and F2PY takes care of and C/FORTRAN row vs. column leading issues. What I can't figure out is what this function actually does and the importance of the nx and ny parameters. They seem to be specify the maximum indicies of the spax and spay arrays which makes me think they should be optional and default to the sizes of z, but the double nested FORTRAN do loop is a mess in dgeocomps.f.
> 
> —
> Reply to this email directly or view it on GitHub.
>