/[MITgcm]/MITgcm/pkg/exf/exf_init_runoff.F
ViewVC logotype

Annotation of /MITgcm/pkg/exf/exf_init_runoff.F

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


Revision 1.7 - (hide annotations) (download)
Fri Aug 15 01:42:44 2003 UTC (20 years, 10 months ago) by dimitri
Branch: MAIN
CVS Tags: checkpoint51j_post, branchpoint-genmake2, checkpoint51h_pre, checkpoint51g_post, checkpoint51f_post, checkpoint51i_pre
Branch point for: branch-genmake2
Changes since 1.6: +3 -3 lines
Modified pkg/exf/exf_interp.F in order to specify option
linear or bi-linear via argument rather than CPP option.

1 heimbach 1.2 #include "EXF_CPPOPTIONS.h"
2    
3     subroutine exf_init_runoff( mythid )
4    
5     c ==================================================================
6     c SUBROUTINE exf_init_runoff
7     c ==================================================================
8     c
9     c o
10     c
11     c started: Ralf.Giering@FastOpt.de 25-Mai-2000
12 dimitri 1.4 c mods for pkg/seaice: menemenlis@jpl.nasa.gov 20-Dec-2002
13 heimbach 1.2 c
14     c ==================================================================
15     c SUBROUTINE exf_init_runoff
16     c ==================================================================
17    
18     implicit none
19    
20     c == global variables ==
21    
22     #include "EEPARAMS.h"
23     #include "SIZE.h"
24     #include "GRID.h"
25    
26     #include "exf_param.h"
27     #include "exf_fields.h"
28     #include "exf_constants.h"
29    
30     c == routine arguments ==
31    
32     integer mythid
33    
34 dimitri 1.4 #if (defined (ALLOW_RUNOFF) || defined (ALLOW_SEAICE))
35 dimitri 1.3
36 heimbach 1.2 c == local variables ==
37    
38 dimitri 1.7 integer bi, bj, i, j, interp_method
39 heimbach 1.2
40     c == end of interface ==
41    
42     do bj = mybylo(mythid), mybyhi(mythid)
43     do bi = mybxlo(mythid), mybxhi(mythid)
44     do j = 1, sny
45     do i = 1, snx
46     runoff(i,j,bi,bj) = 0. _d 0
47     enddo
48     enddo
49     enddo
50     enddo
51    
52 dimitri 1.3 if ( runofffile .NE. ' ' ) then
53 dimitri 1.5 #ifdef USE_EXF_INTERPOLATION
54 dimitri 1.7 interp_method = 2
55 dimitri 1.6 call exf_interp(
56 dimitri 1.5 & runofffile, exf_iprec
57     & , runoff, 1, xC, yC
58     & ,runoff_lon0,runoff_lon_inc
59     & ,runoff_lat0,runoff_lat_inc
60 dimitri 1.7 & ,runoff_nlon,runoff_nlat,interp_method,mythid )
61 dimitri 1.5 #else
62 dimitri 1.3 call mdsreadfield( runofffile, exf_iprec, exf_yftype, 1
63     & , runoff, 1, mythid
64     & )
65 dimitri 1.5 #endif
66 dimitri 1.3 if (exf_yftype .eq. 'RL') then
67     call exf_filter_rl( runoff, runoffmask, mythid )
68     else
69     call exf_filter_rs( runoff, runoffmask, mythid )
70     end if
71    
72 dimitri 1.4 c-- scale runoff array
73 dimitri 1.3 do bj = mybylo(mythid), mybyhi(mythid)
74 dimitri 1.4 do bi = mybxlo(mythid), mybxhi(mythid)
75     do j = 1, sny
76     do i = 1, snx
77     if (runoff(i,j,bi,bj).gt.20.) runoff(i,j,bi,bj)=0.
78     runoff(i,j,bi,bj) = exf_inscal_runoff*runoff(i,j,bi,bj)
79     enddo
80 heimbach 1.2 enddo
81 dimitri 1.4 enddo
82     enddo
83 dimitri 1.3 endif
84 heimbach 1.2
85 dimitri 1.4 #endif
86 heimbach 1.2
87     end

  ViewVC Help
Powered by ViewVC 1.1.22