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 2920 for branches/2011/dev_r2787_MERCATOR3_tidalpot/NEMOGCM/NEMO/OPA_SRC/DYN/dynspg_ts.F90 – NEMO

Ignore:
Timestamp:
2011-10-14T09:15:19+02:00 (13 years ago)
Author:
cbricaud
Message:

add tidal potential

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2011/dev_r2787_MERCATOR3_tidalpot/NEMOGCM/NEMO/OPA_SRC/DYN/dynspg_ts.F90

    r2724 r2920  
    3535   USE bdydyn          ! unstructured open boundaries 
    3636   USE bdytides        ! tidal forcing at unstructured open boundaries. 
     37   USE tideini 
     38   USE updtide 
    3739   USE lib_mpp         ! distributed memory computing library 
    3840   USE lbclnk          ! ocean lateral boundary conditions (or mpp link) 
     
    371373         IF( lk_obc )   CALL obc_dta_bt ( kt, jn   ) 
    372374         IF( lk_bdy )   CALL bdy_dta_fla( kt, jn+1, icycle ) 
     375         IF ((lk_tide).AND.(ln_tide_pot)) CALL upd_tide( kt, jn ) 
    373376 
    374377         !                                                !* after ssh_e 
     
    418421                     zu_spg = -grav * ( sshn_e(ji+1,jj) - sshn_e(ji,jj) ) / e1u(ji,jj) 
    419422                     zv_spg = -grav * ( sshn_e(ji,jj+1) - sshn_e(ji,jj) ) / e2v(ji,jj) 
     423                  ENDIF 
     424                  ! add tidal astronomical forcing 
     425                  IF ( lk_tide ) THEN  
     426                  zu_spg = zu_spg + grav * ( pot_astro(ji+1,jj) - pot_astro(ji,jj) ) / e1u(ji,jj) 
     427                  zv_spg = zv_spg + grav * ( pot_astro(ji,jj+1) - pot_astro(ji,jj) ) / e2v(ji,jj) 
    420428                  ENDIF 
    421429                  ! energy conserving formulation for planetary vorticity term 
     
    447455                     zv_spg = -grav * ( sshn_e(ji,jj+1) - sshn_e(ji,jj) ) / e2v(ji,jj) 
    448456                  ENDIF 
     457                  ! add tidal astronomical forcing 
     458                  IF ( lk_tide ) THEN 
     459                  zu_spg = zu_spg + grav * ( pot_astro(ji+1,jj) - pot_astro(ji,jj) ) / e1u(ji,jj) 
     460                  zv_spg = zv_spg + grav * ( pot_astro(ji,jj+1) - pot_astro(ji,jj) ) / e2v(ji,jj) 
     461                  ENDIF 
    449462                  ! enstrophy conserving formulation for planetary vorticity term 
    450463                  zy1 =   z1_8 * ( zwy(ji  ,jj-1) + zwy(ji+1,jj-1) + zwy(ji,jj) + zwy(ji+1,jj  ) ) / e1u(ji,jj) 
     
    472485                     zu_spg = -grav * ( sshn_e(ji+1,jj) - sshn_e(ji,jj) ) / e1u(ji,jj) 
    473486                     zv_spg = -grav * ( sshn_e(ji,jj+1) - sshn_e(ji,jj) ) / e2v(ji,jj) 
     487                  ENDIF 
     488                  ! add tidal astronomical forcing 
     489                  IF ( lk_tide ) THEN 
     490                  zu_spg = zu_spg + grav * ( pot_astro(ji+1,jj) - pot_astro(ji,jj) ) / e1u(ji,jj) 
     491                  zv_spg = zv_spg + grav * ( pot_astro(ji,jj+1) - pot_astro(ji,jj) ) / e2v(ji,jj) 
    474492                  ENDIF 
    475493                  ! energy/enstrophy conserving formulation for planetary vorticity term 
Note: See TracChangeset for help on using the changeset viewer.