c c------------------------------------------------------------------ c Begin file /home/sting/foster/timegcm/addch4/addch4.f c------------------------------------------------------------------ c program addch4 c include "timeparam.h" include "timerd.h" include "glbm.h" parameter(imxm1=imx-1) logical found character*8 histvol(3) dimension gcmlat(jmx) data histvol /'ROBLE ','RGR92 ','TISS04 '/ data nhvols/1/, luhist/8/, md/21/, mh/0/, mm/0/ data luglbm/20/ c do j=1,jmx gcmlat(j) = -87.5+(j-1)*5. enddo c c Read timegcm history: c istart = 1 write(6,"(' ')") write(6,"('Read timegcm hist: ', + ' md:mh:mm=',i2,':',i2,':',i2)") md,mh,mm call gettime(histvol,nhvols,luhist,md,mh,mm,istart,found,ivf) if (.not.found) then write(6,"('>>> Stopping because proc could not find ', + 'model time ',i2,':',i2,':',i2)") md,mh,mm write(6,"(' History volume(s) searched = ',3a8)") + (histvol(i),i=1,3) stop 'timehist' endif c c Read glbmean history: call getglbm(luglbm) c c Put ch4 from glbmean into f array: c Also put special value for o21d into f array: c do i=3,imxp1 f(i,:,28) = glbmfld(:,igmch4) f(i,:,29) = 1.e-20 enddo c c Set periodic points in f: 1,2 = 73,74 and 75,76 = 3,4: c do ip=28,29 do i=1,2 f(i,:,ip) = f(i+imxm1,:,ip) f(i+imxp1,:,ip) = f(i+2,:,ip) enddo enddo c c Write new history file: c c stop 'done' end