The TELEMAC-MASCARET system  trunk
yasmi_waq.f
Go to the documentation of this file.
1 ! ***********************
2  SUBROUTINE yasmi_waq
3 ! ***********************
4  & (yasmi)
5 !
6 !
7 !***********************************************************************
8 ! TELEMAC2D V7P0
9 !***********************************************************************
10 !
11 !brieF tells which tracers will have implicit source terms
12 !
13 !
14 !history R.ATA
15 !+ 12/02/2016
16 !+ V7P2
17 !+ CREATION
18 !
19 ! R. ATA
20 !+ 07/07/2016
21 !+ V7P3
22 !+ ADAPTATION FOR THE NEW MANAGEMENT OF TRACERS
23 !
24 !history S.E. BOURBAN (HRW)
25 !+ 21/09/2017
26 !+ V7P3
27 !+ WAQPROCESS is now a prime number, so that multiple processes
28 !+ can be called by multiplication of the prime numbers.
29 !
30 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
31 !| YASMI |<--| LOGICS FOR IMPLICIT SOURCE TERMS
32 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
33 !
34  USE bief
37  USE interface_waqtel, ex_yasmi_waq => yasmi_waq
38 !
39  IMPLICIT NONE
40 !
41 !+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
42 !
43 !
44  LOGICAL , INTENT(INOUT):: YASMI(*)
45 !
46 !+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
47 !
48  INTEGER :: I
49  LOGICAL :: FOUND
50  found = .false.
51 !
52 !-----------------------------------------------------------------------
53 !
54 ! O2 MODULE
55 !
56  IF( 2*int(waqprocess/2).EQ.waqprocess ) THEN
57 !
58 ! DISSOLVED O2
59  yasmi(ind_o2) = yasmi(ind_o2) .OR. .false.
60 ! ORGANIC LOAD
61  yasmi(ind_ol) = .true.
62 ! NH4 LOAD
63  yasmi(ind_nh4) = .true.
64 !
65  found = .true.
66  ENDIF
67 !
68 !-----------------------------------------------------------------------
69 !
70 ! BIOMASS MODULE
71 !
72  IF( 3*int(waqprocess/3).EQ.waqprocess ) THEN
73 !
74 ! PHYTO BIOMASS
75  yasmi(ind_phy) = yasmi(ind_phy) .OR. .false.
76 ! DISSOLVED PO4
77  yasmi(ind_po4) = yasmi(ind_po4) .OR. .false.
78 ! POR NON ASSIM
79  yasmi(ind_por) = yasmi(ind_por) .OR. .false.
80 ! DISSOLVED NO3
81  yasmi(ind_no3) = yasmi(ind_no3) .OR. .false.
82 ! NO3 NON ASSIM
83  yasmi(ind_nor) = yasmi(ind_nor) .OR. .false.
84 !
85  found = .true.
86  ENDIF
87 !
88 !-----------------------------------------------------------------------
89 !
90 ! EUTRO MODULE
91 !
92  IF( 5*int(waqprocess/5).EQ.waqprocess ) THEN
93 !
94 ! PHYTO BIOMASS
95  yasmi(ind_phy) = yasmi(ind_phy) .OR. .false.
96 ! DISSOLVED PO4
97  yasmi(ind_po4) = yasmi(ind_po4) .OR. .false.
98 ! POR NON ASSIM
99  yasmi(ind_por) = yasmi(ind_por) .OR. .false.
100 ! DISSOLVED NO3
101  yasmi(ind_no3) = yasmi(ind_no3) .OR. .false.
102 ! NOR NON ASSIM
103  yasmi(ind_nor) = yasmi(ind_nor) .OR. .false.
104 ! CHARGE NH4
105  yasmi(ind_nh4) = .true.
106 ! ORGANIC LOAD
107  yasmi(ind_ol) = .true.
108 ! DISSOLVED O2
109  yasmi(ind_o2) = yasmi(ind_o2) .OR. .false.
110 !
111  found = .true.
112  ENDIF
113 !
114 !-----------------------------------------------------------------------
115 !
116 ! MICROPOL MODULE
117 !
118  IF( 7*int(waqprocess/7).EQ.waqprocess ) THEN
119 !
120 ! SUSPENDED LOAD
121  yasmi(ind_ss) = yasmi(ind_ss) .OR. .false.
122 ! BED SEDIMENTS
123  yasmi(ind_sf) = yasmi(ind_sf) .OR. .false.
124 ! MICRO POLLUTANT
125  yasmi(ind_c) = .true.
126 ! ADSORBED SUSPENSION LOAD
127  yasmi(ind_css) = .true.
128 ! ADSORBED BED SED
129  yasmi(ind_csf) = .true.
130 !
131  found = .true.
132  ENDIF
133 !
134 !-----------------------------------------------------------------------
135 !
136 ! THERMIC MODULE
137 !
138  IF( 11*int(waqprocess/11).EQ.waqprocess ) THEN
139 !
140 ! CONSIDERED IMPLICIT BECAUSE ATABOS AND BTABOS ARE IMPLICIT
141  yasmi(ind_t) = .true.
142 !
143  found = .true.
144  ENDIF
145 !
146 !-----------------------------------------------------------------------
147 !
148 ! AED2 COUPLING
149 !
150  IF( 13*int(waqprocess/13).EQ.waqprocess ) THEN
151  found = .true.
152  ENDIF
153 !
154 !-----------------------------------------------------------------------
155 !
156 ! DEGRADATION LAW
157 !
158  IF( 17*int(waqprocess/17).EQ.waqprocess ) THEN
159  found = .true.
160 !
161  DO i = 1,nwaq_degra
162  yasmi(rank_degra(i)) = .true.
163  ENDDO
164 !
165  ENDIF
166 !
167 !-----------------------------------------------------------------------
168 !
169 ! GHOST PROCESS IN WAITING FOR THE MERGE WITH ICE PROCESS
170 !
171  IF( 19*int(waqprocess/19).EQ.waqprocess ) THEN
172  found = .true.
173  ENDIF
174 !
175 !-----------------------------------------------------------------------
176 !
177 ! UNKNOWN PROCESS
178 !
179  IF( .NOT.found ) THEN
180  WRITE(lu,20) waqprocess
181 20 FORMAT(1x,'YASMI_WAQ: UNKNOWN WAQ MODULE: ',i4)
182  CALL plante(1)
183  stop
184  ENDIF
185 !
186 !-----------------------------------------------------------------------
187 !
188  RETURN
189  END
integer, dimension(maxwqvar) rank_degra
subroutine yasmi_waq(YASMI)
Definition: yasmi_waq.f:6
Definition: bief.f:3