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.
ldfeiv.F90 in tags/nemo_v3_2/nemo_v3_2/NEMO/OFF_SRC/LDF – NEMO

source: tags/nemo_v3_2/nemo_v3_2/NEMO/OFF_SRC/LDF/ldfeiv.F90 @ 1878

Last change on this file since 1878 was 1878, checked in by flavoni, 14 years ago

initial test for nemogcm

File size: 3.8 KB
Line 
1MODULE ldfeiv
2   !!======================================================================
3   !!                     ***  MODULE  ldfeiv  ***
4   !! Ocean physics:  variable eddy induced velocity coefficients
5   !!======================================================================
6#if   defined key_traldf_eiv   &&   defined key_traldf_c2d
7   !!----------------------------------------------------------------------
8   !!   'key_traldf_eiv'      and                     eddy induced velocity
9   !!   'key_traldf_c2d'                    2D tracer lateral  mixing coef.
10   !!----------------------------------------------------------------------
11   !!   ldf_eiv      : compute the eddy induced velocity coefficients
12   !!                  Same results but not same routine if 'key_autotasking'
13   !!                  is defined or not
14   !!----------------------------------------------------------------------
15   !! * Modules used
16   USE oce             ! ocean dynamics and tracers
17   USE dom_oce         ! ocean space and time domain
18   USE ldftra_oce      ! ocean tracer   lateral physics
19   USE phycst          ! physical constants
20   USE in_out_manager  ! I/O manager
21   USE lbclnk          ! ocean lateral boundary conditions (or mpp link)
22
23   IMPLICIT NONE
24   PRIVATE
25
26   !! * Routine accessibility
27   PUBLIC ldf_eiv               ! routine called by step.F90
28   !!----------------------------------------------------------------------
29   !!  OPA 9.0 , LOCEAN-IPSL (2005)
30   !! $Id: ldfeiv.F90 1326 2009-02-20 10:08:16Z cetlod $
31   !! This software is governed by the CeCILL licence see modipsl/doc/NEMO_CeCILL.txt
32   !!----------------------------------------------------------------------
33   !! * Substitutions
34#  include "domzgr_substitute.h90"
35#  include "vectopt_loop_substitute.h90"
36   !!----------------------------------------------------------------------
37
38CONTAINS
39
40   SUBROUTINE ldf_eiv( kt )
41      !!----------------------------------------------------------------------
42      !!                  ***  ROUTINE ldf_eiv  ***
43      !!
44      !! ** Purpose :   Compute the eddy induced velocity coefficient from the
45      !!      growth rate of baroclinic instability.
46      !!
47      !! ** Method : Specific to the offline model. Computes the horizontal
48      !!             values from the vertical value
49      !!
50      !! History :
51      !!   9.0  !  06-03  (O. Aumont)  Free form, F90
52      !!----------------------------------------------------------------------
53      !! * Arguments
54      INTEGER, INTENT( in ) ::   kt     ! ocean time-step inedx
55
56      !! * Local declarations
57      INTEGER ::   ji, jj           ! dummy loop indices
58      !!----------------------------------------------------------------------
59
60      IF( kt == nit000 ) THEN
61         IF(lwp) WRITE(numout,*)
62         IF(lwp) WRITE(numout,*) 'ldf_eiv : eddy induced velocity coefficients'
63         IF(lwp) WRITE(numout,*) '~~~~~~~'
64      ENDIF
65
66      ! Average the diffusive coefficient at u- v- points
67      DO jj = 2, jpjm1
68         DO ji = fs_2, fs_jpim1   ! vector opt.
69            aeiu(ji,jj) = .5 * ( aeiw(ji,jj) + aeiw(ji+1,jj  ) )
70            aeiv(ji,jj) = .5 * ( aeiw(ji,jj) + aeiw(ji  ,jj+1) )
71         END DO
72      END DO
73
74      ! lateral boundary condition on aeiu, aeiv
75      CALL lbc_lnk( aeiu, 'U', 1. )
76      CALL lbc_lnk( aeiv, 'V', 1. )
77
78   END SUBROUTINE ldf_eiv
79
80
81#else
82   !!----------------------------------------------------------------------
83   !!   Default option                                         Dummy module
84   !!----------------------------------------------------------------------
85CONTAINS
86   SUBROUTINE ldf_eiv( kt )       ! Empty routine
87      WRITE(*,*) 'ldf_eiv: You should not have seen this print! error?', kt
88   END SUBROUTINE ldf_eiv
89#endif
90
91   !!======================================================================
92END MODULE ldfeiv
Note: See TracBrowser for help on using the repository browser.