/[MITgcm]/MITgcm/pkg/dic/bio_export.F
ViewVC logotype

Annotation of /MITgcm/pkg/dic/bio_export.F

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.8 - (hide annotations) (download)
Thu Oct 13 16:25:12 2005 UTC (18 years, 7 months ago) by stephd
Branch: MAIN
CVS Tags: checkpoint57v_post, checkpoint57y_post, checkpoint57y_pre, checkpoint57x_post, checkpoint57w_post
Changes since 1.7: +6 -0 lines
o add additional switches MINFE - to limit amount of free iron
                          READ_PAR - reads PAR from file, rather
                             than using insol.F

1 edhill 1.3 #include "DIC_OPTIONS.h"
2 stephd 1.1 #include "GCHEM_OPTIONS.h"
3    
4 stephd 1.5 CBOP
5     C !ROUTINE: BIO_EXPORT
6    
7     C !INTERFACE: ==========================================================
8 stephd 1.1 SUBROUTINE BIO_EXPORT( PTR_PO4 ,
9     #ifdef ALLOW_FE
10     I PTR_FE,
11     #endif
12     I bioac,
13     I bi,bj,imin,imax,jmin,jmax,
14     I myIter,myTime,myThid)
15    
16 stephd 1.5 c !DESCRIPTION:
17     C Calculate biological activity and export
18    
19     C !USES: ===============================================================
20 stephd 1.1 IMPLICIT NONE
21     #include "SIZE.h"
22     #include "DYNVARS.h"
23     #include "EEPARAMS.h"
24     #include "PARAMS.h"
25     #include "GRID.h"
26     #include "DIC_ABIOTIC.h"
27     #include "DIC_BIOTIC.h"
28    
29 stephd 1.5 C !INPUT PARAMETERS: ===================================================
30     C myThid :: thread number
31     C myIter :: current timestep
32     C myTime :: current time
33     C PTR_PO4 :: phosphate tracer field
34     C PTR_FE :: iron tracer field
35 stephd 1.1 INTEGER myIter
36     _RL myTime
37     INTEGER myThid
38     _RL PTR_PO4(1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nr)
39     #ifdef ALLOW_FE
40     _RL PTR_FE(1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nr)
41     #endif
42 stephd 1.5 INTEGER imin, imax, jmin, jmax, bi, bj
43    
44    
45     C !OUTPUT PARAMETERS: ==================================================
46     C bioac :: biological productivity (will be split
47     C between export and dissolved pool)
48 stephd 1.1 _RL bioac(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR)
49    
50     #ifdef ALLOW_PTRACERS
51     #ifdef DIC_BIOTIC
52 stephd 1.5
53     C !LOCAL VARIABLES: ====================================================
54     C i,j,k :: loop indices
55 stephd 1.1 INTEGER I,J,k
56 stephd 1.5 _RL sfac(1-OLy:sNy+OLy)
57     _RL lit, atten
58     CEOP
59 stephd 1.8 #ifndef READ_PAR
60 stephd 1.1 call insol(myTime,sfac,bj)
61 stephd 1.8 #endif
62 stephd 1.1 DO j=1-OLy,sNy+OLy
63     DO i=1-OLx,sNx+OLx
64 stephd 1.2 C Fortran-90
65     CRG C$TAF INIT bio_export = static, nlev
66     C FORTRAN-77 dynamic memory uses adstore adresto
67     CRG C$TAF INIT bio_export = memory
68     C FORTRAN-77 with know max of nlev
69     C$TAF INIT bio_export = static, 10
70 stephd 1.8 #ifdef READ_PAR
71     lit=PAR(i,j,bi,bj)
72     #else
73 stephd 1.1 lit=sfac(j)
74 stephd 1.8 #endif
75 stephd 1.1 DO k=1,nlev
76 stephd 1.2 C$TAF STORE lit = bio_export
77 stephd 1.7 atten=(k0*drF(k)*hFacC(i,j,k,bi,bj)*.5)
78     if (k.gt.1) atten=atten+(k0*drF(k-1)
79     & *hFacC(i,j,k-1,bi,bj)*.5)
80 stephd 1.1 lit=lit*exp(-atten)*(1.d0-Fice(i,j,bi,bj))
81     if (lit.lt.0.d0.or.lit.gt.150) then
82     print*,'QQ lit', lit
83     endif
84     bioac(i,j,k)=alpha(i,j,bi,bj)*
85 stephd 1.5 & lit/(lit+lit0)*maskC(i,j,k,bi,bj)*
86 stephd 1.1 #ifdef ALLOW_FE
87 stephd 1.5 & min(PTR_PO4(i,j,k)/(PTR_PO4(i,j,k)+KPO4),
88     & PTR_FE(i,j,k)/(PTR_FE(i,j,k)+KFE) )
89     #else
90     & PTR_PO4(i,j,k)/(PTR_PO4(i,j,k)+KPO4)
91 stephd 1.1 #endif
92     ENDDO
93     ENDDO
94     ENDDO
95     c
96     #endif
97     #endif
98     RETURN
99     END

  ViewVC Help
Powered by ViewVC 1.1.22