- 积分
- 127
- 贡献
-
- 精华
- 在线时间
- 小时
- 注册时间
- 2013-5-27
- 最后登录
- 1970-1-1
|
登录后查看更多精彩内容~
您需要 登录 才可以下载或查看,没有帐号?立即注册
x
本帖最后由 一闭一睁 于 2013-6-26 15:38 编辑
闲话少叙,上菜....
台站信息 7.txt
1 130.52416 42.63535
2 129.19614 42.27893
3 129.08132 42.98463
4 129.4146 42.76317
5 129.6718 43.33066
6 129.64566 43.31308
7 130.37929 42.85337
台站数据(标准化后) left.txt
生成多时次(48个月)站点资料 sta.grd的fortan程序
!7个站,48个月
integer i,j
real tim
integer nlev,nflag
real a1(7,48),lat(7),lon(7),stid(7)
character*8 id(7)
real a
open(1,file='c:\test_stn\left.txt')!7个水文站资料
open(2,file='c:\test_stn\7.txt')!台站数据
open(3,file='c:\test_stn\sta.grd',status='replace', form='binary')
read(1,*)((a1(i,j),i=1,7),j=1,48)
!读台站坐标数据
do i=1,7
read(2,*)stid(i),lat(i),lon(i)
enddo
!写数据
do i=1,48
tim=0.0
nlev=1
nflag=1
do j=1,7
write(3)stid(j),lat(j),lon(j),tim,nlev,nflag,a1(j,i)
!write(3,*)stid(j),lat(j),lon(j),tim,nlev,nflag,a1(j,i)
enddo
nlev=0
write(3)stid(j-1),lat(j-1),lon(j-1),tim,nlev,nflag
!write(3,*)stid(j-1),lat(j-1),lon(j-1),tim,nlev,nflag
enddo
close(3)
数据描述文件station.ctl
dset c:/test_stn/sta.grd
dtype station
stnmap c:/test_stn/station.map
undef -999.0
title jl
tdef 48 linear jan1951 1mo
vars 1
t 0 99 data
endvars
生成映射文件,报错了
ga-> ! stnmap -i c:/test_stn/station.ctl
Name of binary data set: c:/test_stn/sta.grd
Number of times in the data set: 48
Number of surface variables: 1
Number of level dependent variables: 0
Starting scan of station data binary file.
Binary data file open: c:/test_stn/sta.grd
Processing time step 1
Invalid station hdr found in station binary file
Possible causes: Invalid level count in hdr
Descriptor file mismatch
File not station data
Invalid relative time
levs = 1 flag = -1085527939 time = 1.4013e-45
,晕了,求助!
|
-
|