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.
p4zint.F90 in branches/2016/dev_r6519_HPC_4/NEMOGCM/NEMO/TOP_SRC/PISCES/P4Z – NEMO

source: branches/2016/dev_r6519_HPC_4/NEMOGCM/NEMO/TOP_SRC/PISCES/P4Z/p4zint.F90 @ 7037

Last change on this file since 7037 was 7037, checked in by mocavero, 8 years ago

ORCA2_LIM_PISCES hybrid version update

  • Property svn:keywords set to Id
File size: 3.8 KB
Line 
1MODULE p4zint
2   !!======================================================================
3   !!                         ***  MODULE p4zint  ***
4   !! TOP :   PISCES interpolation and computation of various accessory fields
5   !!======================================================================
6   !! History :   1.0  !  2004-03 (O. Aumont) Original code
7   !!             2.0  !  2007-12  (C. Ethe, G. Madec)  F90
8   !!----------------------------------------------------------------------
9#if defined key_pisces
10   !!----------------------------------------------------------------------
11   !!   'key_pisces'                                       PISCES bio-model
12   !!----------------------------------------------------------------------
13   !!   p4z_int        :  interpolation and computation of various accessory fields
14   !!----------------------------------------------------------------------
15   USE oce_trc         !  shared variables between ocean and passive tracers
16   USE trc             !  passive tracers common variables
17   USE sms_pisces      !  PISCES Source Minus Sink variables
18   USE iom
19
20   IMPLICIT NONE
21   PRIVATE
22
23   PUBLIC   p4z_int 
24   REAL(wp) ::   xksilim = 16.5e-6_wp   ! Half-saturation constant for the Si half-saturation constant computation
25
26   !!----------------------------------------------------------------------
27   !! NEMO/TOP 3.3 , NEMO Consortium (2010)
28   !! $Id$
29   !! Software governed by the CeCILL licence     (NEMOGCM/NEMO_CeCILL.txt)
30   !!----------------------------------------------------------------------
31CONTAINS
32
33   SUBROUTINE p4z_int( kt )
34      !!---------------------------------------------------------------------
35      !!                     ***  ROUTINE p4z_int  ***
36      !!
37      !! ** Purpose :   interpolation and computation of various accessory fields
38      !!
39      !!---------------------------------------------------------------------
40      !
41      INTEGER, INTENT( in ) ::   kt      ! ocean time-step index
42      !
43      INTEGER  :: ji, jj, jk             ! dummy loop indices
44      REAL(wp) :: zvar                   ! local variable
45      !!---------------------------------------------------------------------
46      !
47      IF( nn_timing == 1 )  CALL timing_start('p4z_int')
48      !
49      ! Computation of phyto and zoo metabolic rate
50      ! -------------------------------------------
51!$OMP PARALLEL
52!$OMP DO schedule(static) private(jk,jj,ji)
53      DO jk = 1, jpk
54         DO jj = 1, jpj
55            DO ji = 1, jpi
56               tgfunc (ji,jj,jk) = EXP( 0.063913 * tsn(ji,jj,jk,jp_tem) )
57               tgfunc2(ji,jj,jk) = EXP( 0.07608  * tsn(ji,jj,jk,jp_tem) )
58            END DO
59         END DO
60      END DO
61
62      ! Computation of the silicon dependant half saturation  constant for silica uptake
63      ! ---------------------------------------------------
64!$OMP DO schedule(static) private(jj,ji,zvar)
65      DO jj = 1, jpj
66         DO ji = 1, jpi
67            zvar = trb(ji,jj,1,jpsil) * trb(ji,jj,1,jpsil)
68            xksimax(ji,jj) = MAX( xksimax(ji,jj), ( 1.+ 7.* zvar / ( xksilim * xksilim + zvar ) ) * 1e-6 )
69         END DO
70      END DO
71      !
72      IF( nday_year == nyear_len(1) ) THEN
73!$OMP WORKSHARE
74         xksi   (:,:) = xksimax(:,:)
75         xksimax(:,:) = 0._wp
76!$OMP END WORKSHARE NOWAIT
77      ENDIF
78!$OMP END PARALLEL
79      !
80      IF( nn_timing == 1 )  CALL timing_stop('p4z_int')
81      !
82   END SUBROUTINE p4z_int
83
84#else
85   !!======================================================================
86   !!  Dummy module :                                   No PISCES bio-model
87   !!======================================================================
88CONTAINS
89   SUBROUTINE p4z_int                   ! Empty routine
90      WRITE(*,*) 'p4z_int: You should not have seen this print! error?'
91   END SUBROUTINE p4z_int
92#endif 
93
94   !!======================================================================
95END MODULE p4zint
Note: See TracBrowser for help on using the repository browser.