comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Finding Backward trajectory of wind data
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: Finding Backward trajectory of wind data [message #78648] Fri, 02 December 2011 06:38 Go to next message
Kenneth P. Bowman is currently offline  Kenneth P. Bowman
Messages: 585
Registered: May 2000
Senior Member
In article <e30fbc78-c426-4192-9c91-f75537fd9495@b32g2000yqn.googlegroups.com>,
shambhu <shambhu.mca36@gmail.com> wrote:

> Hi all,
>
> Am having a file(air.2000.nc) which consists of
> lat,lon,level(height),time(date) which is 6 hourly data. M trying to
> find nearest point & then to find trajectory. Am not getting how to
> find for lat=42, lon=79. Below is the code am using, which is answered
> in this forum. But am facing some probs.
>
> pro ConnectGrids
> ; First grid
> n1 = 72
> x1 = air ;file var
> y1 = air
>
> ; Find closest: method 1
> triangulate, x1, y1, c ; Compute Delaunay triangulation
> connect = GRIDDATA(x1,y1, air, Xout=x2, Yout=y2,$
> /NEAREST_N,TRIANGLES =c)
>
>
> please help me on this. looking forward
>
> thanks in adv

The file air.2000.nc probably contains air temperatures, which won't
help you very much with computing trajectories. Look at the
metadata and see.

In principle, calculating trajectories is easy. You just solve the
coupled ODE's

dx/dt = v(x,t), x(0) = x0

where x is the position vector, v is the velocity vector, and t is time.

In practice, this is a complex problem with many subtleties. I suggest
that you look into one of the publicly available trajectory models
like HYSPLIT or FLEXPART.

I think that you need much more help with this than you will be
able to get in this newsgroup.

Ken Bowman
Re: Finding Backward trajectory of wind data [message #78683 is a reply to message #78648] Thu, 15 December 2011 21:16 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
shambhu writes:

> I am a newbi to IDL. Am trying to find wind trajectory using nearest
> grid point. Am using NCEP data file air.2000.nc which consists of lon,
> lat, level, and time. But am getting error which is not reachable to
> me. Please help me on this

You are redefining the variable "fid" on this line:

ncdf_attget,fid,varndx,attname,fid

I think you want something like this:

ncdf_attget,fid,varndx,attname,attrVar

Cheers,

David


--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Finding Backward trajectory of wind data
Next Topic: Triangulate-reg

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 09:16:15 PDT 2025

Total time taken to generate the page: 0.00604 seconds