Changeset 4147 for branches/2013/dev_LOCEAN_2013/NEMOGCM/NEMO/OFF_SRC
- Timestamp:
- 2013-11-04T12:51:55+01:00 (11 years ago)
- Location:
- branches/2013/dev_LOCEAN_2013/NEMOGCM/NEMO/OFF_SRC
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2013/dev_LOCEAN_2013/NEMOGCM/NEMO/OFF_SRC/domain.F90
r3632 r4147 88 88 !!---------------------------------------------------------------------- 89 89 USE ioipsl 90 INTEGER :: ios ! Local integer output status for namelist read 90 91 NAMELIST/namrun/ nn_no , cn_exp , cn_ocerst_in, cn_ocerst_out, ln_rstart , nn_rstctl, & 91 92 & nn_it000, nn_itend , nn_date0 , nn_leapy , nn_istate , nn_stock , & 92 93 & nn_write, ln_dimgnnn, ln_mskland , ln_clobber , nn_chunksz 93 NAMELIST/namdom/ nn_bathy , rn_e3zps_min, rn_e3zps_rat, nn_msh , rn_hmin, & 94 & nn_acc , rn_atfp , rn_rdt , rn_rdtmin , & 95 & rn_rdtmax, rn_rdth , nn_baro , nn_closea 94 NAMELIST/namdom/ nn_bathy , rn_e3zps_min, rn_e3zps_rat, nn_msh , rn_hmin, & 95 & nn_acc , rn_atfp , rn_rdt , rn_rdtmin , & 96 & rn_rdtmax, rn_rdth , nn_baro , nn_closea , & 97 & jphgr_msh, & 98 & ppglam0, ppgphi0, ppe1_deg, ppe2_deg, ppe1_m, ppe2_m, & 99 & ppsur, ppa0, ppa1, ppkth, ppacr, ppdzmin, pphmax, ldbletanh, & 100 & ppa2, ppkth2, ppacr2 96 101 NAMELIST/namcla/ nn_cla 97 102 #if defined key_netcdf4 … … 100 105 !!---------------------------------------------------------------------- 101 106 102 REWIND( numnam ) ! Namelist namrun : parameters of the run 103 READ ( numnam, namrun ) 107 REWIND( numnam_ref ) ! Namelist namrun in reference namelist : Parameters of the run 108 READ ( numnam_ref, namrun, IOSTAT = ios, ERR = 901) 109 901 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namrun in reference namelist', lwp ) 110 111 REWIND( numnam_cfg ) ! Namelist namrun in configuration namelist : Parameters of the run 112 READ ( numnam_cfg, namrun, IOSTAT = ios, ERR = 902 ) 113 902 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namrun in configuration namelist', lwp ) 114 WRITE ( numond, namrun ) 104 115 ! 105 116 IF(lwp) THEN ! control print … … 170 181 #endif 171 182 172 REWIND( numnam ) ! Domain 173 READ ( numnam, namdom ) 183 REWIND( numnam_ref ) ! Namelist namdom in reference namelist : space & time domain (bathymetry, mesh, timestep) 184 READ ( numnam_ref, namdom, IOSTAT = ios, ERR = 903) 185 903 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namdom in reference namelist', lwp ) 186 187 REWIND( numnam_cfg ) ! Namelist namdom in configuration namelist : space & time domain (bathymetry, mesh, timestep) 188 READ ( numnam_cfg, namdom, IOSTAT = ios, ERR = 904 ) 189 904 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namdom in configuration namelist', lwp ) 190 WRITE ( numond, namdom ) 174 191 175 192 IF(lwp) THEN … … 193 210 WRITE(numout,*) ' depth of transition rn_rdth = ', rn_rdth 194 211 WRITE(numout,*) ' suppression of closed seas (=0) nn_closea = ', nn_closea 212 WRITE(numout,*) ' type of horizontal mesh jphgr_msh = ', jphgr_msh 213 WRITE(numout,*) ' longitude of first raw and column T-point ppglam0 = ', ppglam0 214 WRITE(numout,*) ' latitude of first raw and column T-point ppgphi0 = ', ppgphi0 215 WRITE(numout,*) ' zonal grid-spacing (degrees) ppe1_deg = ', ppe1_deg 216 WRITE(numout,*) ' meridional grid-spacing (degrees) ppe2_deg = ', ppe2_deg 217 WRITE(numout,*) ' zonal grid-spacing (degrees) ppe1_m = ', ppe1_m 218 WRITE(numout,*) ' meridional grid-spacing (degrees) ppe2_m = ', ppe2_m 219 WRITE(numout,*) ' ORCA r4, r2 and r05 coefficients ppsur = ', ppsur 220 WRITE(numout,*) ' ppa0 = ', ppa0 221 WRITE(numout,*) ' ppa1 = ', ppa1 222 WRITE(numout,*) ' ppkth = ', ppkth 223 WRITE(numout,*) ' ppacr = ', ppacr 224 WRITE(numout,*) ' Minimum vertical spacing ppdzmin = ', ppdzmin 225 WRITE(numout,*) ' Maximum depth pphmax = ', pphmax 226 WRITE(numout,*) ' Use double tanf function for vertical coordinates ldbletanh = ', ldbletanh 227 WRITE(numout,*) ' Double tanh function parameters ppa2 = ', ppa2 228 WRITE(numout,*) ' ppkth2 = ', ppkth2 229 WRITE(numout,*) ' ppacr2 = ', ppacr2 195 230 ENDIF 196 231 … … 206 241 rdth = rn_rdth 207 242 208 REWIND( numnam ) ! Namelist cross land advection 209 READ ( numnam, namcla ) 243 REWIND( numnam_ref ) ! Namelist namcla in reference namelist : Cross land advection 244 READ ( numnam_ref, namcla, IOSTAT = ios, ERR = 905) 245 905 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namcla in reference namelist', lwp ) 246 247 REWIND( numnam_cfg ) ! Namelist namcla in configuration namelist : Cross land advection 248 READ ( numnam_cfg, namcla, IOSTAT = ios, ERR = 906 ) 249 906 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namcla in configuration namelist', lwp ) 250 WRITE( numond, namcla ) 251 210 252 IF(lwp) THEN 211 253 WRITE(numout,*) … … 216 258 #if defined key_netcdf4 217 259 ! ! NetCDF 4 case ("key_netcdf4" defined) 218 REWIND( numnam ) ! Namelist namnc4 : netcdf4 chunking parameters 219 READ ( numnam, namnc4 ) 260 REWIND( numnam_ref ) ! Namelist namnc4 in reference namelist : NETCDF 261 READ ( numnam_ref, namnc4, IOSTAT = ios, ERR = 907) 262 907 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namnc4 in reference namelist', lwp ) 263 264 REWIND( numnam_cfg ) ! Namelist namnc4 in configuration namelist : NETCDF 265 READ ( numnam_cfg, namnc4, IOSTAT = ios, ERR = 908 ) 266 908 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namnc4 in configuration namelist', lwp ) 267 WRITE( numond, namnc4 ) 220 268 IF(lwp) THEN ! control print 221 269 WRITE(numout,*) … … 257 305 !!---------------------------------------------------------------------- 258 306 INTEGER :: ioptio = 0 ! temporary integer 307 INTEGER :: ios 259 308 !! 260 309 NAMELIST/namzgr/ ln_zco, ln_zps, ln_sco 261 310 !!---------------------------------------------------------------------- 262 311 263 REWIND ( numnam ) ! Read Namelist namzgr : vertical coordinate' 264 READ ( numnam, namzgr ) 312 REWIND( numnam_ref ) ! Namelist namzgr in reference namelist : Vertical coordinate 313 READ ( numnam_ref, namzgr, IOSTAT = ios, ERR = 901 ) 314 901 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namzgr in reference namelist', lwp ) 315 316 REWIND( numnam_cfg ) ! Namelist namzgr in configuration namelist : Vertical coordinate 317 READ ( numnam_cfg, namzgr, IOSTAT = ios, ERR = 902 ) 318 902 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namzgr in configuration namelist', lwp ) 319 WRITE ( numond, namzgr ) 265 320 266 321 IF(lwp) THEN ! Control print -
branches/2013/dev_LOCEAN_2013/NEMOGCM/NEMO/OFF_SRC/dtadyn.F90
r3827 r4147 47 47 PUBLIC dta_dyn ! called by step.F90 48 48 49 CHARACTER(len=100) :: cn_dir = './'!: Root directory for location of ssr files50 LOGICAL :: ln_dynwzv = .true.!: vertical velocity read in a file (T) or computed from u/v (F)51 LOGICAL :: ln_dynbbl = .true.!: bbl coef read in a file (T) or computed (F)52 LOGICAL :: ln_degrad = .false.!: degradation option enabled or not49 CHARACTER(len=100) :: cn_dir !: Root directory for location of ssr files 50 LOGICAL :: ln_dynwzv !: vertical velocity read in a file (T) or computed from u/v (F) 51 LOGICAL :: ln_dynbbl !: bbl coef read in a file (T) or computed (F) 52 LOGICAL :: ln_degrad !: degradation option enabled or not 53 53 54 54 INTEGER , PARAMETER :: jpfld = 20 ! maximum number of fields to read … … 326 326 INTEGER :: jfld ! dummy loop arguments 327 327 INTEGER :: inum, idv, idimv ! local integer 328 INTEGER :: ios ! Local integer output status for namelist read 328 329 !! 329 330 CHARACTER(len=100) :: cn_dir ! Root directory for location of core files … … 337 338 & sn_uwd, sn_vwd, sn_wwd, sn_avt, sn_ubl, sn_vbl, & 338 339 & sn_ahu, sn_ahv, sn_ahw, sn_eiu, sn_eiv, sn_eiw, sn_sfx 339 340 !!---------------------------------------------------------------------- 341 ! ! ============ 342 ! ! Namelist 343 ! ! ============ 344 ! (NB: frequency positive => hours, negative => months) 345 ! ! file ! frequency ! variable ! time intep ! clim ! 'yearly' or ! weights ! rotation ! 346 ! ! name ! (hours) ! name ! (T/F) ! (T/F) ! 'monthly' ! filename ! pairs ! 347 sn_tem = FLD_N( 'dyna_grid_T' , 120 , 'votemper' , .true. , .true. , 'yearly' , '' , '' ) 348 sn_sal = FLD_N( 'dyna_grid_T' , 120 , 'vosaline' , .true. , .true. , 'yearly' , '' , '' ) 349 sn_mld = FLD_N( 'dyna_grid_T' , 120 , 'somixght' , .true. , .true. , 'yearly' , '' , '' ) 350 sn_emp = FLD_N( 'dyna_grid_T' , 120 , 'sowaflup' , .true. , .true. , 'yearly' , '' , '' ) 351 sn_sfx = FLD_N( 'dyna_grid_T' , 120 , 'sowaflcd' , .true. , .true. , 'yearly' , '' , '' ) 352 !! sn_sfx = FLD_N( 'dyna_grid_T' , 120 , 'sosfldow' , .true. , .true. , 'yearly' , '' , '' ) ! v3.5+ 353 sn_ice = FLD_N( 'dyna_grid_T' , 120 , 'soicecov' , .true. , .true. , 'yearly' , '' , '' ) 354 sn_qsr = FLD_N( 'dyna_grid_T' , 120 , 'soshfldo' , .true. , .true. , 'yearly' , '' , '' ) 355 sn_wnd = FLD_N( 'dyna_grid_T' , 120 , 'sowindsp' , .true. , .true. , 'yearly' , '' , '' ) 356 sn_uwd = FLD_N( 'dyna_grid_U' , 120 , 'vozocrtx' , .true. , .true. , 'yearly' , '' , '' ) 357 sn_vwd = FLD_N( 'dyna_grid_V' , 120 , 'vomecrty' , .true. , .true. , 'yearly' , '' , '' ) 358 sn_wwd = FLD_N( 'dyna_grid_W' , 120 , 'vovecrtz' , .true. , .true. , 'yearly' , '' , '' ) 359 sn_avt = FLD_N( 'dyna_grid_W' , 120 , 'votkeavt' , .true. , .true. , 'yearly' , '' , '' ) 360 sn_ubl = FLD_N( 'dyna_grid_U' , 120 , 'sobblcox' , .true. , .true. , 'yearly' , '' , '' ) 361 sn_vbl = FLD_N( 'dyna_grid_V' , 120 , 'sobblcoy' , .true. , .true. , 'yearly' , '' , '' ) 362 sn_ahu = FLD_N( 'dyna_grid_U' , 120 , 'vozoahtu' , .true. , .true. , 'yearly' , '' , '' ) 363 sn_ahv = FLD_N( 'dyna_grid_V' , 120 , 'vomeahtv' , .true. , .true. , 'yearly' , '' , '' ) 364 sn_ahw = FLD_N( 'dyna_grid_W' , 120 , 'voveahtz' , .true. , .true. , 'yearly' , '' , '' ) 365 sn_eiu = FLD_N( 'dyna_grid_U' , 120 , 'vozoaeiu' , .true. , .true. , 'yearly' , '' , '' ) 366 sn_eiv = FLD_N( 'dyna_grid_V' , 120 , 'vomeaeiv' , .true. , .true. , 'yearly' , '' , '' ) 367 sn_eiw = FLD_N( 'dyna_grid_W' , 120 , 'voveaeiw' , .true. , .true. , 'yearly' , '' , '' ) 368 ! 369 REWIND( numnam ) ! read in namlist namdta_dyn 370 READ ( numnam, namdta_dyn ) 340 ! 341 REWIND( numnam_ref ) ! Namelist namdta_dyn in reference namelist : Offline: init. of dynamical data 342 READ ( numnam_ref, namdta_dyn, IOSTAT = ios, ERR = 901) 343 901 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namdta_dyn in reference namelist', lwp ) 344 345 REWIND( numnam_cfg ) ! Namelist namdta_dyn in configuration namelist : Offline: init. of dynamical data 346 READ ( numnam_cfg, namdta_dyn, IOSTAT = ios, ERR = 902 ) 347 902 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namdta_dyn in configuration namelist', lwp ) 348 WRITE ( numond, namdta_dyn ) 371 349 ! ! store namelist information in an array 372 350 ! ! Control print -
branches/2013/dev_LOCEAN_2013/NEMOGCM/NEMO/OFF_SRC/nemogcm.F90
r3827 r4147 136 136 INTEGER :: ji ! dummy loop indices 137 137 INTEGER :: ilocal_comm ! local integer 138 INTEGER :: ios 138 139 CHARACTER(len=80), DIMENSION(16) :: cltxt 139 140 !! … … 141 142 & nn_isplt, nn_jsplt, nn_jctls, nn_jctle, & 142 143 & nn_bench, nn_timing 144 NAMELIST/namcfg/ cp_cfg, cp_cfz, jp_cfg, jpidta, jpjdta, jpkdta, jpiglo, jpjglo, & 145 & jpizoom, jpjzoom, jperio 143 146 !!---------------------------------------------------------------------- 144 147 ! 145 148 cltxt = '' 146 149 ! 147 ! ! open Namelist file 148 CALL ctl_opn( numnam, 'namelist', 'OLD', 'FORMATTED', 'SEQUENTIAL', -1, 6, .FALSE. ) 149 ! 150 READ( numnam, namctl ) ! Namelist namctl : Control prints & Benchmark 151 ! 150 ! ! Open reference namelist and configuration namelist files 151 CALL ctl_opn( numnam_ref, 'namelist_ref', 'OLD', 'FORMATTED', 'SEQUENTIAL', -1, 6, .FALSE. ) 152 CALL ctl_opn( numnam_cfg, 'namelist_cfg', 'OLD', 'FORMATTED', 'SEQUENTIAL', -1, 6, .FALSE. ) 153 CALL ctl_opn( numond, 'output.namelist.dyn', 'REPLACE', 'FORMATTED', 'SEQUENTIAL', -1, 6, .FALSE., narea ) 154 ! 155 ! 156 REWIND( numnam_ref ) ! Namelist namctl in reference namelist : Control prints & Benchmark 157 READ ( numnam_ref, namctl, IOSTAT = ios, ERR = 901 ) 158 901 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namctl in reference namelist', lwp ) 159 160 REWIND( numnam_cfg ) ! Namelist namctl in confguration namelist : Control prints & Benchmark 161 READ ( numnam_cfg, namctl, IOSTAT = ios, ERR = 902 ) 162 902 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namctl in configuration namelist', lwp ) 163 WRITE( numond, namctl ) 164 ! 165 REWIND( numnam_ref ) ! Namelist namcfg in reference namelist : Control prints & Benchmark 166 READ ( numnam_ref, namcfg, IOSTAT = ios, ERR = 903 ) 167 903 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namcfg in reference namelist', lwp ) 168 169 REWIND( numnam_cfg ) ! Namelist namcfg in confguration namelist : Control prints & Benchmark 170 READ ( numnam_cfg, namcfg, IOSTAT = ios, ERR = 904 ) 171 904 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namcfg in configuration namelist', lwp ) 172 WRITE( numond, namcfg ) 152 173 ! !--------------------------------------------! 153 174 ! ! set communicator & select the local node ! … … 155 176 #if defined key_iomput 156 177 CALL xios_initialize( "nemo",return_comm=ilocal_comm ) 157 narea = mynode( cltxt, numnam , nstop, ilocal_comm ) ! Nodes selection178 narea = mynode( cltxt, numnam_ref, numnam_cfg, numond , nstop, ilocal_comm ) ! Nodes selection 158 179 #else 159 180 ilocal_comm = 0 160 narea = mynode( cltxt, numnam , nstop )! Nodes selection (control print return in cltxt)181 narea = mynode( cltxt, numnam_ref, numnam_cfg, numond , nstop ) ! Nodes selection (control print return in cltxt) 161 182 #endif 162 183 … … 294 315 jsplt = nn_jsplt 295 316 nbench = nn_bench 317 IF(lwp) THEN ! control print 318 WRITE(numout,*) 319 WRITE(numout,*) 'namcfg : configuration initialization through namelist read' 320 WRITE(numout,*) '~~~~~~~ ' 321 WRITE(numout,*) ' Namelist namcfg' 322 WRITE(numout,*) ' configuration name cp_cfg = ', TRIM(cp_cfg) 323 WRITE(numout,*) ' configuration resolution jp_cfg = ', jp_cfg 324 WRITE(numout,*) ' 1st lateral dimension ( >= jpi ) jpidta = ', jpidta 325 WRITE(numout,*) ' 2nd " " ( >= jpj ) jpjdta = ', jpjdta 326 WRITE(numout,*) ' 3nd " " jpkdta = ', jpkdta 327 WRITE(numout,*) ' 1st dimension of global domain in i jpiglo = ', jpiglo 328 WRITE(numout,*) ' 2nd - - in j jpjglo = ', jpjglo 329 WRITE(numout,*) ' left bottom i index of the zoom (in data domain) jpizoom = ', jpizoom 330 WRITE(numout,*) ' left bottom j index of the zoom (in data domain) jpizoom = ', jpjzoom 331 WRITE(numout,*) ' lateral cond. type (between 0 and 6) jperio = ', jperio 332 ENDIF 296 333 ! ! Parameter control 297 334 ! … … 337 374 CASE ( 'gyre' ) ; CALL ctl_warn( ' The Benchmark is activated ' ) 338 375 CASE DEFAULT ; CALL ctl_stop( ' The Benchmark is based on the GYRE configuration:', & 339 & ' key_gyre must be usedor set nbench = 0' )376 & ' cp_cfg="gyre" in namelsit &namcfg or set nbench = 0' ) 340 377 END SELECT 341 378 ENDIF … … 364 401 ! 365 402 IF( numstp /= -1 ) CLOSE( numstp ) ! time-step file 366 IF( numnam /= -1 ) CLOSE( numnam ) ! oce namelist 403 IF( numnam_ref /= -1 ) CLOSE( numnam_ref ) ! oce reference namelist 404 IF( numnam_cfg /= -1 ) CLOSE( numnam_cfg ) ! oce configuration namelist 367 405 IF( numout /= 6 ) CLOSE( numout ) ! standard model output file 368 406 numout = 6 ! redefine numout in case it is used after this point...
Note: See TracChangeset
for help on using the changeset viewer.