- 积分
- 216
- 贡献
-
- 精华
- 在线时间
- 小时
- 注册时间
- 2011-10-24
- 最后登录
- 1970-1-1
|
登录后查看更多精彩内容~
您需要 登录 才可以下载或查看,没有帐号?立即注册
x
本帖最后由 ★翼★ 于 2015-5-5 08:50 编辑
做等熵位涡分析,出现了一些问题,就高手指点一下
第一个问题:'reinit''open e:\toraji\fnl.ctl'
'set lon 0 360'
'set lat -90 90'
'set lev 1000 100'
"define t=T"
"define u=u"
"define v=v"
"define pp=lev"
"define coriol=2*7.29e-5*sin(lat*3.1415/180)"
"define dudy=cdiff(u,y)/(111177*cdiff(lat,y))"
"define dvdx=cdiff(v,x)/(111177*cdiff(lon,x)*cos(lat*3.1415/180))"
"define dt=t(z-1)*pow(1000/PP(z-1),0.286)-t(z+1)*pow(1000/PP(z+1),0.286)"
"define dp=100*(PP(z-1)-PP(z+1))"
"define dtdp=dt/dp"
"define part1="isen(dvdx,t,PP,315)
"define part2="isen(dudy,t,PP,315)
"define part3="isen(dtdp,t,PP,315)
"define pv315=-9.8*(coriol+part1-part2)*part3"
"set z 1"
*'set ccolor 1'
'set lon 80 150'
'set lat 10 60'
'd pv315*1000000'
'gxprint e:\toraji\2.png x1200 y800 white'
*'disable fwrite'
function isen(field,tgrid,pgrid,tlev)
我用这个程序正常出图,用了fwrite之后,就不能出了,ctl如下
dset e:\toraji\is315.dat
title ispv
undef -9.99e33
xdef 71 linear 80 1
ydef 51 linear 10 1
zdef 1 levels 1 1
tdef 1 linear 00z31JuL2001 6hr
vars 1
ipv 0 99 Geopotential vor
endvars
第二个问题,我做了一个时间循环,就是在315-K这个层上的多个时次的PV,但是出来的总是第一个时间的数据,好像while t不起作用,gs如下
*等熵位涡分析
'reinit'
'open e:\toraji\fnl.ctl'
'set lon 0 360'
'set lat -90 90'
*'set lev 1000 100'
*'set t 1 12'
*'set fwrite e:\toraji\is315.dat'
*'set gxout fwrite'
p=1
while(p<13)
'set t 'p''
zz=2
while(zz<3)
*'set z 2 22'
'set lev 1000 100'
"define t=T"
"define u=u"
"define v=v"
"define pp=lev"
"define coriol=2*7.29e-5*sin(lat*3.1415/180)"
"define dudy=cdiff(u,y)/(111177*cdiff(lat,y))"
"define dvdx=cdiff(v,x)/(111177*cdiff(lon,x)*cos(lat*3.1415/180))"
"define dt=t(z-1)*pow(1000/PP(z-1),0.286)-t(z+1)*pow(1000/PP(z+1),0.286)"
"define dp=100*(PP(z-1)-PP(z+1))"
"define dtdp=dt/dp"
"define part1="isen(dvdx,t,PP,315)
"define part2="isen(dudy,t,PP,315)
"define part3="isen(dtdp,t,PP,315)
"define pv330=-9.8*(coriol+part1-part2)*part3"
zz=zz+1
endwhile
"set z 1"
'set lon 80 140'
'set lat 20 55'
'd pv330*1000000'
p=p+1
endwhile
*'gxprint e:\toraji\2.png x1200 y800 white'
*'gxprint e:\toraji\ispv.eps white'
*'disable fwrite'
function isen(field,tgrid,pgrid,tlev)
|
|