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.
flxmod.F90 in trunk/NEMO/OPA_SRC/SBC – NEMO

source: trunk/NEMO/OPA_SRC/SBC/flxmod.F90 @ 529

Last change on this file since 529 was 473, checked in by opalod, 18 years ago

nemo_v1_update_060: SM: IOM + 301 levels + CORE + begining of ctl_stop

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 6.9 KB
Line 
1MODULE flxmod
2   !!======================================================================
3   !!                       ***  MODULE  flxmod  ***
4   !! Ocean forcing:  thermohaline forcing of the ocean
5   !!=====================================================================
6   !! * Modules used
7   USE oce             ! ocean dynamics and tracers
8   USE dom_oce         ! ocean space and time domain
9   USE phycst          ! physical constants
10   USE in_out_manager  ! I/O manager
11   USE lib_mpp         ! distribued memory computing library
12   USE lbclnk          ! ocean lateral boundary conditions (or mpp link)
13   USE daymod          ! calendar
14   USE ocfzpt          ! ocean freezing point
15
16   IMPLICIT NONE
17   PRIVATE
18
19   !! * Routine accessibility
20   PUBLIC flx       ! routine called by step.F90
21   PUBLIC flx_init  ! routine called by opa.F90
22
23   !! * local declarations
24   REAL(wp), PUBLIC ::            & !!! surface fluxes namelist (namflx)
25      q0    = 0.e0,               &  ! net heat flux
26      qsr0  = 0.e0,               &  ! solar heat flux
27      emp0  = 0.e0,               &  ! net freshwater flux
28      dqdt0 = -40.,               &  ! coefficient for SST damping (W/m2/K)
29      deds0 = 27.7                   ! coefficient for SSS damping (mm/day)
30   
31   !! * Substitutions
32#  include "domzgr_substitute.h90"
33   !!----------------------------------------------------------------------
34   !!   OPA 9.0 , LOCEAN-IPSL (2005)
35   !! $Header$
36   !! This software is governed by the CeCILL licence see modipsl/doc/NEMO_CeCILL.txt
37   !!----------------------------------------------------------------------
38
39#if defined key_flx_bulk_monthly
40   !!----------------------------------------------------------------------
41   !!   'key_flx_bulk_monthly'   and                           MONTHLY bulk
42   !!   Default option                                         Net CDF file
43   !!----------------------------------------------------------------------
44#  include "flx_bulk_monthly.h90"
45
46#elif defined key_flx_bulk_daily
47   !!----------------------------------------------------------------------
48   !!   'key_flx_bulk_daily'                                     DAILY bulk
49   !!                                                          Net CDF file
50   !!----------------------------------------------------------------------
51#  include "flx_bulk_daily.h90"
52
53#elif defined key_flx_core
54   !!----------------------------------------------------------------------
55   !!   'key_flx_core'   and                     NCAR data (Large & Yeager)
56   !!                                                          Net CDF file
57   !!----------------------------------------------------------------------
58#  include "flx_core.h90"
59
60#elif defined key_flx_forced_daily
61   !!----------------------------------------------------------------------
62   !!   'key_flx_forced_daily'                                 DAILY fluxes
63   !!                                                          Net CDF file
64   !!----------------------------------------------------------------------
65#  include "flx_forced_daily.h90"
66
67#elif defined key_coupled
68# if defined key_ice_lim
69   !!----------------------------------------------------------------------
70   !!   'key_coupled'  and                          Coupled Ocan/Atmosphere
71   !!   'key_ice_lim'                               with  LIM sea-ice model
72   !!----------------------------------------------------------------------
73#  include "flx_coupled_ice.h90"
74
75# else
76   !!----------------------------------------------------------------------
77   !!   'key_flx_coupled'  and                      Coupled Ocan/Atmosphere
78   !!   Default option                              without   sea-ice model
79   !!----------------------------------------------------------------------
80#  include "flx_coupled_noice.h90"
81
82# endif
83#else
84   !!----------------------------------------------------------------------
85   !!   Default option                                   Analytical forcing
86   !!----------------------------------------------------------------------
87   !!   flx          : define the thermohaline fluxes for the ocean
88   !!----------------------------------------------------------------------
89   !! * Module used
90   !!----------------------------------------------------------------------
91
92CONTAINS
93
94   SUBROUTINE flx ( kt )
95      !!---------------------------------------------------------------------
96      !!                    ***  ROUTINE flx  ***
97      !!             
98      !! ** Purpose :   provide the thermohaline fluxes (heat and freshwater)
99      !!      to the ocean at each time step.
100      !!
101      !! ** Method  :   Constant surface fluxes (read in namelist (namflx))
102      !!
103      !! ** Action  : - q, qt, qsr, emp, emps, qrp, erp
104      !!
105      !! History :
106      !!        !  91-03  ()  Original code
107      !!   8.5  !  02-09  (G. Madec)  F90: Free form and module
108      !!----------------------------------------------------------------------
109      !! * arguments
110      INTEGER, INTENT( in  ) ::   kt   ! ocean time step
111      !!---------------------------------------------------------------------
112
113      IF( kt == nit000 )  THEN
114         IF(lwp) WRITE(numout,*)' '
115         IF(lwp) WRITE(numout,*)'flx     : Analytical/Constant surface fluxes'
116         IF(lwp) WRITE(numout,*)'~~~~~~~ '
117         IF(lwp) WRITE(numout,*)'          See the routine oce_sbc'     
118         IF(lwp) WRITE(numout,*)' '
119      ENDIF
120
121   END SUBROUTINE flx
122
123#endif
124
125
126   SUBROUTINE flx_init
127      !!---------------------------------------------------------------------
128      !!                    ***  ROUTINE flx  ***
129      !!             
130      !! ** Purpose :   provide the thermohaline fluxes (heat and freshwater)
131      !!      to the ocean at each time step.
132      !!
133      !! ** Method  :   Constant surface fluxes (read in namelist (namflx))
134      !!
135      !! ** Action  : - q, qt, qsr, emp, emps, qrp, erp
136      !!
137      !! History :
138      !!        !  91-03  ()  Original code
139      !!   8.5  !  02-09  (G. Madec)  F90: Free form and module
140      !!----------------------------------------------------------------------
141      NAMELIST/namflx/ q0, qsr0, emp0, dqdt0, deds0
142      !!---------------------------------------------------------------------
143
144      ! Read Namelist namflx : surface thermohaline fluxes
145      ! --------------------
146      REWIND ( numnam )
147      READ   ( numnam, namflx )
148
149      IF(lwp) THEN
150         WRITE(numout,*)' '
151         WRITE(numout,*)'flx_init : thermohaline forcing '
152         WRITE(numout,*)'~~~~~~~~ '
153         WRITE(numout,*)'           net heat flux                  q0   = ', q0  , ' W/m2'
154         WRITE(numout,*)'           solar heat flux                qsr0 = ', qsr0, ' W/m2'
155         WRITE(numout,*)'           net heat flux                  emp0 = ', emp0, ' W/m2'
156         WRITE(numout,*)'           coefficient for SST damping   dqdt0 = ', dqdt0,' W/m2/K'
157         WRITE(numout,*)'           coefficient for SSS damping   deds0 = ', deds0,' mm/day'
158      ENDIF
159
160   END SUBROUTINE flx_init
161
162END MODULE flxmod
Note: See TracBrowser for help on using the repository browser.