Changeset 9495 for branches/UKMO/dev_merge_2017_restart_datestamp_GO6_mixing/NEMOGCM/NEMO/OPA_SRC/ICB/icbrst.F90
- Timestamp:
- 2018-04-23T16:34:55+02:00 (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/UKMO/dev_merge_2017_restart_datestamp_GO6_mixing/NEMOGCM/NEMO/OPA_SRC/ICB/icbrst.F90
r9493 r9495 25 25 USE netcdf ! netcdf routines for IO 26 26 USE iom 27 USE ioipsl, ONLY : ju2ymds ! for calendar28 27 USE icb_oce ! define iceberg arrays 29 28 USE icbutl ! iceberg utility routines … … 158 157 INTEGER :: jn ! dummy loop index 159 158 INTEGER :: ix_dim, iy_dim, ik_dim, in_dim 160 INTEGER :: iyear, imonth, iday 161 REAL (wp) :: zsec 162 REAL (wp) :: zfjulday 163 CHARACTER(len=256) :: cl_path 164 CHARACTER(len=256) :: cl_filename 165 CHARACTER(LEN=20) :: clkt ! ocean time-step deine as a character 159 CHARACTER(len=256) :: cl_path 160 CHARACTER(len=256) :: cl_filename 166 161 TYPE(iceberg), POINTER :: this 167 162 TYPE(point) , POINTER :: pt … … 171 166 cl_path = TRIM(cn_ocerst_outdir) 172 167 IF( cl_path(LEN_TRIM(cl_path):) /= '/' ) cl_path = TRIM(cl_path) // '/' 173 IF ( ln_rstdate ) THEN 174 zfjulday = fjulday + rdt / rday 175 IF( ABS(zfjulday - REAL(NINT(zfjulday),wp)) < 0.1 / rday ) zfjulday = REAL(NINT(zfjulday),wp) ! avoid truncation error 176 CALL ju2ymds( zfjulday, iyear, imonth, iday, zsec ) 177 WRITE(clkt, '(i4.4,2i2.2)') iyear, imonth, iday 168 IF( lk_mpp ) THEN 169 WRITE(cl_filename,'(A,"_icebergs_",I8.8,"_restart_",I4.4,".nc")') TRIM(cexper), kt, narea-1 178 170 ELSE 179 IF( kt > 999999999 ) THEN ; WRITE(clkt, * ) kt 180 ELSE ; WRITE(clkt, '(i8.8)') kt 181 ENDIF 182 ENDIF 183 IF( lk_mpp ) THEN 184 WRITE(cl_filename,'(A,"_icebergs_",A,"_restart_",I4.4,".nc")') TRIM(cexper), TRIM(ADJUSTL(clkt)), narea-1 185 ELSE 186 WRITE(cl_filename,'(A,"_icebergs_",A,"_restart.nc")') TRIM(cexper), TRIM(ADJUSTL(clkt)) 171 WRITE(cl_filename,'(A,"_icebergs_",I8.8,"_restart.nc")') TRIM(cexper), kt 187 172 ENDIF 188 173 IF (nn_verbose_level >= 0) WRITE(numout,'(2a)') 'icebergs, write_restart: creating ',TRIM(cl_path)//TRIM(cl_filename)
Note: See TracChangeset
for help on using the changeset viewer.