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.
dynspg_oce.F90 in branches/2015/dev_r5847_MERCATOR9_solveur_simplification/NEMOGCM/NEMO/OPA_SRC/DYN – NEMO

source: branches/2015/dev_r5847_MERCATOR9_solveur_simplification/NEMOGCM/NEMO/OPA_SRC/DYN/dynspg_oce.F90 @ 5868

Last change on this file since 5868 was 5868, checked in by jchanut, 8 years ago

Free surface simplification #1620. Step 1: suppress filtered free surface

  • Property svn:keywords set to Id
File size: 3.5 KB
Line 
1MODULE dynspg_oce
2   !!======================================================================
3   !!                       ***  MODULE dynspg_oce  ***
4   !!       
5   !! Ocean dynamics: Define in memory some surface pressure gradient variables
6   !!======================================================================
7   !! History :  1.0  ! 2005-12  (C. Talandier, G. Madec)  Original code
8   !!            3.2  ! 2009-07  (R. Benshila) Suppression of rigid-lid option
9   !!----------------------------------------------------------------------
10   USE par_oce        ! ocean parameters
11   USE lib_mpp        ! MPP library
12
13   IMPLICIT NONE
14   PUBLIC           
15
16   PUBLIC   dynspg_oce_alloc   ! called in dynspg.F90
17   
18   !                                                       !!! Surface pressure gradient logicals
19#if   defined key_dynspg_exp
20   LOGICAL, PUBLIC, PARAMETER ::   lk_dynspg_exp = .TRUE.   !: Explicit free surface flag
21#else
22   LOGICAL, PUBLIC, PARAMETER ::   lk_dynspg_exp = .FALSE.  !: Explicit free surface flag
23#endif
24#if   defined key_dynspg_ts
25   LOGICAL, PUBLIC, PARAMETER ::   lk_dynspg_ts  = .TRUE.   !: Free surface with time splitting flag
26#else
27   LOGICAL, PUBLIC, PARAMETER ::   lk_dynspg_ts  = .FALSE.  !: Free surface with time splitting flag
28#endif
29  !                                                                         !!! Time splitting scheme (key_dynspg_ts)
30   REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) ::   sshn_e, ssha_e   ! sea surface heigth (now, after)
31   REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) ::   ua_e  , va_e     ! barotropic velocities (after)
32   REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) ::   hu_e  , hv_e     ! now ocean depth ( = Ho+sshn_e )
33   REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) ::   hur_e , hvr_e    ! inverse of hu_e and hv_e
34   REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) ::   un_adv, vn_adv   ! Advection vel. at "now" barocl. step
35   REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) ::   ub2_b,  vb2_b    ! Half step fluxes (ln_bt_fw=T)
36#if defined key_agrif
37   REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:) ::   ub2_i_b,  vb2_i_b! Half step time integrated fluxes
38#endif
39
40   !!----------------------------------------------------------------------
41   !! NEMO/OPA 4.0 , NEMO Consortium (2011)
42   !! $Id$
43   !! Software governed by the CeCILL licence     (NEMOGCM/NEMO_CeCILL.txt)
44   !!----------------------------------------------------------------------
45CONTAINS
46
47   INTEGER FUNCTION dynspg_oce_alloc()
48      !!----------------------------------------------------------------------
49      !!                  ***  routine dynspg_oce_alloc  ***
50      !!----------------------------------------------------------------------
51      ALLOCATE( sshn_e(jpi,jpj) , ua_e(jpi,jpj) , hu_e(jpi,jpj) , hur_e(jpi,jpj) ,      &
52         &      ssha_e(jpi,jpj) , va_e(jpi,jpj) , hv_e(jpi,jpj) , hvr_e(jpi,jpj) ,      &
53         &      ub2_b(jpi,jpj)  , vb2_b(jpi,jpj)                                 ,      &
54#if defined key_agrif
55         &      ub2_i_b(jpi,jpj), vb2_i_b(jpi,jpj)                               ,      &
56#endif
57         &      un_adv(jpi,jpj) , vn_adv(jpi,jpj)                                , STAT = dynspg_oce_alloc )
58         !
59      IF( lk_mpp                )   CALL mpp_sum ( dynspg_oce_alloc )
60      IF( dynspg_oce_alloc /= 0 )   CALL ctl_warn('dynspg_oce_alloc: failed to allocate arrays')
61      !
62   END FUNCTION dynspg_oce_alloc
63
64   !!======================================================================
65END MODULE dynspg_oce
Note: See TracBrowser for help on using the repository browser.