<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Hi Kevin:<br>
<br>
It looks like in your NAM-2011072200.ctl file you are defining one
vertical level:<br>
<br>
<font size="-1">zdef 1 levels 315<br>
<br>
</font>but you then assign two levels to each variable:<br>
<br>
<font size="-1">cpd 2 99 Condensation Pressure
Deficit (mb)<br>
isenps 2 99 Pressure (mb)<br>
u 2 99 Zonal component of wind (ms^-1)<br>
v 2 99 Meridional component of wind (ms^-1)</font><br>
<br>
I think if you change the "2's" above with "1", or for surface you
can have "0",<br>
it should work ok.<br>
<br>
Jim<br>
<br>
On 7/22/11 2:49 AM, Kevin Huyck wrote:
<blockquote cite="mid:4E2971D2.6050800@meridian-enviro.com"
type="cite">
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
<font size="-1">Good morning.<br>
<br>
I'm attempting to configure some post-processing subroutines for
several parameters I find useful. For my pathfinder case, I am
creating a binary file using "fwrite" to store four parameters.
Each parameter varies in the horizontal plane, but not in the
vertical (i.e. only one vertical level is computed). When I
output a single timestep, I can open and retrieve the data file
and the data display correctly. If I write each variable twice,
once for each time step, I can retrieve the first time step, but
not the second. At present I'm feeding commands into the
command-line interpreter rather than executing a script. I've
seen examples in the archives discussing varying the time
dimension by way of a "while" loop. Since I'm entering the
commands individually the result /should/ be the same as if run
from a script.<br>
<br>
I'm not sure where I'm making my mistake in the process, so any
guidance would be appreciated.<br>
<br>
Input data is the North American Mesoscale (NAM) 40 km model. I
am computing values for "t 1" and "t 2" during this trial
period. The variables utilized in the process are "cpd",
"isenps", "u", and "v". Command sequence is first, followed by
the .ctl file. I use a homemade script file, "compute_cpd.gs",
to conduct the necessary calculations. This script accepts three
arguments, Theta surface (in Kelvin), grid skip, and working
file number. compute_cpd.gs returns cpd, isenps, u, and v. In
this case, "z" in NAM-2011072200.dat represents the "theta"
level for the isentropic surface.<br>
<br>
--- Command Listing ---<br>
open NAM-2011072200.ctl<br>
set t 1<br>
run compute_cpd.gs 315 1 1<br>
<br>
set fwrite ./cpd/NAM-2011072200.dat<br>
set gxout fwrite<br>
<br>
d cpd<br>
d isenps<br>
d u<br>
d v<br>
<br>
set t 2<br>
run compute_cpd.gs 315 1 1<br>
<br>
d cpd<br>
d isenps<br>
d u<br>
d v<br>
<br>
disable fwrite<br>
reinit<br>
<br>
open ./cpd/NAM-2011072200.ctl<br>
set t 1<br>
run ./draw-cpd.gs<br>
<br>
clear graphics<br>
set t 2<br>
run ./draw-cpd.gs<br>
<br>
--- Error Output ---<br>
Low Level I/O Error: Read error on data file <br>
Data file name = ./cpd/NAM-2011072200.dat <br>
Error reading 200 bytes at location 704000 <br>
Data Request Error: Error for variable 'cpd'<br>
Error ocurred at column 1<br>
DISPLAY error: Invalid expression <br>
Expression = cpd<br>
Cannot plot color bar: No shading information<br>
Low Level I/O Error: Read error on data file <br>
Data file name = ./cpd/NAM-2011072200.dat <br>
Error reading 200 bytes at location 704000 <br>
Data Request Error: Error for variable 'cpd'<br>
Error ocurred at column 1<br>
DISPLAY error: Invalid expression <br>
Expression = cpd<br>
Low Level I/O Error: Read error on data file <br>
Data file name = ./cpd/NAM-2011072200.dat <br>
Error reading 200 bytes at location 880000 <br>
Data Request Error: Error for variable 'isenps'<br>
Error ocurred at column 1<br>
DISPLAY error: Invalid expression <br>
Expression = isenps<br>
Low Level I/O Error: Read error on data file <br>
Data file name = ./cpd/NAM-2011072200.dat <br>
Error reading 200 bytes at location 1056000 <br>
Data Request Error: Error for variable 'u'<br>
Operation Error: Error from skip function<br>
Error ocurred at column 1<br>
DISPLAY error: Invalid expression <br>
Expression = skip(u,2)<br>
<br>
--- ./cpd/NAM-2011072200.ctl Contents ---<br>
dset /home/Agena/klhuyck/cpd/NAM-2011072200.dat<br>
title NAM 40km Condensation Pressure Deficit<br>
undef -999000000.000000<br>
options little_endian<br>
xdef 200 linear -145.0 0.5<br>
ydef 110 linear 12.0 0.5<br>
zdef 1 levels 315<br>
tdef 2 linear 00Z22Jul2011 3hr<br>
vars 4<br>
cpd 2 99 Condensation Pressure Deficit (mb)<br>
isenps 2 99 Pressure (mb)<br>
u 2 99 Zonal component of wind (ms^-1)<br>
v 2 99 Meridional component of wind (ms^-1)<br>
endvars<br>
</font>
<div class="moz-signature"><br>
-- <br>
<span class="postbody"><span style="font-size: 10pt;
font-family: "Trebuchet MS"; color: rgb(0, 0,
192);">Kevin L. Huyck<br>
Forecaster, Meridian Environmental Technology, Inc.<br>
<a moz-do-not-send="true"
href="mailto:klhuyck@meridian-enviro.com">
klhuyck@meridian-enviro.com</a><br>
<br>
Composed using Mozilla Thunderbird!</span></span> </div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
gradsusr mailing list
<a class="moz-txt-link-abbreviated" href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a>
<a class="moz-txt-link-freetext" href="http://gradsusr.org/mailman/listinfo/gradsusr">http://gradsusr.org/mailman/listinfo/gradsusr</a>
</pre>
</blockquote>
</body>
</html>