Changeset 11358
- Timestamp:
- 2019-07-26T16:10:19+02:00 (5 years ago)
- Location:
- NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization
- Files:
-
- 1 deleted
- 18 edited
Legend:
- Unmodified
- Added
- Removed
-
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/cfgs/SHARED/namelist_ref
r11317 r11358 50 50 cn_ocerst_indir = "." ! directory from which to read input ocean restarts 51 51 cn_ocerst_out = "restart" ! suffix of ocean restart name (output) 52 cn_ocerst_outdir = "." 52 cn_ocerst_outdir = "." ! directory in which to write output ocean restarts 53 53 ln_iscpl = .false. ! cavity evolution forcing or coupling to ice sheet model 54 54 nn_istate = 0 ! output the initial state (1) or not (0) 55 55 ln_rst_list = .false. ! output restarts at list of times using nn_stocklist (T) or at set frequency with nn_stock (F) 56 nn_stock = 5840 ! frequency of creation of a restart file (modulo referenced to 1) 56 nn_stock = 0 ! used only if ln_rst_list = F: output restart freqeuncy (modulo referenced to 1) 57 ! ! = 0 force to write restart files only at the end of the run 58 ! ! = -1 do not do any restart 57 59 nn_stocklist = 0,0,0,0,0,0,0,0,0,0 ! List of timesteps when a restart file is to be written 58 nn_write = 5840 ! frequency of write in the output file (modulo referenced to nn_it000) 59 ln_mskland = .false. ! mask land points in NetCDF outputs (costly: + ~15%) 60 nn_write = 0 ! used only if key_iomput is not defined: output frequency (modulo referenced to nn_it000) 61 ! ! = 0 force to write output files only at the end of the run 62 ! ! = -1 do not do any output file 63 ln_mskland = .false. ! mask land points in NetCDF outputs 60 64 ln_cfmeta = .false. ! output additional data to netCDF files required for compliance with the CF metadata standard 61 65 ln_clobber = .true. ! clobber (overwrite) an existing file -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/ICE/icerst.F90
r10425 r11358 53 53 IF( kt == nit000 ) lrst_ice = .FALSE. ! default definition 54 54 55 IF( ln_rst_list .OR. nn_stock /= -1 ) THEN 55 56 ! in order to get better performances with NetCDF format, we open and define the ice restart file 56 57 ! one ice time step before writing the data (-> at nitrst - 2*nn_fsbc + 1), except if we write ice 57 58 ! restart files every ice time step or if an ice restart file was writen at nitend - 2*nn_fsbc + 1 58 IF( kt == nitrst - 2*nn_fsbc + 1 .OR. n stock == nn_fsbc &59 IF( kt == nitrst - 2*nn_fsbc + 1 .OR. nn_stock == nn_fsbc & 59 60 & .OR. ( kt == nitend - nn_fsbc + 1 .AND. .NOT. lrst_ice ) ) THEN 60 61 IF( nitrst <= nitend .AND. nitrst > 0 ) THEN … … 81 82 ENDIF 82 83 ENDIF 84 ENDIF 83 85 ! 84 86 IF( ln_icectl ) CALL ice_prt( kt, iiceprt, jiceprt, 1, ' - Beginning the time step - ' ) ! control print -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/OCE/BDY/bdyvol.F90
r11234 r11358 143 143 ! Check the cumulated transport through unstructured OBC once barotropic velocities corrected 144 144 ! ------------------------------------------------------ 145 IF( MOD( kt, n write ) == 0 .AND. ( kc == 1 ) ) THEN145 IF( MOD( kt, nn_write ) == 0 .AND. ( kc == 1 ) ) THEN 146 146 ! 147 147 ! compute residual transport across boundary -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/OCE/DIA/diawri.F90
r11325 r11358 426 426 !! define all the NETCDF files and fields 427 427 !! At each time step call histdef to compute the mean if ncessary 428 !! Each n write time step, output the instantaneous or mean fields428 !! Each nn_write time step, output the instantaneous or mean fields 429 429 !!---------------------------------------------------------------------- 430 430 INTEGER, INTENT( in ) :: kt ! ocean time-step index … … 442 442 REAL(wp), DIMENSION(jpi,jpj,jpk) :: zw3d ! 3D workspace 443 443 !!---------------------------------------------------------------------- 444 !445 IF( ln_timing ) CALL timing_start('dia_wri')446 444 ! 447 445 IF( ninist == 1 ) THEN !== Output the initial state and forcings ==! … … 450 448 ENDIF 451 449 ! 450 IF( nn_write == -1 ) RETURN ! we will never do any output 451 ! 452 IF( ln_timing ) CALL timing_start('dia_wri') 453 ! 452 454 ! 0. Initialisation 453 455 ! ----------------- … … 459 461 clop = "x" ! no use of the mask value (require less cpu time and otherwise the model crashes) 460 462 #if defined key_diainstant 461 zsto = n write * rdt463 zsto = nn_write * rdt 462 464 clop = "inst("//TRIM(clop)//")" 463 465 #else … … 465 467 clop = "ave("//TRIM(clop)//")" 466 468 #endif 467 zout = n write * rdt469 zout = nn_write * rdt 468 470 zmax = ( nitend - nit000 + 1 ) * rdt 469 471 … … 496 498 ! WRITE root name in date.file for use by postpro 497 499 IF(lwp) THEN 498 CALL dia_nam( clhstnam, n write,' ' )500 CALL dia_nam( clhstnam, nn_write,' ' ) 499 501 CALL ctl_opn( inum, 'date.file', 'REPLACE', 'FORMATTED', 'SEQUENTIAL', -1, numout, lwp, narea ) 500 502 WRITE(inum,*) clhstnam … … 504 506 ! Define the T grid FILE ( nid_T ) 505 507 506 CALL dia_nam( clhstnam, n write, 'grid_T' )508 CALL dia_nam( clhstnam, nn_write, 'grid_T' ) 507 509 IF(lwp) WRITE(numout,*) " Name of NETCDF file ", clhstnam ! filename 508 510 CALL histbeg( clhstnam, jpi, glamt, jpj, gphit, & ! Horizontal grid: glamt and gphit … … 540 542 ! Define the U grid FILE ( nid_U ) 541 543 542 CALL dia_nam( clhstnam, n write, 'grid_U' )544 CALL dia_nam( clhstnam, nn_write, 'grid_U' ) 543 545 IF(lwp) WRITE(numout,*) " Name of NETCDF file ", clhstnam ! filename 544 546 CALL histbeg( clhstnam, jpi, glamu, jpj, gphiu, & ! Horizontal grid: glamu and gphiu … … 553 555 ! Define the V grid FILE ( nid_V ) 554 556 555 CALL dia_nam( clhstnam, n write, 'grid_V' ) ! filename557 CALL dia_nam( clhstnam, nn_write, 'grid_V' ) ! filename 556 558 IF(lwp) WRITE(numout,*) " Name of NETCDF file ", clhstnam 557 559 CALL histbeg( clhstnam, jpi, glamv, jpj, gphiv, & ! Horizontal grid: glamv and gphiv … … 566 568 ! Define the W grid FILE ( nid_W ) 567 569 568 CALL dia_nam( clhstnam, n write, 'grid_W' ) ! filename570 CALL dia_nam( clhstnam, nn_write, 'grid_W' ) ! filename 569 571 IF(lwp) WRITE(numout,*) " Name of NETCDF file ", clhstnam 570 572 CALL histbeg( clhstnam, jpi, glamt, jpj, gphit, & ! Horizontal grid: glamt and gphit … … 741 743 ! donne le nombre d'elements, et ndex la liste des indices a sortir 742 744 743 IF( lwp .AND. MOD( itmod, n write ) == 0 ) THEN745 IF( lwp .AND. MOD( itmod, nn_write ) == 0 ) THEN 744 746 WRITE(numout,*) 'dia_wri : write model outputs in NetCDF files at ', kt, 'time-step' 745 747 WRITE(numout,*) '~~~~~~ ' -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/OCE/DOM/domain.F90
r11320 r11358 336 336 WRITE(numout,*) ' frequency of restart file nn_stock = ', nn_stock 337 337 ENDIF 338 #if ! defined key_iomput 338 339 WRITE(numout,*) ' frequency of output file nn_write = ', nn_write 340 #endif 339 341 WRITE(numout,*) ' mask land points ln_mskland = ', ln_mskland 340 342 WRITE(numout,*) ' additional CF standard metadata ln_cfmeta = ', ln_cfmeta … … 358 360 nleapy = nn_leapy 359 361 ninist = nn_istate 360 nstock = nn_stock361 nstocklist = nn_stocklist362 nwrite = nn_write363 362 neuler = nn_euler 364 363 IF( neuler == 1 .AND. .NOT. ln_rstart ) THEN … … 369 368 ENDIF 370 369 ! ! control of output frequency 371 IF( nstock == 0 .OR. nstock > nitend ) THEN 372 WRITE(ctmp1,*) 'nstock = ', nstock, ' it is forced to ', nitend 370 IF( .NOT. ln_rst_list ) THEN ! we use nn_stock 371 IF( nn_stock == -1 ) CALL ctl_warn( 'nn_stock = -1 --> no restart will be done' ) 372 IF( nn_stock == 0 .OR. nn_stock > nitend ) THEN 373 WRITE(ctmp1,*) 'nn_stock = ', nn_stock, ' it is forced to ', nitend 374 CALL ctl_warn( ctmp1 ) 375 nn_stock = nitend 376 ENDIF 377 ENDIF 378 #if ! defined key_iomput 379 IF( nn_write == -1 ) CALL ctl_warn( 'nn_write = -1 --> no output files will be done' ) 380 IF ( nn_write == 0 ) THEN 381 WRITE(ctmp1,*) 'nn_write = ', nn_write, ' it is forced to ', nitend 373 382 CALL ctl_warn( ctmp1 ) 374 nstock = nitend 375 ENDIF 376 IF ( nwrite == 0 ) THEN 377 WRITE(ctmp1,*) 'nwrite = ', nwrite, ' it is forced to ', nitend 378 CALL ctl_warn( ctmp1 ) 379 nwrite = nitend 380 ENDIF 383 nn_write = nitend 384 ENDIF 385 #endif 381 386 382 387 #if defined key_agrif -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/OCE/IOM/in_out_manager.F90
r11317 r11358 80 80 INTEGER :: nleapy !: Leap year calendar flag (0/1 or 30) 81 81 INTEGER :: ninist !: initial state output flag (0/1) 82 INTEGER :: nwrite !: model standard output frequency83 INTEGER :: nstock !: restart file frequency84 INTEGER, DIMENSION(10) :: nstocklist !: restart dump times85 82 86 83 !!---------------------------------------------------------------------- -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/OCE/IOM/restart.F90
r10425 r11358 70 70 IF( ln_rst_list ) THEN 71 71 nrst_lst = 1 72 nitrst = n stocklist( nrst_lst )72 nitrst = nn_stocklist( nrst_lst ) 73 73 ELSE 74 74 nitrst = nitend 75 75 ENDIF 76 76 ENDIF 77 78 IF( .NOT. ln_rst_list .AND. nn_stock == -1 ) RETURN ! we will never do any restart 77 79 78 80 ! frequency-based restart dumping (nn_stock) 79 IF( .NOT. ln_rst_list .AND. MOD( kt - 1, n stock ) == 0 ) THEN81 IF( .NOT. ln_rst_list .AND. MOD( kt - 1, nn_stock ) == 0 ) THEN 80 82 ! we use kt - 1 and not kt - nit000 to keep the same periodicity from the beginning of the experiment 81 nitrst = kt + n stock - 1 ! define the next value of nitrst for restart writing83 nitrst = kt + nn_stock - 1 ! define the next value of nitrst for restart writing 82 84 IF( nitrst > nitend ) nitrst = nitend ! make sure we write a restart at the end of the run 83 85 ENDIF … … 85 87 ! we open and define the ocean restart file one time step before writing the data (-> at nitrst - 1) 86 88 ! except if we write ocean restart files every time step or if an ocean restart file was writen at nitend - 1 87 IF( kt == nitrst - 1 .OR. n stock == 1 .OR. ( kt == nitend .AND. .NOT. lrst_oce ) ) THEN89 IF( kt == nitrst - 1 .OR. nn_stock == 1 .OR. ( kt == nitend .AND. .NOT. lrst_oce ) ) THEN 88 90 IF( nitrst <= nitend .AND. nitrst > 0 ) THEN 89 91 ! beware of the format used to write kt (default is i8.8, that should be large enough...) … … 184 186 lrst_oce = .FALSE. 185 187 IF( ln_rst_list ) THEN 186 nrst_lst = MIN(nrst_lst + 1, SIZE(n stocklist,1))187 nitrst = n stocklist( nrst_lst )188 nrst_lst = MIN(nrst_lst + 1, SIZE(nn_stocklist,1)) 189 nitrst = nn_stocklist( nrst_lst ) 188 190 ENDIF 189 191 ENDIF -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/OCE/SBC/sbcmod.F90
r11317 r11358 307 307 ! 308 308 ! !* check consistency between model timeline and nn_fsbc 309 IF( MOD( nitend - nit000 + 1, nn_fsbc) /= 0 .OR. & 310 MOD( nstock , nn_fsbc) /= 0 ) THEN 311 WRITE(ctmp1,*) 'sbc_init : experiment length (', nitend - nit000 + 1, ') or nstock (', nstock, & 312 & ' is NOT a multiple of nn_fsbc (', nn_fsbc, ')' 313 CALL ctl_stop( ctmp1, 'Impossible to properly do model restart' ) 309 IF( ln_rst_list .OR. nn_stock /= -1 ) THEN ! we will do restart files 310 IF( MOD( nitend - nit000 + 1, nn_fsbc) /= 0 ) THEN 311 WRITE(ctmp1,*) 'sbc_init : experiment length (', nitend - nit000 + 1, ') is NOT a multiple of nn_fsbc (', nn_fsbc, ')' 312 CALL ctl_stop( ctmp1, 'Impossible to properly do model restart' ) 313 ENDIF 314 IF( .NOT. ln_rst_list .AND. MOD( nn_stock, nn_fsbc) /= 0 ) THEN ! we don't use nn_stock if ln_rst_list 315 WRITE(ctmp1,*) 'sbc_init : nn_stock (', nn_stock, ') is NOT a multiple of nn_fsbc (', nn_fsbc, ')' 316 CALL ctl_stop( ctmp1, 'Impossible to properly do model restart' ) 317 ENDIF 314 318 ENDIF 315 319 ! -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/OCE/STO/stopar.F90
r11353 r11358 750 750 CHARACTER(LEN=9) :: clsto3d='sto3d_000' ! stochastic parameter variable name 751 751 CHARACTER(LEN=10) :: clseed='seed0_0000' ! seed variable name 752 752 !!---------------------------------------------------------------------- 753 754 IF( .NOT. ln_rst_list .AND. nn_stock == -1 ) RETURN ! we will never do any restart 755 753 756 IF ( jpsto2d > 0 .OR. jpsto3d > 0 ) THEN 754 757 … … 790 793 ! Open the restart file one timestep before writing restart 791 794 IF( kt < nitend) THEN 792 IF( kt == nitrst - 1 .OR. n stock == 1 .OR. kt == nitend-1 ) THEN795 IF( kt == nitrst - 1 .OR. nn_stock == 1 .OR. kt == nitend-1 ) THEN 793 796 ! create the filename 794 797 IF( nitrst > 999999999 ) THEN ; WRITE(clkt, * ) nitrst -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/OCE/TRD/trdmxl_rst.F90
r10425 r11358 47 47 !!-------------------------------------------------------------------------------- 48 48 49 IF( .NOT. ln_rst_list .AND. nn_stock == -1 ) RETURN ! we will never do any restart 50 49 51 ! to get better performances with NetCDF format: 50 52 ! we open and define the ocean restart_mxl file one time step before writing the data (-> at nitrst - 1) 51 53 ! except if we write ocean restart_mxl files every time step or if an ocean restart_mxl file was writen at nitend - 1 52 IF( kt == nitrst - 1 .OR. n stock == 1 .OR. ( kt == nitend .AND. MOD( nitend - 1, nstock ) == 0 ) ) THEN54 IF( kt == nitrst - 1 .OR. nn_stock == 1 .OR. ( kt == nitend .AND. MOD( nitend - 1, nn_stock ) == 0 ) ) THEN 53 55 ! beware of the format used to write kt (default is i8.8, that should be large enough...) 54 56 IF( nitrst > 999999999 ) THEN ; WRITE(clkt, * ) nitrst -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/OCE/TRD/trdvor.F90
r10425 r11358 46 46 REAL(wp), SAVE, ALLOCATABLE, DIMENSION(:,:) :: vor_avr ! average 47 47 REAL(wp), SAVE, ALLOCATABLE, DIMENSION(:,:) :: vor_avrb ! before vorticity (kt-1) 48 REAL(wp), SAVE, ALLOCATABLE, DIMENSION(:,:) :: vor_avrbb ! vorticity at begining of the n write-1 timestep averaging period48 REAL(wp), SAVE, ALLOCATABLE, DIMENSION(:,:) :: vor_avrbb ! vorticity at begining of the nn_write-1 timestep averaging period 49 49 REAL(wp), SAVE, ALLOCATABLE, DIMENSION(:,:) :: vor_avrbn ! after vorticity at time step after the 50 REAL(wp), SAVE, ALLOCATABLE, DIMENSION(:,:) :: rotot ! begining of the N WRITE-1 timesteps50 REAL(wp), SAVE, ALLOCATABLE, DIMENSION(:,:) :: rotot ! begining of the NN_WRITE-1 timesteps 51 51 REAL(wp), SAVE, ALLOCATABLE, DIMENSION(:,:) :: vor_avrtot ! 52 52 REAL(wp), SAVE, ALLOCATABLE, DIMENSION(:,:) :: vor_avrres ! … … 129 129 !! from ocean surface down to control surface (NetCDF output) 130 130 !! 131 !! ** Method/usage : integration done over n write-1 time steps131 !! ** Method/usage : integration done over nn_write-1 time steps 132 132 !! 133 133 !! ** Action : trends : … … 143 143 !! vortrd (,,10) = forcing term 144 144 !! vortrd (,,11) = bottom friction term 145 !! rotot(,) : total cumulative trends over n write-1 time steps145 !! rotot(,) : total cumulative trends over nn_write-1 time steps 146 146 !! vor_avrtot(,) : first membre of vrticity equation 147 147 !! vor_avrres(,) : residual = dh/dt entrainment … … 214 214 !! from ocean surface down to control surface (NetCDF output) 215 215 !! 216 !! ** Method/usage : integration done over n write-1 time steps216 !! ** Method/usage : integration done over nn_write-1 time steps 217 217 !! 218 218 !! ** Action : trends : … … 228 228 !! vortrd (,,10) = forcing term 229 229 !! vortrd (,,11) = bottom friction term 230 !! rotot(,) : total cumulative trends over n write-1 time steps230 !! rotot(,) : total cumulative trends over nn_write-1 time steps 231 231 !! vor_avrtot(,) : first membre of vrticity equation 232 232 !! vor_avrres(,) : residual = dh/dt entrainment … … 360 360 ENDIF 361 361 362 ! II.2 cumulated trends over analysis period (kt=2 to n write)362 ! II.2 cumulated trends over analysis period (kt=2 to nn_write) 363 363 ! ---------------------- 364 ! trends cumulated over n write-2 time steps364 ! trends cumulated over nn_write-2 time steps 365 365 366 366 IF( kt >= nit000+2 ) THEN … … 376 376 ! III. Output in netCDF + residual computation 377 377 ! ============================================= 378 378 379 379 ! define time axis 380 380 it = kt … … 504 504 ENDIF 505 505 #if defined key_diainstant 506 zsto = n write*rdt506 zsto = nn_write*rdt 507 507 clop = "inst("//TRIM(clop)//")" 508 508 #else -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/SAS/diawri.F90
r10425 r11358 125 125 !! define all the NETCDF files and fields 126 126 !! At each time step call histdef to compute the mean if ncessary 127 !! Each n write time step, output the instantaneous or mean fields127 !! Each nn_write time step, output the instantaneous or mean fields 128 128 !!---------------------------------------------------------------------- 129 129 !! … … 138 138 REAL(wp) :: zsto, zout, zmax, zjulian ! local scalars 139 139 !!---------------------------------------------------------------------- 140 !141 IF( ln_timing ) CALL timing_start('dia_wri')142 140 ! 143 141 ! Output the initial state and forcings … … 147 145 ENDIF 148 146 ! 147 IF( nn_write == -1 ) RETURN ! we will never do any output 148 ! 149 IF( ln_timing ) CALL timing_start('dia_wri') 150 ! 149 151 ! 0. Initialisation 150 152 ! ----------------- … … 159 161 ENDIF 160 162 #if defined key_diainstant 161 zsto = n write * rdt163 zsto = nn_write * rdt 162 164 clop = "inst("//TRIM(clop)//")" 163 165 #else … … 165 167 clop = "ave("//TRIM(clop)//")" 166 168 #endif 167 zout = n write * rdt169 zout = nn_write * rdt 168 170 zmax = ( nitend - nit000 + 1 ) * rdt 169 171 … … 196 198 ! WRITE root name in date.file for use by postpro 197 199 IF(lwp) THEN 198 CALL dia_nam( clhstnam, n write,' ' )200 CALL dia_nam( clhstnam, nn_write,' ' ) 199 201 CALL ctl_opn( inum, 'date.file', 'REPLACE', 'FORMATTED', 'SEQUENTIAL', -1, numout, lwp, narea ) 200 202 WRITE(inum,*) clhstnam … … 204 206 ! Define the T grid FILE ( nid_T ) 205 207 206 CALL dia_nam( clhstnam, n write, 'grid_T' )208 CALL dia_nam( clhstnam, nn_write, 'grid_T' ) 207 209 IF(lwp) WRITE(numout,*) " Name of NETCDF file ", clhstnam ! filename 208 210 CALL histbeg( clhstnam, jpi, glamt, jpj, gphit, & ! Horizontal grid: glamt and gphit … … 216 218 ! Define the U grid FILE ( nid_U ) 217 219 218 CALL dia_nam( clhstnam, n write, 'grid_U' )220 CALL dia_nam( clhstnam, nn_write, 'grid_U' ) 219 221 IF(lwp) WRITE(numout,*) " Name of NETCDF file ", clhstnam ! filename 220 222 CALL histbeg( clhstnam, jpi, glamu, jpj, gphiu, & ! Horizontal grid: glamu and gphiu … … 228 230 ! Define the V grid FILE ( nid_V ) 229 231 230 CALL dia_nam( clhstnam, n write, 'grid_V' ) ! filename232 CALL dia_nam( clhstnam, nn_write, 'grid_V' ) ! filename 231 233 IF(lwp) WRITE(numout,*) " Name of NETCDF file ", clhstnam 232 234 CALL histbeg( clhstnam, jpi, glamv, jpj, gphiv, & ! Horizontal grid: glamv and gphiv … … 291 293 ! donne le nombre d'elements, et ndex la liste des indices a sortir 292 294 293 IF( lwp .AND. MOD( itmod, n write ) == 0 ) THEN295 IF( lwp .AND. MOD( itmod, nn_write ) == 0 ) THEN 294 296 WRITE(numout,*) 'dia_wri : write model outputs in NetCDF files at ', kt, 'time-step' 295 297 WRITE(numout,*) '~~~~~~ ' -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/TOP/PISCES/SED/sedrst.F90
r10425 r11358 49 49 IF( ln_rst_list ) THEN 50 50 nrst_lst = 1 51 nitrst = n stocklist( nrst_lst )51 nitrst = nn_stocklist( nrst_lst ) 52 52 ELSE 53 53 nitrst = nitend 54 54 ENDIF 55 55 ENDIF 56 IF( .NOT. ln_rst_list .AND. MOD( kt - 1, n stock ) == 0 ) THEN56 IF( .NOT. ln_rst_list .AND. MOD( kt - 1, nn_stock ) == 0 ) THEN 57 57 ! we use kt - 1 and not kt - nittrc000 to keep the same periodicity from the beginning of the experiment 58 nitrst = kt + n stock - 1 ! define the next value of nitrst for restart writing58 nitrst = kt + nn_stock - 1 ! define the next value of nitrst for restart writing 59 59 IF( nitrst > nitend ) nitrst = nitend ! make sure we write a restart at the end of the run 60 60 ENDIF … … 62 62 IF( kt == nittrc000 ) lrst_sed = .FALSE. 63 63 ENDIF 64 65 IF( .NOT. ln_rst_list .AND. nn_stock == -1 ) RETURN ! we will never do any restart 64 66 65 67 ! to get better performances with NetCDF format: 66 68 ! we open and define the tracer restart file one tracer time step before writing the data (-> at nitrst - 2*nn_dttrc + 1) 67 69 ! except if we write tracer restart files every tracer time step or if a tracer restart file was writen at nitend - 2*nn_dttrc + 1 68 IF( kt == nitrst - 2*nn_dtsed .OR. n stock == nn_dtsed .OR. ( kt == nitend - nn_dtsed .AND. .NOT. lrst_sed ) ) THEN70 IF( kt == nitrst - 2*nn_dtsed .OR. nn_stock == nn_dtsed .OR. ( kt == nitend - nn_dtsed .AND. .NOT. lrst_sed ) ) THEN 69 71 ! beware of the format used to write kt (default is i8.8, that should be large enough) 70 72 IF( nitrst > 1.0e9 ) THEN ; WRITE(clkt,* ) nitrst … … 300 302 IF( l_offline .AND. ln_rst_list ) THEN 301 303 nrst_lst = nrst_lst + 1 302 nitrst = n stocklist( nrst_lst )304 nitrst = nn_stocklist( nrst_lst ) 303 305 ENDIF 304 306 ENDIF -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/TOP/trcrst.F90
r10425 r11358 58 58 IF( ln_rst_list ) THEN 59 59 nrst_lst = 1 60 nitrst = n stocklist( nrst_lst )60 nitrst = nn_stocklist( nrst_lst ) 61 61 ELSE 62 62 nitrst = nitend … … 64 64 ENDIF 65 65 66 IF( .NOT. ln_rst_list .AND. MOD( kt - 1, n stock ) == 0 ) THEN66 IF( .NOT. ln_rst_list .AND. MOD( kt - 1, nn_stock ) == 0 ) THEN 67 67 ! we use kt - 1 and not kt - nittrc000 to keep the same periodicity from the beginning of the experiment 68 nitrst = kt + n stock - 1 ! define the next value of nitrst for restart writing68 nitrst = kt + nn_stock - 1 ! define the next value of nitrst for restart writing 69 69 IF( nitrst > nitend ) nitrst = nitend ! make sure we write a restart at the end of the run 70 70 ENDIF … … 72 72 IF( kt == nittrc000 ) lrst_trc = .FALSE. 73 73 ENDIF 74 75 IF( .NOT. ln_rst_list .AND. nn_stock == -1 ) RETURN ! we will never do any restart 74 76 75 77 ! to get better performances with NetCDF format: 76 78 ! we open and define the tracer restart file one tracer time step before writing the data (-> at nitrst - 2*nn_dttrc + 1) 77 79 ! except if we write tracer restart files every tracer time step or if a tracer restart file was writen at nitend - 2*nn_dttrc + 1 78 IF( kt == nitrst - 2*nn_dttrc .OR. n stock == nn_dttrc .OR. ( kt == nitend - nn_dttrc .AND. .NOT. lrst_trc ) ) THEN80 IF( kt == nitrst - 2*nn_dttrc .OR. nn_stock == nn_dttrc .OR. ( kt == nitend - nn_dttrc .AND. .NOT. lrst_trc ) ) THEN 79 81 ! beware of the format used to write kt (default is i8.8, that should be large enough) 80 82 IF( nitrst > 1.0e9 ) THEN ; WRITE(clkt,* ) nitrst … … 153 155 IF( l_offline .AND. ln_rst_list ) THEN 154 156 nrst_lst = nrst_lst + 1 155 nitrst = n stocklist( nrst_lst )157 nitrst = nn_stocklist( nrst_lst ) 156 158 ENDIF 157 159 ENDIF -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/tests/BENCH/EXPREF/namelist_cfg_orca025_like
r10539 r11358 9 9 nn_it000 = 1 ! first time step 10 10 nn_itend = 1000 ! last time step 11 nn_stock = 0! frequency of creation of a restart file (modulo referenced to 1)12 nn_write = 0! frequency of write in the output file (modulo referenced to nn_it000)11 nn_stock = -1 ! frequency of creation of a restart file (modulo referenced to 1) 12 nn_write = -1 ! frequency of write in the output file (modulo referenced to nn_it000) 13 13 / 14 14 !----------------------------------------------------------------------- -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/tests/BENCH/EXPREF/namelist_cfg_orca12_like
r10539 r11358 9 9 nn_it000 = 1 ! first time step 10 10 nn_itend = 1000 ! last time step 11 nn_stock = 0! frequency of creation of a restart file (modulo referenced to 1)12 nn_write = 0! frequency of write in the output file (modulo referenced to nn_it000)11 nn_stock = -1 ! frequency of creation of a restart file (modulo referenced to 1) 12 nn_write = -1 ! frequency of write in the output file (modulo referenced to nn_it000) 13 13 / 14 14 !----------------------------------------------------------------------- -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/tests/BENCH/EXPREF/namelist_cfg_orca1_like
r10539 r11358 9 9 nn_it000 = 1 ! first time step 10 10 nn_itend = 1000 ! last time step 11 nn_stock = 0! frequency of creation of a restart file (modulo referenced to 1)12 nn_write = 0! frequency of write in the output file (modulo referenced to nn_it000)11 nn_stock = -1 ! frequency of creation of a restart file (modulo referenced to 1) 12 nn_write = -1 ! frequency of write in the output file (modulo referenced to nn_it000) 13 13 / 14 14 !----------------------------------------------------------------------- -
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/tests/CANAL/MY_SRC/diawri.F90
r10425 r11358 531 531 !! define all the NETCDF files and fields 532 532 !! At each time step call histdef to compute the mean if ncessary 533 !! Each n write time step, output the instantaneous or mean fields533 !! Each nn_write time step, output the instantaneous or mean fields 534 534 !!---------------------------------------------------------------------- 535 535 INTEGER, INTENT( in ) :: kt ! ocean time-step index … … 547 547 REAL(wp), DIMENSION(jpi,jpj,jpk) :: zw3d ! 3D workspace 548 548 !!---------------------------------------------------------------------- 549 !550 IF( ln_timing ) CALL timing_start('dia_wri')551 549 ! 552 550 IF( ninist == 1 ) THEN !== Output the initial state and forcings ==! … … 555 553 ENDIF 556 554 ! 555 IF( nn_write == -1 ) RETURN ! we will never do any output 556 ! 557 IF( ln_timing ) CALL timing_start('dia_wri') 558 ! 557 559 ! 0. Initialisation 558 560 ! ----------------- … … 564 566 clop = "x" ! no use of the mask value (require less cpu time and otherwise the model crashes) 565 567 #if defined key_diainstant 566 zsto = n write * rdt568 zsto = nn_write * rdt 567 569 clop = "inst("//TRIM(clop)//")" 568 570 #else … … 570 572 clop = "ave("//TRIM(clop)//")" 571 573 #endif 572 zout = n write * rdt574 zout = nn_write * rdt 573 575 zmax = ( nitend - nit000 + 1 ) * rdt 574 576 … … 601 603 ! WRITE root name in date.file for use by postpro 602 604 IF(lwp) THEN 603 CALL dia_nam( clhstnam, n write,' ' )605 CALL dia_nam( clhstnam, nn_write,' ' ) 604 606 CALL ctl_opn( inum, 'date.file', 'REPLACE', 'FORMATTED', 'SEQUENTIAL', -1, numout, lwp, narea ) 605 607 WRITE(inum,*) clhstnam … … 609 611 ! Define the T grid FILE ( nid_T ) 610 612 611 CALL dia_nam( clhstnam, n write, 'grid_T' )613 CALL dia_nam( clhstnam, nn_write, 'grid_T' ) 612 614 IF(lwp) WRITE(numout,*) " Name of NETCDF file ", clhstnam ! filename 613 615 CALL histbeg( clhstnam, jpi, glamt, jpj, gphit, & ! Horizontal grid: glamt and gphit … … 645 647 ! Define the U grid FILE ( nid_U ) 646 648 647 CALL dia_nam( clhstnam, n write, 'grid_U' )649 CALL dia_nam( clhstnam, nn_write, 'grid_U' ) 648 650 IF(lwp) WRITE(numout,*) " Name of NETCDF file ", clhstnam ! filename 649 651 CALL histbeg( clhstnam, jpi, glamu, jpj, gphiu, & ! Horizontal grid: glamu and gphiu … … 658 660 ! Define the V grid FILE ( nid_V ) 659 661 660 CALL dia_nam( clhstnam, n write, 'grid_V' ) ! filename662 CALL dia_nam( clhstnam, nn_write, 'grid_V' ) ! filename 661 663 IF(lwp) WRITE(numout,*) " Name of NETCDF file ", clhstnam 662 664 CALL histbeg( clhstnam, jpi, glamv, jpj, gphiv, & ! Horizontal grid: glamv and gphiv … … 671 673 ! Define the W grid FILE ( nid_W ) 672 674 673 CALL dia_nam( clhstnam, n write, 'grid_W' ) ! filename675 CALL dia_nam( clhstnam, nn_write, 'grid_W' ) ! filename 674 676 IF(lwp) WRITE(numout,*) " Name of NETCDF file ", clhstnam 675 677 CALL histbeg( clhstnam, jpi, glamt, jpj, gphit, & ! Horizontal grid: glamt and gphit … … 762 764 ENDIF 763 765 764 IF( .NOT. ln_cpl) THEN766 IF( ln_ssr ) THEN 765 767 CALL histdef( nid_T, "sohefldp", "Surface Heat Flux: Damping" , "W/m2" , & ! qrp 766 768 & jpi, jpj, nh_T, 1 , 1, 1 , -99 , 32, clop, zsto, zout ) … … 770 772 & jpi, jpj, nh_T, 1 , 1, 1 , -99 , 32, clop, zsto, zout ) 771 773 ENDIF 772 773 IF( ln_cpl .AND. nn_ice <= 1 ) THEN 774 CALL histdef( nid_T, "sohefldp", "Surface Heat Flux: Damping" , "W/m2" , & ! qrp 775 & jpi, jpj, nh_T, 1 , 1, 1 , -99 , 32, clop, zsto, zout ) 776 CALL histdef( nid_T, "sowafldp", "Surface Water Flux: Damping" , "Kg/m2/s", & ! erp 777 & jpi, jpj, nh_T, 1 , 1, 1 , -99 , 32, clop, zsto, zout ) 778 CALL histdef( nid_T, "sosafldp", "Surface salt flux: Damping" , "Kg/m2/s", & ! erp * sn 779 & jpi, jpj, nh_T, 1 , 1, 1 , -99 , 32, clop, zsto, zout ) 780 ENDIF 781 774 782 775 clmx ="l_max(only(x))" ! max index on a period 783 776 ! CALL histdef( nid_T, "sobowlin", "Bowl Index" , "W-point", & ! bowl INDEX … … 855 848 ! donne le nombre d'elements, et ndex la liste des indices a sortir 856 849 857 IF( lwp .AND. MOD( itmod, n write ) == 0 ) THEN850 IF( lwp .AND. MOD( itmod, nn_write ) == 0 ) THEN 858 851 WRITE(numout,*) 'dia_wri : write model outputs in NetCDF files at ', kt, 'time-step' 859 852 WRITE(numout,*) '~~~~~~ ' … … 919 912 ENDIF 920 913 921 IF( .NOT. ln_cpl) THEN914 IF( ln_ssr ) THEN 922 915 CALL histwrite( nid_T, "sohefldp", it, qrp , ndim_hT, ndex_hT ) ! heat flux damping 923 916 CALL histwrite( nid_T, "sowafldp", it, erp , ndim_hT, ndex_hT ) ! freshwater flux damping 924 IF( ln_ssr ) zw2d(:,:) = erp(:,:) * tsn(:,:,1,jp_sal) * tmask(:,:,1) 925 CALL histwrite( nid_T, "sosafldp", it, zw2d , ndim_hT, ndex_hT ) ! salt flux damping 926 ENDIF 927 IF( ln_cpl .AND. nn_ice <= 1 ) THEN 928 CALL histwrite( nid_T, "sohefldp", it, qrp , ndim_hT, ndex_hT ) ! heat flux damping 929 CALL histwrite( nid_T, "sowafldp", it, erp , ndim_hT, ndex_hT ) ! freshwater flux damping 930 IF( ln_ssr ) zw2d(:,:) = erp(:,:) * tsn(:,:,1,jp_sal) * tmask(:,:,1) 917 zw2d(:,:) = erp(:,:) * tsn(:,:,1,jp_sal) * tmask(:,:,1) 931 918 CALL histwrite( nid_T, "sosafldp", it, zw2d , ndim_hT, ndex_hT ) ! salt flux damping 932 919 ENDIF
Note: See TracChangeset
for help on using the changeset viewer.