Re: Neighbours of a grid cell

From: Dave Allured - NOAA Affiliate <dave.allured_at_nyahnyahspammersnyahnyah>
Date: Fri Nov 30 2012 - 18:45:45 MST

For adjacent neighbors, you can do this with simple subscripting. Let
v(*,*) be a 2-D array. Let i and j be the integer subscripts. Assume the
order of data is south to north, and west to east.

South neighbor = v(i,j-1)
North neighbor = v(i,j+1)
West neighbor = v(i-1,j)
East neighbor = v(i+1,j)

What exactly do you mean by "all the neighbours"?

--Dave

On Fri, Nov 30, 2012 at 5:12 PM, Sasidharan, Aparna
<sasidha2@illinois.edu>wrote:

>
> Hi,
>
> I want to partition a HOMME grid for which I need to find the neighbours
> of every grid cell. Is there a function in NCL that helps you find all the
> neighbours of a given grid cell?
>
> Thanks
> Aparna
> ________________________________________
> From: ncl-talk-bounces@ucar.edu [ncl-talk-bounces@ucar.edu] on behalf of
> Mary Haley [haley@ucar.edu]
> Sent: Friday, November 30, 2012 9:45 AM
> To: George Vandenberghe
> Cc: ncl-talk@ucar.edu
> Subject: Re: idt
>
> Hi George,
>
> For future reference, this kind of question is more appropriate for
> ncl-install@ucar.edu.
>
> Idt is still included with NCL/NCAR Graphics. It probably just had a
> failure during the build.
>
> Can you send me the make-output file from your NCARG build?
>
> Thanks,
>
> --Mary
>
> On Nov 28, 2012, at 1:02 PM, George Vandenberghe wrote:
>
> > We have a large IBM sandybridge (Intel chip) Idataplex cluster running
> > a late release of RHL and
> > running predominantly intel compled codes. I tried
> > downloading ncl6.0 source and building the ncar graphics
> > subset using ifort and icc rather than gcc and gfort. It mostly built
> > but idt is missing from $NCARG_ROOT/bin Idt also did
> > not build using the linux default of gfortran. Has idt
> > been dropped from the ncar graphics base? Or do I have a build error?
> >
> >
> >
> >
> >
> >
> > _______________________________________________
> > ncl-talk mailing list
> > List instructions, subscriber options, unsubscribe:
> > http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Fri Nov 30 18:45:56 2012

This archive was generated by hypermail 2.1.8 : Fri Dec 07 2012 - 13:30:06 MST