- Timestamp:
- 2018-06-21T11:58:42+02:00 (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/UKMO/dev_r5518_nemo2cice_prints/NEMOGCM/NEMO/OPA_SRC/nemogcm.F90
r9816 r9817 68 68 USE icbini ! handle bergs, initialisation 69 69 USE icbstp ! handle bergs, calving, themodynamics and transport 70 USE sbccpl 70 71 USE cpl_oasis3 ! OASIS3 coupling 71 72 USE c1d ! 1D configuration … … 74 75 #if defined key_top 75 76 USE trcini ! passive tracer initialisation 77 USE trc, ONLY: numstr ! tracer stats unit number 76 78 #endif 77 79 USE lib_mpp ! distributed memory computing … … 161 163 ENDIF 162 164 165 #if defined key_agrif 166 CALL Agrif_Regrid() 167 #endif 168 163 169 DO WHILE ( istp <= nitend .AND. nstop == 0 ) 164 170 #if defined key_agrif 165 CALL Agrif_Step( stp )! AGRIF: time stepping171 CALL stp ! AGRIF: time stepping 166 172 #else 167 CALL stp( istp ) ! standard time stepping 173 IF (lk_oasis) CALL sbc_cpl_snd( istp ) ! Coupling to atmos 174 CALL stp( istp ) 175 ! We don't couple on the final timestep because 176 ! our restart file has already been written 177 ! and contains all the necessary data for a 178 ! restart. sbc_cpl_snd could be called here 179 ! but it would require 180 ! a) A test to ensure it was not performed 181 ! on the very last time-step 182 ! b) the presence of another call to 183 ! sbc_cpl_snd call prior to the main DO loop 184 ! This solution produces identical results 185 ! with fewer lines of code. 168 186 #endif 169 187 istp = istp + 1 … … 187 205 ! 188 206 #if defined key_agrif 189 CALL Agrif_ParentGrid_To_ChildGrid() 190 IF( lk_diaobs ) CALL dia_obs_wri 191 IF( nn_timing == 1 ) CALL timing_finalize 192 CALL Agrif_ChildGrid_To_ParentGrid() 207 IF( .NOT. Agrif_Root() ) THEN 208 CALL Agrif_ParentGrid_To_ChildGrid() 209 IF( lk_diaobs ) CALL dia_obs_wri 210 IF( nn_timing == 1 ) CALL timing_finalize 211 CALL Agrif_ChildGrid_To_ParentGrid() 212 ENDIF 193 213 #endif 194 214 IF( nn_timing == 1 ) CALL timing_finalize … … 277 297 IF( Agrif_Root() ) THEN 278 298 IF( lk_oasis ) THEN 279 CALL cpl_init( " oceanx", ilocal_comm ) ! nemo local communicator given by oasis299 CALL cpl_init( "toyoce", ilocal_comm ) ! nemo local communicator given by oasis 280 300 CALL xios_initialize( "not used",local_comm=ilocal_comm ) ! send nemo communicator to xios 281 301 ELSE … … 288 308 IF( lk_oasis ) THEN 289 309 IF( Agrif_Root() ) THEN 290 CALL cpl_init( " oceanx", ilocal_comm ) ! nemo local communicator given by oasis310 CALL cpl_init( "toyoce", ilocal_comm ) ! nemo local communicator given by oasis 291 311 ENDIF 292 312 ! Nodes selection (control print return in cltxt) … … 334 354 jpj = ( jpjglo-2*jprecj + (jpnj-1) ) / jpnj + 2*jprecj ! second dim. 335 355 #endif 336 ENDIF 356 ENDIF 337 357 jpk = jpkdta ! third dim 358 #if defined key_agrif 359 ! simple trick to use same vertical grid as parent 360 ! but different number of levels: 361 ! Save maximum number of levels in jpkdta, then define all vertical grids 362 ! with this number. 363 ! Suppress once vertical online interpolation is ok 364 IF(.NOT.Agrif_Root()) jpkdta = Agrif_Parent(jpkdta) 365 #endif 338 366 jpim1 = jpi-1 ! inner domain indices 339 367 jpjm1 = jpj-1 ! " " … … 448 476 ! ! Diagnostics 449 477 IF( lk_floats ) CALL flo_init ! drifting Floats 450 IF( lk_diaar5 ) CALL dia_ar5_init ! ar5 diag451 478 CALL dia_ptr_init ! Poleward TRansports initialization 452 479 IF( lk_diadct ) CALL dia_dct_init ! Sections tranports … … 461 488 IF( lk_asminc ) CALL asm_inc_init ! Initialize assimilation increments 462 489 IF(lwp) WRITE(numout,*) 'Euler time step switch is ', neuler 490 491 IF (nstop > 0) THEN 492 CALL CTL_STOP('STOP','Critical errors in NEMO initialisation') 493 END IF 494 463 495 ! 464 496 END SUBROUTINE nemo_init … … 596 628 IF( numdct_heat /= -1 ) CLOSE( numdct_heat ) ! heat transports 597 629 IF( numdct_salt /= -1 ) CLOSE( numdct_salt ) ! salt transports 598 630 #if defined key_top 631 IF( numstr /= -1 ) CLOSE( numstr ) ! tracer statistics 632 #endif 599 633 ! 600 634 numout = 6 ! redefine numout in case it is used after this point... … … 710 744 INTEGER :: ifac, jl, inu 711 745 INTEGER, PARAMETER :: ntest = 14 712 INTEGER :: ilfax(ntest) 713 ! 714 ! lfax contains the set of allowed factors. 715 data (ilfax(jl),jl=1,ntest) / 16384, 8192, 4096, 2048, 1024, 512, 256, & 716 & 128, 64, 32, 16, 8, 4, 2 / 717 !!---------------------------------------------------------------------- 746 INTEGER, DIMENSION(ntest) :: ilfax 747 ! 748 ! ilfax contains the set of allowed factors. 749 ilfax(:) = (/(2**jl,jl=ntest,1,-1)/) 750 !!---------------------------------------------------------------------- 751 ! ilfax contains the set of allowed factors. 752 ilfax(:) = (/(2**jl,jl=ntest,1,-1)/) 718 753 719 754 ! Clear the error flag and initialise output vars
Note: See TracChangeset
for help on using the changeset viewer.