/[MITgcm]/MITgcm/pkg/matrix/matrix_store_tendency.F
ViewVC logotype

Annotation of /MITgcm/pkg/matrix/matrix_store_tendency.F

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


Revision 1.3 - (hide annotations) (download)
Mon Nov 5 18:58:00 2007 UTC (16 years, 6 months ago) by jmc
Branch: MAIN
CVS Tags: checkpoint63a, checkpoint60, checkpoint61, checkpoint62, checkpoint63, checkpoint59q, checkpoint59p, checkpoint59r, checkpoint59m, checkpoint59l, checkpoint59o, checkpoint59n, checkpoint59k, checkpoint59j, checkpoint62c, checkpoint62b, checkpoint62a, checkpoint62g, checkpoint62f, checkpoint62e, checkpoint62d, checkpoint62k, checkpoint62j, checkpoint62i, checkpoint62h, checkpoint62o, checkpoint62n, checkpoint62m, checkpoint62l, checkpoint62s, checkpoint62r, checkpoint62q, checkpoint62p, checkpoint62w, checkpoint62v, checkpoint62u, checkpoint62t, checkpoint62z, checkpoint62y, checkpoint62x, checkpoint61f, checkpoint61g, checkpoint61d, checkpoint61e, checkpoint61b, checkpoint61c, checkpoint61a, checkpoint61n, checkpoint61o, checkpoint61l, checkpoint61m, checkpoint61j, checkpoint61k, checkpoint61h, checkpoint61i, checkpoint61v, checkpoint61w, checkpoint61t, checkpoint61u, checkpoint61r, checkpoint61s, checkpoint61p, checkpoint61q, checkpoint61z, checkpoint61x, checkpoint61y
Changes since 1.2: +38 -36 lines
split PTRACERS.h in 2 header files: PTRACERS_FIELDS.h & PTRACERS_PARAMS
 declare Namelist in matrix_readparms.F (was previously in MATRIX.h)

1 jmc 1.3 C $Header: /u/gcmpack/MITgcm/pkg/matrix/matrix_store_tendency.F,v 1.2 2005/04/19 18:44:50 edhill Exp $
2 edhill 1.2 C $Name: $
3 spk 1.1
4     #include "PACKAGES_CONFIG.h"
5     #include "CPP_OPTIONS.h"
6 jmc 1.3
7 edhill 1.2 C !ROUTINE MATRIX_STORE_TENDENCY_EXP
8     C This routine accumalates the explicit tendency matrix. Note that
9     C on entry gPtr is the tracer field after explicit advection-
10     C diffusion. On exit, gPtr is set to the initial tracer field for
11     C the next step (implicit matrix calculation).
12 spk 1.1
13 jmc 1.3 SUBROUTINE MATRIX_STORE_TENDENCY_EXP(
14 edhill 1.2 & bi, bj, myTime, myIter, myThid )
15 jmc 1.3
16 spk 1.1 IMPLICIT NONE
17 jmc 1.3 #include "SIZE.h"
18 spk 1.1 #include "EEPARAMS.h"
19 jmc 1.3 #include "PARAMS.h"
20 spk 1.1 #include "PTRACERS_SIZE.h"
21 jmc 1.3 #include "PTRACERS_PARAMS.h"
22     #include "PTRACERS_FIELDS.h"
23     #include "MATRIX.h"
24    
25 spk 1.1 INTEGER bi, bj
26     _RL myTime
27     INTEGER myIter
28     INTEGER myThid
29    
30     #ifdef ALLOW_MATRIX
31    
32 jmc 1.3 INTEGER i,j,k
33     INTEGER iTracer
34 spk 1.1
35     DO iTracer=1,PTRACERS_numInUse
36     DO k=1,Nr
37     DO j=1-Oly, sNy+Oly
38     DO i=1-Olx, sNx+Olx
39 jmc 1.3 MATRIX(i,j,k,bi,bj,iTracer,1) =
40 spk 1.1 & MATRIX(i,j,k,bi,bj,iTracer,1)
41 jmc 1.3 & + (gPtr(i,j,k,bi,bj,iTracer)
42 spk 1.1 & - PTRACERS_initial(i,j,k,bi,bj,iTracer))
43 jmc 1.3 gPtr(i,j,k,bi,bj,iTracer)=
44     & PTRACERS_initial(i,j,k,bi,bj,iTracer)
45 spk 1.1 ENDDO
46     ENDDO
47     ENDDO
48     ENDDO
49    
50     expMatrixCounter = expMatrixCounter + 1
51 jmc 1.3
52 spk 1.1 #endif /* ALLOW_MATRIX */
53 jmc 1.3 RETURN
54 spk 1.1 END
55 jmc 1.3
56 edhill 1.2 C !ROUTINE MATRIX_STORE_TENDENCY_IMP
57     C This routine accumalates the implicit update matrix. Note that on
58     C entry PTR is the tracer field after implicit advection-
59     C diffusion. On exit, PTR is set to the initial tracer field.
60 spk 1.1
61 jmc 1.3 SUBROUTINE MATRIX_STORE_TENDENCY_IMP(
62 edhill 1.2 & bi, bj, myTime, myIter, myThid )
63 jmc 1.3
64 spk 1.1 IMPLICIT NONE
65 jmc 1.3 #include "SIZE.h"
66 spk 1.1 #include "EEPARAMS.h"
67 jmc 1.3 #include "PARAMS.h"
68 spk 1.1 #include "PTRACERS_SIZE.h"
69 jmc 1.3 #include "PTRACERS_PARAMS.h"
70     #include "PTRACERS_FIELDS.h"
71     #include "MATRIX.h"
72    
73 spk 1.1 INTEGER bi, bj
74     _RL myTime
75     INTEGER myIter
76     INTEGER myThid
77    
78     #ifdef ALLOW_MATRIX
79    
80 jmc 1.3 INTEGER i,j,k
81     INTEGER iTracer
82    
83 spk 1.1 DO iTracer=1,PTRACERS_numInUse
84     DO k=1,Nr
85     DO j=1-Oly, sNy+Oly
86     DO i=1-Olx, sNx+Olx
87 jmc 1.3 MATRIX(i,j,k,bi,bj,iTracer,2) =
88     & MATRIX(i,j,k,bi,bj,iTracer,2)
89 spk 1.1 & + pTracer(i,j,k,bi,bj,iTracer)
90 jmc 1.3 pTracer(i,j,k,bi,bj,iTracer)=
91     & PTRACERS_initial(i,j,k,bi,bj,iTracer)
92 spk 1.1 ENDDO
93     ENDDO
94     ENDDO
95     ENDDO
96    
97 jmc 1.3 impMatrixCounter = impMatrixCounter + 1
98    
99 spk 1.1 #endif /* ALLOW_MATRIX */
100 jmc 1.3 RETURN
101 spk 1.1 END
102 jmc 1.3

  ViewVC Help
Powered by ViewVC 1.1.22