1 | !!---------------------------------------------------------------------- |
---|
2 | !! *** trcini.cfc.h90 *** |
---|
3 | !!---------------------------------------------------------------------- |
---|
4 | !! * Module variables |
---|
5 | INTEGER :: & |
---|
6 | inum = 16 ! unit number |
---|
7 | CHARACTER (len=34) :: & |
---|
8 | clname = 'cfc1112.atm' ! ??? |
---|
9 | REAL(wp) :: & |
---|
10 | ylats = -10., & ! 10 degrees south |
---|
11 | ylatn = 10. ! 10 degrees north |
---|
12 | |
---|
13 | CONTAINS |
---|
14 | |
---|
15 | SUBROUTINE trc_ini |
---|
16 | !!--------------------------------------------------------------------- |
---|
17 | !! *** trcini.cfc.h90 *** |
---|
18 | !! |
---|
19 | !! Purpose : special initialization for cfc model |
---|
20 | !! --------- |
---|
21 | !! |
---|
22 | !! |
---|
23 | !! History : |
---|
24 | !! 8.2 ! 04-06 (JC. Dutay) original code |
---|
25 | !! 8.5 ! 05-03 (O. Aumont and A. El Moussaoui F90 |
---|
26 | !! 9.0 ! 05-10 (C. Ethe) Modularity |
---|
27 | !!--------------------------------------------------------------------- |
---|
28 | !! TOP 1.0 , LOCEAN-IPSL (2005) |
---|
29 | !! $Header$ |
---|
30 | !! This software is governed by the CeCILL licence see modipsl/doc/NEMO_CeCILL.txt |
---|
31 | !!--------------------------------------------------------------------- |
---|
32 | !! Local declarations |
---|
33 | INTEGER :: ji, jj, jn, jl, jm |
---|
34 | REAL(wp) :: zyy, zyd |
---|
35 | |
---|
36 | |
---|
37 | ! |
---|
38 | ! Initialization of boundaries conditions |
---|
39 | ! --------------------------------------- |
---|
40 | |
---|
41 | pp_cfc(:,:,:) = 0.0 |
---|
42 | qtr (:,:,:) = 0.0 |
---|
43 | xphem(:,: ) = 0.0 |
---|
44 | |
---|
45 | |
---|
46 | DO jn = 1, jptra |
---|
47 | DO jm = 1, jphem |
---|
48 | DO jl = 1, jpyear |
---|
49 | p_cfc(jl,jm,jn) = 0.0 |
---|
50 | END DO |
---|
51 | END DO |
---|
52 | ENDDO |
---|
53 | |
---|
54 | |
---|
55 | ! Initialization of qint in case of no restart |
---|
56 | !---------------------------------------------- |
---|
57 | IF( .NOT. lrsttr ) THEN |
---|
58 | IF(lwp) THEN |
---|
59 | WRITE(numout,*) |
---|
60 | WRITE(numout,*) 'Initialization de qint ; No restart : qint equal zero ' |
---|
61 | ENDIF |
---|
62 | DO jn = 1, jptra |
---|
63 | DO jj = 1, jpj |
---|
64 | DO ji = 1, jpi |
---|
65 | qint(ji,jj,jn) = 0. |
---|
66 | END DO |
---|
67 | END DO |
---|
68 | ENDDO |
---|
69 | ENDIF |
---|
70 | |
---|
71 | |
---|
72 | ! |
---|
73 | ! READ CFC partial pressure atmospheric value : |
---|
74 | ! p11(year,nt) = PCFC11 in northern (1) and southern (2) hemisphere |
---|
75 | ! p12(year,nt) = PCFC12 in northern (1) and southern (2) hemisphere |
---|
76 | !-------------------------------------------------------------------- |
---|
77 | |
---|
78 | IF(lwp) WRITE(numout,*) 'read of formatted file cfc1112atm' |
---|
79 | |
---|
80 | OPEN( UNIT = inum, FORM = 'FORMATTED',FILE = clname, STATUS = 'OLD') |
---|
81 | REWIND(inum) |
---|
82 | |
---|
83 | |
---|
84 | ! Skip over 1st six descriptor lines |
---|
85 | !----------------------------------- |
---|
86 | DO jm = 1, 6 |
---|
87 | READ(inum,'(1x)') |
---|
88 | END DO |
---|
89 | |
---|
90 | |
---|
91 | ! Read file |
---|
92 | ! --------- |
---|
93 | DO jn = 31, 98 |
---|
94 | READ(inum,*) zyy, p_cfc(jn,1,jp11), p_cfc(jn,1,jp12), & |
---|
95 | & p_cfc(jn,2,jp11), p_cfc(jn,2,jp12) |
---|
96 | WRITE(numout,'(f7.2, 4f8.2)' ) & |
---|
97 | & zyy, p_cfc(jn,1,jp11), p_cfc(jn,1,jp12), & |
---|
98 | & p_cfc(jn,2,jp11), p_cfc(jn,2,jp12) |
---|
99 | END DO |
---|
100 | |
---|
101 | p_cfc(32,1:2,jp11) = 5.e-4 |
---|
102 | p_cfc(33,1:2,jp11) = 8.e-4 |
---|
103 | p_cfc(34,1:2,jp11) = 1.e-6 |
---|
104 | p_cfc(35,1:2,jp11) = 2.e-3 |
---|
105 | p_cfc(36,1:2,jp11) = 4.e-3 |
---|
106 | p_cfc(37,1:2,jp11) = 6.e-3 |
---|
107 | p_cfc(38,1:2,jp11) = 8.e-3 |
---|
108 | p_cfc(39,1:2,jp11) = 1.e-2 |
---|
109 | |
---|
110 | |
---|
111 | IF(lwp) THEN |
---|
112 | WRITE(numout,*) |
---|
113 | WRITE(numout,*) ' Year p11HN p11HS p12HN p12HS ' |
---|
114 | DO jn = 30, 100 |
---|
115 | WRITE(numout, '( 1I4, 4F9.2)') & |
---|
116 | & jn, p_cfc(jn,1,jp11), p_cfc(jn,2,jp11), & |
---|
117 | & p_cfc(jn,1,jp12), p_cfc(jn,2,jp12) |
---|
118 | END DO |
---|
119 | ENDIF |
---|
120 | |
---|
121 | |
---|
122 | ! Interpolation factor of atmospheric partial pressure |
---|
123 | ! Linear interpolation between 2 hemispheric function of latitud between ylats and ylatn |
---|
124 | !--------------------------------------------------------------------------------------- |
---|
125 | zyd = ylatn - ylats |
---|
126 | DO jj = 1 , jpj |
---|
127 | DO ji = 1 , jpi |
---|
128 | IF( gphit(ji,jj) .GE. ylatn ) THEN |
---|
129 | xphem(ji,jj) = 1. |
---|
130 | ELSE IF (gphit(ji,jj) .LE. ylats) THEN |
---|
131 | xphem(ji,jj) = 0. |
---|
132 | ELSE |
---|
133 | xphem(ji,jj) = ( gphit(ji,jj) - ylats) / zyd |
---|
134 | ENDIF |
---|
135 | END DO |
---|
136 | END DO |
---|
137 | |
---|
138 | END SUBROUTINE trc_ini |
---|