1 subroutine pccac1 ( nbcham, nocham,
2 > nnfonc, npfonc, obprof, oblopg,
3 > ulsort, langue, codret )
4 c ______________________________________________________________________
8 c Outil de Maillage Adaptatif par Raffinement et Deraffinement d'EDF R&D
10 c Version originale enregistree le 18 juin 1996 sous le numero 96036
11 c aupres des huissiers de justice Simart et Lavoir a Clamart
12 c Version 11.2 enregistree le 13 fevrier 2015 sous le numero 2015/014
13 c aupres des huissiers de justice
14 c Lavoir, Silinski & Cherqui-Abrahmi a Clamart
16 c HOMARD est une marque deposee d'Electricite de France
22 c ______________________________________________________________________
24 c aPres adaptation - mise a jour des CAracteristiques des Champs - 1
26 c ______________________________________________________________________
28 c . nom . e/s . taille . description .
29 c .____________________________________________________________________.
30 c . nbcham . e . 1 . nombre de champs .
31 c . nocham . es . nbcham . nom des objets qui contiennent la .
32 c . . . . description de chaque champ .
33 c . nnfonc . e . char8 . nom de la fonction iteration n .
34 c . npfonc . e . char8 . nom de la fonction iteration n+1 .
35 c . obprof . e . char8 . nom de l'objet profil eventuel .
36 c . oblopg . e . char8 . nom de l'objet localisation eventuelle .
37 c . ulsort . e . 1 . numero d'unite logique de la liste standard.
38 c . langue . e . 1 . langue des messages .
39 c . . . . 1 : francais, 2 : anglais .
40 c . codret . es . 1 . code de retour des modules .
41 c . . . . 0 : pas de probleme .
42 c . . . . 1 : probleme .
43 c ______________________________________________________________________
46 c 0. declarations et dimensionnement
49 c 0.1. ==> generalites
55 parameter ( nompro = 'PCCAC1' )
73 character*8 nocham(nbcham)
74 character*8 npfonc, nnfonc, obprof, oblopg
76 integer ulsort, langue, codret
78 c 0.4. ==> variables locales
80 integer iaux, jaux, kaux
81 integer codre1, codre2, codre3
86 integer adcaen, adcaca
87 integer typgeo, ngauss, nbenmx, nbvapr, nbtyas
88 integer carsup, nbtafo, typint
89 integer advale, advalr, adobch, adprpg, adtyas
92 parameter ( nbmess = 10 )
93 character*80 texte(nblang,nbmess)
95 c 0.5. ==> initialisations
96 c ______________________________________________________________________
106 #ifdef _DEBUG_HOMARD_
107 write (ulsort,texte(langue,1)) 'Entree', nompro
111 texte(1,4) = '(''Etape '',a1,'' : nom de la fonction = '',a8)'
112 texte(1,5) = '(''... Le remplacement de la fonction a eu lieu.'')'
114 texte(2,4) = '(''Stage '',a1,'' : name of the function = '',a8)'
115 texte(2,5) = '(''... Change of function occured.'')'
117 #ifdef _DEBUG_HOMARD_
118 write (ulsort,texte(langue,4)) 'n', nnfonc
119 write (ulsort,texte(langue,4)) 'p' ,npfonc
123 c 2. on passe en revue tous les champs
126 do 20 , nrocha = 1 , nbcham
128 #ifdef _DEBUG_HOMARD_
129 write (ulsort,*) '.. Nom du champ = ',nocham(nrocha)
130 call gmprsx (nompro, nocham(nrocha)//'.Cham_Car' )
133 c 2.1. ==> reperage des noms des fonctions
135 if ( codret.eq.0 ) then
137 call gmliat ( nocham(nrocha), 2, nbtvch, codre1 )
138 call gmadoj ( nocham(nrocha)//'.Cham_Ent', adcaen, iaux, codre2 )
139 call gmadoj ( nocham(nrocha)//'.Cham_Car', adcaca, iaux, codre3 )
141 codre0 = min ( codre1, codre2, codre3 )
142 codret = max ( abs(codre0), codret,
143 > codre1, codre2, codre3 )
147 c 2.2. ==> on parcourt les tableaux
148 c on opere un traitement quand on tombe sur la bonne fonction
150 if ( codret.eq.0 ) then
152 do 21 , nrotv = 1, nbtvch
154 jaux = adcaca + nbincc*(nrotv-1)
156 if ( smem(jaux).eq.nnfonc ) then
158 c 2.2.1. ==> on met a jour le nombre de valeurs
160 if ( codret.eq.0 ) then
162 #ifdef _DEBUG_HOMARD_
163 write (ulsort,texte(langue,3)) 'UTCAFO', nompro
165 call utcafo ( npfonc,
167 > typgeo, ngauss, nbenmx, nbvapr, nbtyas,
168 > carsup, nbtafo, typint,
169 > advale, advalr, adobch, adprpg, adtyas,
170 > ulsort, langue, codret )
174 if ( codret.eq.0 ) then
176 c 1. type de support au sens MED
177 c 2. numero du pas de temps
178 c 4. 1, si numero d'ordre, 0 sinon
180 c 4. nombre de points de Gauss
181 c 5. nombre d'entites support
182 c 6. nombre de valeurs du profil eventuel
183 c 7. nombre de supports associes
184 c 8. noeuds par elements/points de Gauss/autre
185 c 9. numero du 1er tableau dans la fonction
186 c 10. -1 ou champ elga/champ elno
187 c 11. type interpolation
188 c 21-nbinec. type des supports associes
190 jaux = adcaen + nbinec*(nrotv-1)
191 imem(jaux+4) = nbenmx
192 imem(jaux+5) = nbvapr
193 imem(jaux+6) = nbtyas
195 cgn print *,(imem(adtyas+kaux-1),kaux = 1 , nbtyas)
196 do 211 , kaux = 1 , nbtyas
197 imem(jaux+19+kaux) = imem(adtyas+kaux-1)
202 c 2.2.2. ==> on remplace l'ancien nom de la fonction par le nouveau
204 jaux = adcaca + nbincc*(nrotv-1)
206 #ifdef _DEBUG_HOMARD_
207 write (ulsort,texte(langue,5))
210 c 2.2.3. ==> on archive le nom de l'eventuel profil
212 if ( nbvapr.gt.0 ) then
213 smem(jaux+1) = obprof
215 smem(jaux+1) = blan08
218 c 2.2.4. ==> on archive le nom de l'eventuelle localisation
220 smem(jaux+2) = oblopg
228 #ifdef _DEBUG_HOMARD_
229 if ( codret.eq.0 ) then
230 call gmprsx (nompro, nocham(nrocha) )
231 call gmprsx (nompro, nocham(nrocha)//'.Cham_Ent' )
232 call gmprsx (nompro, nocham(nrocha)//'.Cham_Car' )
242 if ( codret.ne.0 ) then
246 write (ulsort,texte(langue,1)) 'Sortie', nompro
247 write (ulsort,texte(langue,2)) codret
251 #ifdef _DEBUG_HOMARD_
252 write (ulsort,texte(langue,1)) 'Sortie', nompro