pro createUniformRainFields ;******************************************************************************************** ;******************************************************************************************** ; ;This program creates one precipitation field and copies the metafile from another location. ;The metafile was manualy crafted, prior to this program's execution. ; ;The most important feature to noticed is the /XDR keyword used with the openw command ; ;******************************************************************************************** ;******************************************************************************************** cd,'/hidrosigDataBases/DataBaseNSF_Project/BDRaster/Hidrologia/precipitation/storm/overManVis varInt=[6.,12.,18.,30.,60.,120.,240.,500.,1000.,2000.] cd,'010minUnifStorm' for i=0,n_elements(varInt)-1 do begin intLabel=strmid(strtrim(varInt[i]/10000.,2),2,4) spawn,'cp /home/ricardo/temp/precipitation precipitation_'+intLabel+'_010.metaVHC' openw,unit,'precipitation_'+intLabel+'_010.000000.01.January.2000.vhc',/get_lun,/xdr writeu,unit,replicate(varInt[i],258,258) close,unit free_lun,unit endfor end