!----------------------------------------- ! II.1 Define frequency of output and means ! ----------------------------------------- #if defined key_diainstant zsto = nwrite*rdt clop ="inst(only(x))" #else zsto = rdt clop ="ave(x)" #endif zout = ntrd*rdt IF( kt == nit000 ) THEN IF(lwp) WRITE (numout,*) ' Diavor: netCDF initialization' ! II.2 Compute julian date from starting date of the run ! ------------------------ CALL ymds2ju( nyear, nmonth, nday, 0.e0, zjulian ) IF (lwp) WRITE(numout,*)' ' IF (lwp) WRITE(numout,*)' Date 0 used :',nit000 & ,' YEAR ', nyear,' MONTH ', nmonth,' DAY ', nday & ,'Julian day : ', zjulian ! II.3 Define the T grid trend file (nidvor) ! --------------------------------- CALL dia_nam( clhstnam, ntrd, 'vort' ) ! filename IF(lwp) WRITE(numout,*) ' Name of NETCDF file ', clhstnam CALL histbeg( clhstnam, jpi, glamf, jpj, gphif,1, jpi, & ! Horizontal grid : glamt and gphit & 1, jpj, 0, zjulian, rdt, nh_t, nidvor) CALL wheneq( jpi*jpj, fmask, 1, 1., ndexvor1, ndimvor1 ) ! surface ! Declare output fields as netCDF variables CALL histdef( nidvor, "sovortPh", cvort//"grad Ph" , "s-2", & ! grad Ph & jpi,jpj,nh_t,1,1,1,-99,32,clop,zsto,zout) CALL histdef( nidvor, "sovortEk", cvort//"Energy", "s-2", & ! Energy & jpi,jpj,nh_t,1,1,1,-99,32,clop,zsto,zout) CALL histdef( nidvor, "sovozeta", cvort//"rel vorticity", "s-2", & ! rel vorticity & jpi,jpj,nh_t,1,1,1,-99,32,clop,zsto,zout) CALL histdef( nidvor, "sovortif", cvort//"coriolis", "s-2", & ! coriolis & jpi,jpj,nh_t,1,1,1,-99,32,clop,zsto,zout) CALL histdef( nidvor, "sovodifl", cvort//"lat diff ", "s-2", & ! lat diff & jpi,jpj,nh_t,1,1,1,-99,32,clop,zsto,zout) CALL histdef( nidvor, "sovoadvv", cvort//"vert adv", "s-2", & ! vert adv & jpi,jpj,nh_t,1,1,1,-99,32,clop,zsto,zout) CALL histdef( nidvor, "sovodifv", cvort//"vert diff" , "s-2", & ! vert diff & jpi,jpj,nh_t,1,1,1,-99,32,clop,zsto,zout) CALL histdef( nidvor, "sovortPs", cvort//"grad Ps", "s-2", & ! grad Ps & jpi,jpj,nh_t,1,1,1,-99,32,clop,zsto,zout) CALL histdef( nidvor, "sovortbv", cvort//"Beta V", "s-2", & ! beta.V & jpi,jpj,nh_t,1,1,1,-99,32,clop,zsto,zout) CALL histdef( nidvor, "sovowind", cvort//"wind stress", "s-2", & ! wind stress & jpi,jpj,nh_t,1,1,1,-99,32,clop,zsto,zout) CALL histdef( nidvor, "sovobfri", cvort//"bottom friction", "s-2", & ! bottom friction & jpi,jpj,nh_t,1,1,1,-99,32,clop,zsto,zout) CALL histdef( nidvor, "1st_mbre", cvort//"1st mbre", "s-2", & ! First membre & jpi,jpj,nh_t,1,1,1,-99,32,clop,zsto,zout) CALL histdef( nidvor, "sovorgap", cvort//"gap", "s-2", & ! gap between 1st and 2 nd mbre & jpi,jpj,nh_t,1,1,1,-99,32,clop,zsto,zout) CALL histend( nidvor ) ENDIF