Changeset 5341 for trunk/NEMOGCM/NEMO/LIM_SRC_2
- Timestamp:
- 2015-06-03T16:59:46+02:00 (6 years ago)
- Location:
- trunk/NEMOGCM/NEMO/LIM_SRC_2
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/NEMOGCM/NEMO/LIM_SRC_2/ice_2.F90
r5123 r5341 24 24 ! !!* namicerun read in iceini * 25 25 CHARACTER(len=32) , PUBLIC :: cn_icerst_in !: suffix of ice restart name (input) 26 CHARACTER(len=256) , PUBLIC :: cn_icerst_indir !: ice restart in directory 26 27 CHARACTER(len=32) , PUBLIC :: cn_icerst_out !: suffix of ice restart name (output) 28 CHARACTER(len=256) , PUBLIC :: cn_icerst_outdir !: ice restart out directory 27 29 LOGICAL , PUBLIC :: ln_limdyn !: flag for ice dynamics (T) or not (F) 28 30 LOGICAL , PUBLIC :: ln_limdmp !: Ice damping -
trunk/NEMOGCM/NEMO/LIM_SRC_2/iceini_2.F90
r4624 r5341 40 40 !!---------------------------------------------------------------------- 41 41 !! NEMO/LIM2 4.0 , UCL - NEMO Consortium (2011) 42 !! $Id$ 42 !! $Id$ 43 43 !! Software governed by the CeCILL licence (NEMOGCM/NEMO_CeCILL.txt) 44 44 !!---------------------------------------------------------------------- … … 123 123 !! ** input : Namelist namicerun 124 124 !!------------------------------------------------------------------- 125 NAMELIST/namicerun/ cn_icerst_in, cn_icerst_out, ln_limdyn, ln_limdmp, acrit, hsndif, hicdif 125 NAMELIST/namicerun/ cn_icerst_in, cn_icerst_indir, cn_icerst_out, cn_icerst_outdir, & 126 ln_limdyn, ln_limdmp, acrit, hsndif, hicdif 126 127 INTEGER :: ios ! Local integer output status for namelist read 127 128 !!------------------------------------------------------------------- -
trunk/NEMOGCM/NEMO/LIM_SRC_2/limrst_2.F90
r2528 r5341 50 50 CHARACTER(LEN=20) :: clkt ! ocean time-step deine as a character 51 51 CHARACTER(LEN=50) :: clname ! ice output restart file name 52 CHARACTER(len=150) :: clpath ! full path to ice output restart file 52 53 !!---------------------------------------------------------------------- 53 54 ! … … 58 59 ! except if we write ice restart files every ice time step or if an ice restart file was writen at nitend - 2*nn_fsbc + 1 59 60 IF( kt == nitrst - 2*nn_fsbc + 1 .OR. nstock == nn_fsbc .OR. ( kt == nitend - nn_fsbc + 1 .AND. .NOT. lrst_ice ) ) THEN 60 ! beware of the format used to write kt (default is i8.8, that should be large enough...) 61 IF( nitrst > 99999999 ) THEN ; WRITE(clkt, * ) nitrst 62 ELSE ; WRITE(clkt, '(i8.8)') nitrst 61 IF( nitrst <= nitend .AND. nitrst > 0 ) THEN 62 ! beware of the format used to write kt (default is i8.8, that should be large enough...) 63 IF( nitrst > 99999999 ) THEN ; WRITE(clkt, * ) nitrst 64 ELSE ; WRITE(clkt, '(i8.8)') nitrst 65 ENDIF 66 ! create the file 67 clname = TRIM(cexper)//"_"//TRIM(ADJUSTL(clkt))//"_"//TRIM(cn_icerst_out) 68 clpath = TRIM(cn_icerst_outdir) 69 IF( clpath(LEN_TRIM(clpath):) /= '/' ) clpath = TRIM(clpath)//'/' 70 IF(lwp) THEN 71 WRITE(numout,*) 72 SELECT CASE ( jprstlib ) 73 CASE ( jprstdimg ) 74 WRITE(numout,*) ' open ice restart binary file: ',TRIM(clpath)//clname 75 CASE DEFAULT 76 WRITE(numout,*) ' open ice restart NetCDF file: ',TRIM(clpath)//clname 77 END SELECT 78 IF( kt == nitrst - 2*nn_fsbc + 1 ) THEN 79 WRITE(numout,*) ' kt = nitrst - 2*nn_fsbc + 1 = ', kt,' date= ', ndastp 80 ELSE ; WRITE(numout,*) ' kt = ' , kt,' date= ', ndastp 81 ENDIF 82 ENDIF 83 84 CALL iom_open( TRIM(clpath)//TRIM(clname), numriw, ldwrt = .TRUE., kiolib = jprstlib ) 85 lrst_ice = .TRUE. 63 86 ENDIF 64 ! create the file65 clname = TRIM(cexper)//"_"//TRIM(ADJUSTL(clkt))//"_"//TRIM(cn_icerst_out)66 IF(lwp) THEN67 WRITE(numout,*)68 SELECT CASE ( jprstlib )69 CASE ( jprstdimg ) ; WRITE(numout,*) ' open ice restart binary file: '//clname70 CASE DEFAULT ; WRITE(numout,*) ' open ice restart NetCDF file: '//clname71 END SELECT72 IF( kt == nitrst - 2*nn_fsbc + 1 ) THEN73 WRITE(numout,*) ' kt = nitrst - 2*nn_fsbc + 1 = ', kt,' date= ', ndastp74 ELSE ; WRITE(numout,*) ' kt = ' , kt,' date= ', ndastp75 ENDIF76 ENDIF77 78 CALL iom_open( clname, numriw, ldwrt = .TRUE., kiolib = jprstlib )79 lrst_ice = .TRUE.80 87 ENDIF 81 88 ! … … 188 195 ! eventually read netcdf file (monobloc) for restarting on different number of processors 189 196 ! if {cn_icerst_in}.nc exists, then set jlibalt to jpnf90 190 INQUIRE( FILE = TRIM(cn_icerst_in )//'.nc', EXIST = llok )197 INQUIRE( FILE = TRIM(cn_icerst_indir)//'/'//TRIM(cn_icerst_in)//'.nc', EXIST = llok ) 191 198 IF ( llok ) THEN ; jlibalt = jpnf90 ; ELSE ; jlibalt = jprstlib ; ENDIF 192 199 ENDIF 193 200 194 CALL iom_open ( cn_icerst_in, numrir, kiolib = jlibalt )201 CALL iom_open ( TRIM(cn_icerst_indir)//'/'//TRIM(cn_icerst_in), numrir, kiolib = jlibalt ) 195 202 196 203 CALL iom_get( numrir, 'kt_ice' , ziter )
Note: See TracChangeset
for help on using the changeset viewer.