--- trunk/libf/bibio/inithist.f90 2008/02/27 13:16:39 3 +++ trunk/libf/bibio/inithist.f90 2010/03/25 14:29:07 27 @@ -6,7 +6,7 @@ contains - subroutine inithist(day0, anne0, tstep, nq, fileid, filevid, infile, t_ops, & + subroutine inithist(day0, anne0, tstep, nq, fileid, filevid, t_ops, & t_wrt) ! From inithist.F,v 1.1.1.1 2004/05/19 12:53:05 @@ -21,7 +21,6 @@ ! histend ! Entree: - ! infile: nom du fichier histoire a creer ! day0,anne0: date de reference ! tstep: duree du pas de temps en seconde ! t_ops: frequence de l'operation pour IOIPSL @@ -44,18 +43,15 @@ use serre use temps use ener - use advtrac_m + use iniadvtrac_m ! Arguments - character(len=*) infile integer day0, anne0 real, intent(in):: tstep, t_ops, t_wrt integer fileid, filevid integer nq ! Variables locales - - integer tau0 real zjulian integer iq real rlong(iip1,jjp1), rlat(iip1,jjp1) @@ -74,7 +70,6 @@ zan = anne0 dayref = day0 CALL ymds2ju(zan, 1, dayref, 0.0, zjulian) - tau0 = itau_dyn do jj = 1, jjp1 do ii = 1, iip1 @@ -83,12 +78,12 @@ enddo enddo - call histbeg_totreg(infile, iip1, rlong(:,1), jjp1, rlat(1,:), & + call histbeg_totreg("dyn_hist.nc", rlong(:,1), rlat(1,:), & 1, iip1, 1, jjp1, & - tau0, zjulian, tstep, uhoriid, fileid) + itau_dyn, zjulian, tstep, uhoriid, fileid) ! ! Creation du fichier histoire pour la grille en V (oblige pour l'instant, - ! IOIPSL ne permet pas de grilles avec des nombres de point differents dans + ! IOIPSL ne permet pas de grilles avec des nombres de point differents dans ! un meme fichier) do jj = 1, jjm @@ -98,9 +93,9 @@ enddo enddo - call histbeg_totreg('dyn_histv.nc', iip1, rlong(:,1), jjm, rlat(1,:jjm), & + call histbeg_totreg('dyn_histv.nc', rlong(:,1), rlat(1,:jjm), & 1, iip1, 1, jjm, & - tau0, zjulian, tstep, vhoriid, filevid) + itau_dyn, zjulian, tstep, vhoriid, filevid) ! ! Appel a histhori pour rajouter les autres grilles horizontales ! @@ -111,7 +106,7 @@ enddo enddo - call histhori(fileid, iip1, rlong, jjp1, rlat, 'scalar', & + call histhori_regular(fileid, iip1, rlong, jjp1, rlat, 'scalar', & 'Grille points scalaires', thoriid) ! ! Appel a histvert pour la grille verticale @@ -128,52 +123,52 @@ ! call histdef(fileid, 'ucov', 'vents u covariants', 'm/s', & iip1, jjp1, uhoriid, llm, 1, llm, zvertiid, & - 32, 'inst(X)', t_ops, t_wrt) + 'inst(X)', t_ops, t_wrt) ! ! Vents V ! call histdef(filevid, 'vcov', 'vents v covariants', 'm/s', & iip1, jjm, vhoriid, llm, 1, llm, zvertiid, & - 32, 'inst(X)', t_ops, t_wrt) + 'inst(X)', t_ops, t_wrt) ! ! Temperature potentielle ! call histdef(fileid, 'teta', 'temperature potentielle', '-', & iip1, jjp1, thoriid, llm, 1, llm, zvertiid, & - 32, 'inst(X)', t_ops, t_wrt) + 'inst(X)', t_ops, t_wrt) ! ! Geopotentiel ! call histdef(fileid, 'phi', 'geopotentiel instantane', '-', & iip1, jjp1, thoriid, llm, 1, llm, zvertiid, & - 32, 'inst(X)', t_ops, t_wrt) + 'inst(X)', t_ops, t_wrt) ! ! Traceurs ! DO iq=1,nq call histdef(fileid, ttext(iq), ttext(iq), '-', & iip1, jjp1, thoriid, llm, 1, llm, zvertiid, & - 32, 'inst(X)', t_ops, t_wrt) + 'inst(X)', t_ops, t_wrt) enddo ! ! Masse ! call histdef(fileid, 'masse', 'masse', 'kg', & iip1, jjp1, thoriid, 1, 1, 1, -99, & - 32, 'inst(X)', t_ops, t_wrt) + 'inst(X)', t_ops, t_wrt) ! ! Pression au sol ! call histdef(fileid, 'ps', 'pression naturelle au sol', 'Pa', & iip1, jjp1, thoriid, 1, 1, 1, -99, & - 32, 'inst(X)', t_ops, t_wrt) + 'inst(X)', t_ops, t_wrt) ! ! Pression au sol ! call histdef(fileid, 'phis', 'geopotentiel au sol', '-', & iip1, jjp1, thoriid, 1, 1, 1, -99, & - 32, 'inst(X)', t_ops, t_wrt) + 'inst(X)', t_ops, t_wrt) ! ! Fin !