1 subroutine deinz0 ( option,
5 > coonoe, dimcst, coocst,
7 > ulsort, langue, codret )
8 c ______________________________________________________________________
12 c Outil de Maillage Adaptatif par Raffinement et Deraffinement d'EDF R&D
14 c Version originale enregistree le 18 juin 1996 sous le numero 96036
15 c aupres des huissiers de justice Simart et Lavoir a Clamart
16 c Version 11.2 enregistree le 13 fevrier 2015 sous le numero 2015/014
17 c aupres des huissiers de justice
18 c Lavoir, Silinski & Cherqui-Abrahmi a Clamart
20 c HOMARD est une marque deposee d'Electricite de France
26 c ______________________________________________________________________
28 c traitement des DEcisions - INitialisation de l'indicateur
30 c defini par des Zones de raffinement
32 c phase 0 : boite parallelepipedique
34 c ______________________________________________________________________
36 c . nom . e/s . taille . description .
37 c .____________________________________________________________________.
38 c . option . e . 1 . 1 : raffinement, -1 : deraffinement .
39 c .xmin/max. e . 1 . caracteristiques du parallelepipede .
42 c . coonoe . e . nbnoto . coordonnees des noeuds .
43 c . dimcst . e . 1 . dimension de la coordonnee constante .
44 c . . . . eventuelle, 0 si toutes varient .
45 c . coocst . e . 11 . 1 : coordonnee constante eventuelle .
46 c . . . . 2, 3, 4 : xmin, ymin, zmin .
47 c . . . . 5, 6, 7 : xmax, ymax, zmax .
48 c . . . . 8, 9, 10 : -1 si constant, max-min sinon .
49 c . . . . 11 : max des (max-min) .
50 c . nozone . aux . nbnoto . auxiliaire pour le transfert zone/noeud .
51 c . ulsort . e . 1 . numero d'unite logique de la liste standard.
52 c . langue . e . 1 . langue des messages .
53 c . . . . 1 : francais, 2 : anglais .
54 c . codret . es . 1 . code de retour des modules .
55 c . . . . 0 : pas de probleme .
56 c . . . . 2 : probleme dans le traitement .
57 c ______________________________________________________________________
60 c 0. declarations et dimensionnement
63 c 0.1. ==> generalites
69 parameter ( nompro = 'DEINZ0' )
84 integer nozone(nbnoto)
86 double precision xmin, xmax, ymin, ymax, zmin, zmax
87 double precision coonoe(nbnoto,sdim)
88 double precision coocst(11)
90 integer ulsort, langue, codret
92 c 0.4. ==> variables locales
97 double precision xminlo, xmaxlo, yminlo, ymaxlo, zminlo, zmaxlo
100 parameter (nbmess = 10 )
101 character*80 texte(nblang,nbmess)
103 c 0.5. ==> initialisations
104 c ______________________________________________________________________
105 #ifdef _DEBUG_HOMARD_
106 character*1 saux01(3)
107 data saux01 / 'X', 'Y', 'Z' /
116 #ifdef _DEBUG_HOMARD_
117 write (ulsort,texte(langue,1)) 'Entree', nompro
121 texte(1,4) = '(''Zone parellepipedique'')'
122 texte(1,5) = '(''Prise en compte du noeud '',i10,3g15.7)'
124 texte(2,4) = '(''Zone as a brick'')'
125 texte(2,5) = '(''OK for node # '',i10,3g15.7)'
129 #ifdef _DEBUG_HOMARD_
130 write (ulsort,texte(langue,4))
131 write (ulsort,90034) 'Xmin', xmin, 'Xmax', xmax
132 write (ulsort,90034) 'Ymin', ymin, 'Ymax', ymax
133 write (ulsort,90034) 'Zmin', zmin, 'Zmax', zmax
134 write (ulsort,90002) 'sdim', sdim
135 write (ulsort,90002) 'dimcst', dimcst
136 if ( dimcst.ne.0 ) then
137 write (ulsort,90004) saux01(dimcst)//' constant', coocst(dimcst+1)
139 write (ulsort,90002) 'maextr', maextr
146 if ( sdim.eq.3 ) then
148 do 21 , iaux = 1, nbnoto
150 #ifdef _DEBUG_HOMARD_
151 write(ulsort,90004) 'X', coonoe(iaux,1), xmin, xmax
152 write(ulsort,90004) 'Y', coonoe(iaux,2), ymin, ymax
153 write(ulsort,90004) 'Z', coonoe(iaux,3), zmin, zmax
155 if ( coonoe(iaux,1).lt.xmin ) then
157 elseif ( coonoe(iaux,1).gt.xmax ) then
159 elseif ( coonoe(iaux,2).lt.ymin ) then
161 elseif ( coonoe(iaux,2).gt.ymax ) then
163 elseif ( coonoe(iaux,3).lt.zmin ) then
165 elseif ( coonoe(iaux,3).gt.zmax ) then
168 #ifdef _DEBUG_HOMARD_
169 write(ulsort,texte(langue,5)) iaux,
170 > coonoe(iaux,1), coonoe(iaux,2), coonoe(iaux,3)
172 nozone(iaux) = option
177 c 3. Du vrai 2D ou du 2D defini dans un espace 3D
178 c . Avec du vrai 2D, on part du principe que Z est nul
179 c . Avec du 2D immerge, on repere
180 c . On verifie que la coordonnee constante est compatible,
181 c avec une certaine tolerance
186 if ( ( dimcst.eq.0 .or. dimcst.eq.3 ) .and.
187 > ( maextr.eq.0 .or. maextr.eq.3 ) ) then
195 daux = max(coocst(8), coocst(9))
196 elseif ( dimcst.eq.1 .or. maextr.eq.1 ) then
204 daux = max(coocst(9), coocst(10))
205 elseif ( dimcst.eq.2 .or. maextr.eq.2 ) then
213 daux = max(coocst(10), coocst(8))
216 #ifdef _DEBUG_HOMARD_
217 write (ulsort,texte(langue,4))
218 write (ulsort,90034) 'Xminlo', xminlo, 'Xmaxlo', xmaxlo
219 write (ulsort,90034) 'Yminlo', yminlo, 'Ymaxlo', ymaxlo
220 write (ulsort,90034) 'Zminlo', zminlo, 'Zmaxlo', zmaxlo
224 if ( zminlo.gt.coocst(jaux)+daux .or.
225 > zmaxlo.lt.coocst(jaux)-daux ) then
229 do 31 , iaux = 1, nbnoto
231 if ( coonoe(iaux,1).lt.xminlo ) then
233 elseif ( coonoe(iaux,1).gt.xmaxlo ) then
235 elseif ( coonoe(iaux,2).lt.yminlo ) then
237 elseif ( coonoe(iaux,2).gt.ymaxlo ) then
240 #ifdef _DEBUG_HOMARD_
241 write(ulsort,texte(langue,5)) iaux,
242 > coonoe(iaux,1), coonoe(iaux,2)
244 nozone(iaux) = option
256 if ( codret.ne.0 ) then
259 write (ulsort,texte(langue,1)) 'Sortie', nompro
260 write (ulsort,texte(langue,2)) codret
264 #ifdef _DEBUG_HOMARD_
265 write (ulsort,texte(langue,1)) 'Sortie', nompro