fwrite MM5 output
Shailendra Rai
r_shail77 at REDIFFMAIL.COM
Fri Jul 29 02:02:27 EDT 2005
Hello,
U should write .gs file like
'open test24.ctl'
'set x 1 202'
'set y 1 133'
'set gxout fwrite'
'set fwrite uv.dat'
t=13
while (t<=36)
'set t 't
'set z 1'
'd u'
'd v'
t=t+1
endwhile
'disable fwrite'
Hope this should work
-----------------------------------------------------------------------
Shailendra Rai.
K. Banerjee Centre of Atmospheric and Ocean Studies
University of Allahabad
Allahabad
INDIA.
On Fri, 29 Jul 2005 DaNa L.Carlis wrote :
>Hello,
>
>I am attempting to write MM5 output to a binary file that can be read by
>GRADS. I only want to write the u and v component of the winds between the
>12th and 36th hour of the forecast run. I've attached a portion of the .ctl
>file that is produced using MM5toGrADS.
>
>dset ^test24.dat
>byteswapped
>title MM5 data
>undef -9999.
>pdef 99 69 lcc 20.50 -157.20 14.00 11.00 30.00 60.00 -157.20
> 2000. 2000.
>xdef 202 linear -157.44 0.0090
>ydef 133 linear 20.32 0.0090
>zdef 28 levels
> 0.99900
> 0.99600
> 0.99200
> 0.98750
> 0.98250
>tdef 49 linear 00:00Z24JUL2005 1hr
>vars 28
>u 28 99 u wind (m/s)
>v 28 99 v wind (m/s)
>
>Here is a copy of my .gs file that I'm using to write the data:
>
>'open test24.ctl'
>'set x 1 201'
>'set y 1 132'
>'set gxout fwrite'
>'set fwrite uv.dat'
>t=13
>while (t<=36)
>'set t 't
>'d u'
>'d v'
>t=t+1
>endwhile
>
>The .ctl file that is used to read the uv.dat binary file is the following:
>
>dset ^uv.dat
>title wind data
>undef -9999.
>xdef 202 linear -157.44 0.0090
>ydef 133 linear 20.32 0.0090
>zdef 1 levels 0.99900
>tdef 24 linear 12:00Z24JUL2005 1hr
>vars 2
>u 0 99 u wind (m/s)
>v 0 99 u wind (m/s)
>endvars
>
>So, the problem that I'm having is that I can write the data to the binary
>file, but when I open up grads to display the data that I wrote the plots
>are shifted or skewed. The display at time t=1 is fine, but as I move to
>t=5,6,7,etc.. the data becomes more skewed. Please help!!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20050729/a8b5fd29/attachment.html
More information about the gradsusr
mailing list