New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 8213 for branches/NERC/dev_r5518_NOC_MEDUSA_Stable/NEMOGCM/NEMO/TOP_SRC/trcini.F90 – NEMO

Ignore:
Timestamp:
2017-06-25T11:27:43+02:00 (7 years ago)
Author:
jpalmier
Message:

JPALM -- split trcbio - mergeable-ish MEDUSA branch

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/NERC/dev_r5518_NOC_MEDUSA_Stable/NEMOGCM/NEMO/TOP_SRC/trcini.F90

    r8130 r8213  
    2424   USE trcini_pisces   ! PISCES   initialisation 
    2525   USE trcini_c14b     ! C14 bomb initialisation 
     26   USE trcini_age      ! AGE      initialisation 
    2627   USE trcini_my_trc   ! MY_TRC   initialisation 
     28   USE trcini_idtra    ! idealize tracer initialisation 
    2729   USE trcini_medusa   ! MEDUSA   initialisation 
    28    USE trcini_idtra    ! idealize tracer initialisation 
    29    USE trcini_age      ! AGE      initialisation 
    3030   USE trcdta          ! initialisation from files 
    3131   USE daymod          ! calendar manager 
     
    8181         &   CALL ctl_warn(' Coupling with passive tracers and used of diurnal cycle. & 
    8282         & Computation of a daily mean shortwave for some biogeochemical models) ') 
    83           !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! 
    84           !!!!! CHECK For MEDUSA 
    85           !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! 
     83 
    8684      IF( nn_cla == 1 )   & 
    8785         &  CALL ctl_stop( ' Cross Land Advection not yet implemented with passive tracer ; nn_cla must be 0' ) 
     
    112110 
    113111      CALL trc_ice_ini                                 ! Tracers in sea ice 
    114  
    115 # if defined key_debug_medusa 
    116          IF (lwp) write (numout,*) '------------------------------' 
    117          IF (lwp) write (numout,*) 'Jpalm - debug' 
    118          IF (lwp) write (numout,*) ' in trc_init' 
    119          IF (lwp) write (numout,*) ' sms init OK' 
    120          IF (lwp) write (numout,*) ' next: open tracer.stat' 
    121          IF (lwp) write (numout,*) ' ' 
    122          CALL flush(numout) 
    123 # endif 
    124112 
    125113      IF( ln_ctl ) THEN 
     
    135123      ENDIF 
    136124 
    137 # if defined key_debug_medusa 
    138          IF (lwp) write (numout,*) '------------------------------' 
    139          IF (lwp) write (numout,*) 'Jpalm - debug' 
    140          IF (lwp) write (numout,*) ' in trc_init' 
    141          IF (lwp) write (numout,*) 'open tracer.stat -- OK' 
    142          IF (lwp) write (numout,*) ' ' 
    143          CALL flush(numout) 
    144 # endif 
    145  
    146  
    147125      IF( ln_trcdta ) THEN 
    148 #if defined key_medusa 
    149          IF(lwp) WRITE(numout,*) 'AXY: calling trc_dta_init' 
    150          IF(lwp) CALL flush(numout) 
    151 #endif 
    152126         CALL trc_dta_init(jptra) 
    153127      ENDIF 
     
    155129      IF( ln_rsttr ) THEN 
    156130        ! 
    157 #if defined key_medusa 
    158         IF(lwp) WRITE(numout,*) 'AXY: calling trc_rst_read' 
    159         IF(lwp) CALL flush(numout) 
    160 #endif 
    161131        CALL trc_rst_read              ! restart from a file 
    162132        ! 
    163133      ELSE 
    164         ! 
    165 # if defined key_debug_medusa 
    166          IF (lwp) write (numout,*) '------------------------------' 
    167          IF (lwp) write (numout,*) 'Jpalm - debug' 
    168          IF (lwp) write (numout,*) ' Init from file -- will call trc_dta' 
    169          IF (lwp) write (numout,*) ' ' 
    170          CALL flush(numout) 
    171 # endif 
    172134        ! 
    173135        IF( ln_trcdta .AND. nb_trcdta > 0 ) THEN  ! Initialisation of tracer from a file that may also be used for damping 
     
    193155        ENDIF 
    194156        ! 
    195 # if defined key_debug_medusa 
    196          IF (lwp) write (numout,*) '------------------------------' 
    197          IF (lwp) write (numout,*) 'Jpalm - debug' 
    198          IF (lwp) write (numout,*) ' in trc_init' 
    199          IF (lwp) write (numout,*) ' before trb = trn' 
    200          IF (lwp) write (numout,*) ' ' 
    201          CALL flush(numout) 
    202 # endif 
    203         ! 
    204157        trb(:,:,:,:) = trn(:,:,:,:) 
    205         !  
    206 # if defined key_debug_medusa 
    207          IF (lwp) write (numout,*) '------------------------------' 
    208          IF (lwp) write (numout,*) 'Jpalm - debug' 
    209          IF (lwp) write (numout,*) ' in trc_init' 
    210          IF (lwp) write (numout,*) ' trb = trn -- OK' 
    211          IF (lwp) write (numout,*) ' ' 
    212          CALL flush(numout) 
    213 # endif 
    214158        !  
    215159      ENDIF 
     
    220164      IF( ln_zps .AND. .NOT. lk_c1d .AND.       ln_isfcav )   & 
    221165        &    CALL zps_hde_isf( nit000, jptra, trn, pgtu=gtru, pgtv=gtrv, pgtui=gtrui, pgtvi=gtrvi )       ! tracers at the bottom ocean level 
    222       ! 
    223 # if defined key_debug_medusa 
    224          IF (lwp) write (numout,*) '------------------------------' 
    225          IF (lwp) write (numout,*) 'Jpalm - debug' 
    226          IF (lwp) write (numout,*) ' in trc_init' 
    227          IF (lwp) write (numout,*) ' partial step -- OK' 
    228          IF (lwp) write (numout,*) ' ' 
    229          CALL flush(numout) 
    230 # endif 
     166 
     167 
    231168      ! 
    232169      IF( nn_dttrc /= 1 )        CALL trc_sub_ini      ! Initialize variables for substepping passive tracers 
    233170      ! 
    234 # if defined key_debug_medusa 
    235          IF (lwp) write (numout,*) '------------------------------' 
    236          IF (lwp) write (numout,*) 'Jpalm - debug' 
    237          IF (lwp) write (numout,*) ' in trc_init' 
    238          IF (lwp) write (numout,*) ' before initiate tracer contents' 
    239          IF (lwp) write (numout,*) ' ' 
    240          CALL flush(numout) 
    241 # endif 
    242       ! 
     171 
    243172      trai(:) = 0._wp                                                   ! initial content of all tracers 
    244173      DO jn = 1, jptra 
     
    253182         WRITE(numout,*) '          *** Total inital content of all tracers ' 
    254183         WRITE(numout,*) 
    255 # if defined key_debug_medusa 
    256          CALL flush(numout) 
    257 # endif 
    258          ! 
    259 # if defined key_debug_medusa 
    260          WRITE(numout,*) ' litle check :  ', ctrcnm(1) 
    261          CALL flush(numout) 
    262 # endif 
    263184         DO jn = 1, jptra 
    264185            WRITE(numout,9000) jn, TRIM( ctrcnm(jn) ), trai(jn) 
     
    304225      USE trdmxl_trc    , ONLY:   trd_mxl_trc_alloc 
    305226#endif 
     227# if defined key_medusa 
     228      USE bio_medusa_mod, ONLY:   bio_medusa_alloc 
     229# endif 
     230 
    306231      ! 
    307232      INTEGER :: ierr 
     
    316241      ierr = ierr + trd_mxl_trc_alloc() 
    317242#endif 
     243#if defined key_medusa 
     244      ierr = ierr + bio_medusa_alloc() 
     245#endif 
    318246      ! 
    319247      IF( lk_mpp    )   CALL mpp_sum( ierr ) 
Note: See TracChangeset for help on using the changeset viewer.