/[MITgcm]/MITgcm/pkg/cost/cost_readargot.F
ViewVC logotype

Contents of /MITgcm/pkg/cost/cost_readargot.F

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


Revision 1.1.2.1 - (show annotations) (download)
Thu Jun 19 15:21:16 2003 UTC (21 years ago) by heimbach
Branch: ecco-branch
CVS Tags: ecco_c50_e33, ecco_c51_e34d, ecco_c51_e34e, ecco_c51_e34f, ecco_c51_e34g, ecco_c51_e34a, ecco_c51_e34b, ecco_c51_e34c, ecco_c50_e33a, ecco_c51_e34
Changes since 1.1: +100 -0 lines
o Merged G. Gebbie's obcs code.
o Merged A. Koeh's new cost contributions
o Minor cleanups (in particular cost_averages...)

1 C $Header: /u/gcmpack/development/heimbach/ecco_env/pkg/cost/cost_readsstfields.F,v 1.5 2001/02/12 19:40:54 heimbach Exp $
2
3 #include "COST_CPPOPTIONS.h"
4
5
6 subroutine cost_Readargot(
7 I irec,
8 I mythid
9 & )
10
11 c ==================================================================
12 c SUBROUTINE cost_Readargot
13 c ==================================================================
14 c
15 c o Read a given record of the
16 c
17 c started:Armin Koehl akoehl@ucsd.edu
18 c - Restructured the code in order to create a package
19 c for the MITgcmUV.
20 c
21 c ==================================================================
22 c SUBROUTINE cost_Readargot
23 c ==================================================================
24
25 implicit none
26
27 c == global variables ==
28
29 #include "EEPARAMS.h"
30 #include "SIZE.h"
31 #include "PARAMS.h"
32 #include "GRID.h"
33
34 #include "cal.h"
35 #include "cost.h"
36
37 c == routine arguments ==
38
39 integer irec
40 integer mythid
41
42 c == local variables ==
43
44 integer bi,bj
45 integer i,j,k
46 integer itlo,ithi
47 integer jtlo,jthi
48 integer jmin,jmax
49 integer imin,imax
50 integer nobs
51 integer argotrec
52 integer beginargot
53 integer beginrun
54
55 _RL spval
56 _RL vartile
57
58 c == end of interface ==
59
60 parameter (spval = -9999. )
61 ce --> there is certainly a better place for this.
62
63 jtlo = mybylo(mythid)
64 jthi = mybyhi(mythid)
65 itlo = mybxlo(mythid)
66 ithi = mybxhi(mythid)
67 jmin = 1
68 jmax = sny
69 imin = 1
70 imax = snx
71
72 beginargot = argotstartdate(1)/10000
73 beginrun = modelstartdate(1)/10000
74 if ( beginargot .eq. beginrun ) then
75 argotrec = mod(modelstartdate(1)/100,100) -
76 & mod(argotstartdate(1)/100,100) + irec
77 else
78 argotrec = ( beginrun - beginargot - 1)*nmonthyear +
79 & (nmonthyear - mod(argotstartdate(1)/100,100) +
80 & 1) + mod(modelstartdate(1)/100,100) - 1 + irec
81 endif
82 if (argotrec.gt.0) then
83 call mdsreadfield( argotfile, cost_iprec, cost_yftype, nr,
84 & argotobs,argotrec, mythid )
85 else
86 do bj = jtlo,jthi
87 do bi = itlo,ithi
88 do k = 1,nr
89 do j = jmin,jmax
90 do i = imin,imax
91 argotobs(i,j,k,bi,bj)=spval
92 enddo
93 enddo
94 enddo
95 enddo
96 enddo
97 endif
98 return
99 end
100

  ViewVC Help
Powered by ViewVC 1.1.22