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.
sedsfc.F90 in trunk/NEMOGCM/NEMO/TOP_SRC/SED – NEMO

source: trunk/NEMOGCM/NEMO/TOP_SRC/SED/sedsfc.F90 @ 2761

Last change on this file since 2761 was 2761, checked in by cetlod, 13 years ago

Changes in sediment model to use with dynamic memory, see ticket #821

  • Property svn:keywords set to Id
File size: 2.7 KB
Line 
1MODULE sedsfc
2   !!======================================================================
3   !!              ***  MODULE  sedsfc  ***
4   !!    Sediment : Data at sediment surface
5   !!=====================================================================
6#if defined key_sed && ! defined key_sed_off
7   !! * Modules used
8   USE sed     ! sediment global variable
9   USE sedarr
10   USE seddta
11
12   PUBLIC sed_sfc
13
14CONTAINS
15
16   SUBROUTINE sed_sfc( kt )
17      !!---------------------------------------------------------------------
18      !!                  ***  ROUTINE sed_sfc ***
19      !!
20      !! ** Purpose :  Give data from sediment model to tracer model
21      !!
22      !!
23      !!   History :
24      !!        !  06-04 (C. Ethe)  Orginal code
25      !!----------------------------------------------------------------------
26      !!* Arguments
27      INTEGER, INTENT(in) ::  kt              ! time step
28
29      ! * local variables
30      INTEGER :: ji, jj, ikt     ! dummy loop indices
31
32      !------------------------------------------------------------------------
33
34      IF( kt == nitsed000 ) THEN
35         WRITE(numsed,*) ' sed_sfc : Give data from sediment model to tracer model  '
36         WRITE(numsed,*) ' '
37      ENDIF
38
39      ! reading variables
40
41      CALL unpack_arr ( jpoce, trc_data(1:jpi,1:jpj,1), iarroce(1:jpoce), pwcp(1:jpoce,1,jwalk) )
42      CALL unpack_arr ( jpoce, trc_data(1:jpi,1:jpj,2), iarroce(1:jpoce), pwcp(1:jpoce,1,jwdic) )
43      CALL unpack_arr ( jpoce, trc_data(1:jpi,1:jpj,3), iarroce(1:jpoce), pwcp(1:jpoce,1,jwno3) )
44      CALL unpack_arr ( jpoce, trc_data(1:jpi,1:jpj,4), iarroce(1:jpoce), pwcp(1:jpoce,1,jwpo4) )
45      CALL unpack_arr ( jpoce, trc_data(1:jpi,1:jpj,5), iarroce(1:jpoce), pwcp(1:jpoce,1,jwoxy) )
46      CALL unpack_arr ( jpoce, trc_data(1:jpi,1:jpj,6), iarroce(1:jpoce), pwcp(1:jpoce,1,jwsil) )
47
48
49      DO jj = 1,jpj
50         DO ji = 1, jpi
51            ikt = mbkt(ji,jj)
52            IF ( tmask(ji,jj,ikt) == 1 ) THEN
53               trn(ji,jj,ikt,jptal) = trc_data(ji,jj,1)
54               trn(ji,jj,ikt,jpdic) = trc_data(ji,jj,2)
55               trn(ji,jj,ikt,jpno3) = trc_data(ji,jj,3) * 7.6
56               trn(ji,jj,ikt,jppo4) = trc_data(ji,jj,4) * 122.
57               trn(ji,jj,ikt,jpoxy) = trc_data(ji,jj,5)
58               trn(ji,jj,ikt,jpsil) = trc_data(ji,jj,6)
59            ENDIF
60         ENDDO
61      ENDDO
62
63   END SUBROUTINE sed_sfc
64
65#else
66   !!======================================================================
67   !! MODULE sedsfc  :   Dummy module
68   !!======================================================================
69CONTAINS
70   SUBROUTINE sed_sfc ( kt )
71      INTEGER, INTENT(in) :: kt
72      WRITE(*,*) 'sed_sfc: You should not have seen this print! error?', kt
73   END SUBROUTINE sed_sfc
74#endif
75
76END MODULE sedsfc
Note: See TracBrowser for help on using the repository browser.