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 9023 for branches/2017/dev_merge_2017/NEMOGCM/NEMO/OPA_SRC/SBC/sbcmod.F90 – NEMO

Ignore:
Timestamp:
2017-12-13T18:08:50+01:00 (6 years ago)
Author:
timgraham
Message:

Merged METO_MERCATOR branch and resolved all conflicts in OPA_SRC

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2017/dev_merge_2017/NEMOGCM/NEMO/OPA_SRC/SBC/sbcmod.F90

    r9019 r9023  
    9797         &             ln_rnf   , nn_fwb   , ln_ssr   , ln_isf    , ln_apr_dyn ,     & 
    9898         &             ln_wave  , ln_cdgw  , ln_sdw   , ln_tauoc  , ln_stcor   ,     & 
    99          &             nn_lsm 
     99         &             ln_tauw  , nn_lsm, nn_sdrift 
    100100      !!---------------------------------------------------------------------- 
    101101      ! 
     
    155155         WRITE(numout,*) '         surface wave                               ln_wave       = ', ln_wave 
    156156         WRITE(numout,*) '               Stokes drift corr. to vert. velocity ln_sdw        = ', ln_sdw 
     157         WRITE(numout,*) '                  vertical parametrization          nn_sdrift     = ', nn_sdrift 
    157158         WRITE(numout,*) '               wave modified ocean stress           ln_tauoc      = ', ln_tauoc 
     159         WRITE(numout,*) '               wave modified ocean stress component ln_tauw       = ', ln_tauw 
    158160         WRITE(numout,*) '               Stokes coriolis term                 ln_stcor      = ', ln_stcor 
    159161         WRITE(numout,*) '               neutral drag coefficient (CORE, MFS) ln_cdgw       = ', ln_cdgw 
    160162      ENDIF 
     163      ! 
     164      IF( ln_sdw ) THEN 
     165         IF( .NOT.(nn_sdrift==jp_breivik .OR. nn_sdrift==jp_phillips .OR. nn_sdrift==jp_peakfr) ) & 
     166            CALL ctl_stop( 'The chosen nn_sdrift for Stokes drift vertical velocity must be 0, 1, or 2' ) 
     167      ENDIF 
     168      IF( ln_tauoc .AND. ln_tauw ) & 
     169         CALL ctl_stop( 'More than one method for modifying the ocean stress has been selected ', & 
     170                                  '(ln_tauoc=.true. and ln_tauw=.true.)' ) 
     171      IF( ln_tauoc ) & 
     172         CALL ctl_warn( 'You are subtracting the wave stress to the ocean (ln_tauoc=.true.)' ) 
     173      IF( ln_tauw ) & 
     174         CALL ctl_warn( 'The wave modified ocean stress components are used (ln_tauw=.true.) ', & 
     175                              'This will override any other specification of the ocean stress' ) 
    161176      ! 
    162177      IF( .NOT.ln_usr ) THEN     ! the model calendar needs some specificities (except in user defined case) 
     
    391406         IF( ll_opa    )       CALL sbc_cpl_rcv   ( kt, nn_fsbc, nn_ice )   ! OPA-SAS coupling: OPA receiving fields from SAS 
    392407      END SELECT 
    393       IF ( ln_wave .AND. ln_tauoc) THEN                                 ! Wave stress subctracted 
    394             utau(:,:) = utau(:,:)*tauoc_wave(:,:) 
    395             vtau(:,:) = vtau(:,:)*tauoc_wave(:,:) 
    396             taum(:,:) = taum(:,:)*tauoc_wave(:,:) 
    397       ! 
    398             SELECT CASE( nsbc ) 
    399             CASE(  0,1,2,3,5,-1 )  ; 
    400                 IF(lwp .AND. kt == nit000 ) WRITE(numout,*) 'WARNING: You are subtracting the wave stress to the ocean. & 
    401                         & If not requested select ln_tauoc=.false' 
    402             END SELECT 
    403       ! 
    404       END IF 
     408      ! 
    405409      IF( ln_mixcpl )          CALL sbc_cpl_rcv   ( kt, nn_fsbc, nn_ice )   ! forced-coupled mixed formulation after forcing 
    406  
     410      ! 
     411      IF ( ln_wave .AND. (ln_tauoc .OR. ln_tauw) ) CALL sbc_wstress( )      ! Wind stress provided by waves  
    407412      ! 
    408413      !                                            !==  Misc. Options  ==! 
Note: See TracChangeset for help on using the changeset viewer.