script for wind direction

Charles Seman Charles.Seman at NOAA.GOV
Tue Nov 15 13:59:58 EST 2005


Hi Partha,

Here is some code from an email to GrADS Listserv on 9/20/2004 by:
*
* Ken Takahashi G.       e-mail: ken at atmos.washington.edu
* (206) 685-9305
* Dept of Atmospheric Sciences
* University of Washington, Box 351640
'define dir=atan2(-u,-v)*180/3.141592654'
'define
dir=const(dir,1)*(const(maskout(dir,dir),0,-u)+const(maskout(360+dir,-dir),0,-u))'
* where the const(dir,1) preserves the original mask.

I haven't tested the above code...

I hope this helps,
Chuck

Dr. Parthasarathi Mukhopadhyay wrote:

>Hi all,
>Is there any script (.gs) by which wind direction could be obtained by giving u and v?
>Thanks,
>Partha
>--------
>
>------
>DR. PARTHASARATHI MUKHOPADHYAY
>Forecasting Research Division
>Indian Institute of Tropical Meteorology
>Dr. Homi Bhabha Road
>Pashan
>Pune-411008
>INDIA
>
>Telephone:+91 20 25893600 (Office)
>FAX       +91 20 25893825 (Office)
>Email:mpartha at tropmet.res.in
>      mpartha_in at yahoo.com
>-----------------------------
>
>

--

********************************************************************
 Charles Seman                                charles.seman at noaa.gov
 U.S. Department of Commerce / NOAA / OAR
 Geophysical Fluid Dynamics Laboratory         voice: (609) 452-6547
 201 Forrestal Road                              fax: (609) 987-5063
 Princeton, NJ  08540-6649            http://www.gfdl.noaa.gov/~cjs/
********************************************************************

"The contents of this message are mine personally and do not reflect
any position of the Government or NOAA."



More information about the gradsusr mailing list