]> SALOME platform Git repositories - modules/homard.git/blob - src/tool/Suivi_Frontiere/sfprep.F
Salome HOME
Merge branch 'V9_13_BR'
[modules/homard.git] / src / tool / Suivi_Frontiere / sfprep.F
1       subroutine sfprep ( nomail, nocdfr,
2      >                    lgetco, taetco,
3      >                    ulsort, langue, codret )
4 c ______________________________________________________________________
5 c
6 c                             H O M A R D
7 c
8 c Outil de Maillage Adaptatif par Raffinement et Deraffinement d'EDF R&D
9 c
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
15 c
16 c    HOMARD est une marque deposee d'Electricite de France
17 c
18 c Copyright EDF 1996
19 c Copyright EDF 1998
20 c Copyright EDF 2002
21 c Copyright EDF 2020
22 c ______________________________________________________________________
23 c
24 c   Suivi de Frontiere : PREParation
25 c   --                   ---
26 c ______________________________________________________________________
27 c .        .     .        .                                            .
28 c .  nom   . e/s . taille .           description                      .
29 c .____________________________________________________________________.
30 c . nomail . e   . char8  . nom de l'objet maillage homard iter. n+1   .
31 c . nocdfr . e   . char8  . nom de l'objet description de la frontiere .
32 c . lgetco . e   .   1    . longueur du tableau de l'etat courant      .
33 c . taetco . e   . lgetco . tableau de l'etat courant                  .
34 c . ulsort . e   .   1    . numero d'unite logique de la liste standard.
35 c . langue . e   .    1   . langue des messages                        .
36 c .        .     .        . 1 : francais, 2 : anglais                  .
37 c . codret . es  .    1   . code de retour des modules                 .
38 c .        .     .        . en entree = celui du module d'avant        .
39 c .        .     .        . en sortie = celui du module en cours       .
40 c .        .     .        . 0 : pas de probleme                        .
41 c .        .     .        . 1 : manque de temps cpu                    .
42 c .        .     .        . 2x : probleme dans les memoires            .
43 c .        .     .        . 3x : probleme dans les fichiers            .
44 c .        .     .        . 5 : mauvaises options                      .
45 c .        .     .        . 6 : problemes dans les noms d'objet        .
46 c ______________________________________________________________________
47 c
48 c====
49 c 0. declarations et dimensionnement
50 c====
51 c
52 c 0.1. ==> generalites
53 c
54       implicit none
55       save
56 c
57       character*6 nompro
58       parameter ( nompro = 'SFPREP' )
59 c
60 #include "motcle.h"
61 #include "nblang.h"
62 c
63 c 0.2. ==> communs
64 c
65 #include "envex1.h"
66 c
67 #include "gmenti.h"
68 c
69 #include "envca1.h"
70 c
71 c 0.3. ==> arguments
72 c
73       character*8 nomail, nocdfr
74 c
75       integer lgetco
76       integer taetco(lgetco)
77 c
78       integer ulsort, langue, codret
79 c
80 c 0.4. ==> variables locales
81 c
82       integer iaux, jaux
83 c
84       integer pcoono
85       integer psomar, phetar, pnp2ar
86       integer pcfaar, pfamar
87       integer psegli, pnumli
88 c
89       integer codre0, codre1, codre2
90 c
91 #ifdef _DEBUG_HOMARD_
92       character*8 action
93       parameter ( action = 'sufr    ' )
94 #endif
95       character*8 norenu
96       character*8 nhnoeu, nhmapo, nharet, nhtria, nhquad
97       character*8 nhtetr, nhhexa, nhpyra, nhpent
98       character*8 nhelig
99       character*8 nhvois, nhsupe, nhsups
100 c
101 #ifdef _DEBUG_HOMARD_
102       character*6 nompra
103 #endif
104 c
105       integer nbmess
106       parameter ( nbmess = 20 )
107       character*80 texte(nblang,nbmess)
108 c
109 c 0.5. ==> initialisations
110 c ______________________________________________________________________
111 c
112 c====
113 c 1. messages
114 c====
115 c
116 #include "impr01.h"
117 c
118 #ifdef _DEBUG_HOMARD_
119       write (ulsort,texte(langue,1)) 'Entree', nompro
120       call dmflsh (iaux)
121 #endif
122 c
123 #include "impr03.h"
124 c
125 #ifdef _DEBUG_HOMARD_
126       if ( codret.eq.0 ) then
127 c
128       iaux = 0
129       call utveri ( action, nomail, nompro, iaux,
130      >              ulsort, langue, codret )
131 c
132       endif
133 #endif
134 c
135 c====
136 c 2. recuperation des pointeurs
137 c====
138 c
139 c 2.1. ==> structure generale
140 c
141       if ( codret.eq.0 ) then
142 c
143 #ifdef _DEBUG_HOMARD_
144       write (ulsort,texte(langue,3)) 'UTNOMH', nompro
145 #endif
146       call utnomh ( nomail,
147      >                sdim,   mdim,
148      >               degre, maconf, homolo, hierar,
149      >              rafdef, nbmane, typcca, typsfr, maextr,
150      >              mailet,
151      >              norenu,
152      >              nhnoeu, nhmapo, nharet,
153      >              nhtria, nhquad,
154      >              nhtetr, nhhexa, nhpyra, nhpent,
155      >              nhelig,
156      >              nhvois, nhsupe, nhsups,
157      >              ulsort, langue, codret)
158 c
159       endif
160 c
161 c 2.2.==> tableaux
162 c
163       if ( codret.eq.0 ) then
164 c
165 #ifdef _DEBUG_HOMARD_
166       write (ulsort,texte(langue,3)) 'UTAD01', nompro
167 #endif
168       iaux = 3
169       call utad01 ( iaux, nhnoeu,
170      >                jaux,
171      >                jaux,   jaux,   jaux,
172      >              pcoono,   jaux,   jaux,   jaux,
173      >              ulsort, langue, codret )
174 c
175       endif
176 c
177       if ( codret.eq.0 ) then
178 c
179 #ifdef _DEBUG_HOMARD_
180       write (ulsort,texte(langue,3)) 'UTAD02_ar', nompro
181 #endif
182       iaux = 518
183       if ( degre.eq.2 ) then
184         iaux = iaux*13
185       endif
186       call utad02 ( iaux, nharet,
187      >              phetar, psomar, jaux, jaux,
188      >              pfamar, pcfaar,   jaux,
189      >                jaux, pnp2ar,   jaux,
190      >                jaux,   jaux,   jaux,
191      >              ulsort, langue, codret )
192 c
193       endif
194 c
195 c====
196 c 3. Particularites de la frontiere discrete
197 c====
198 #ifdef _DEBUG_HOMARD_
199       write (ulsort,90002) '3. frontiere discrete ; codret', codret
200 #endif
201 c
202 c 3.1.==> Description de la frontiere discrete
203 c
204       if ( codret.eq.0 ) then
205 c
206       call gmadoj ( nocdfr//'.PtrSomLi', psegli, iaux, codre1 )
207       call gmadoj ( nocdfr//'.NumeLign', pnumli, iaux, codre2 )
208 c
209       codre0 = min ( codre1, codre2 )
210       codret = max ( abs(codre0), codret,
211      >               codre1, codre2 )
212 c
213       endif
214 c
215 c 3.2. ==> Compactage des numeros de ligne
216 c
217 #ifdef _DEBUG_HOMARD_
218       write (ulsort,90002) '3.2 compactage nros ligne ; codret', codret
219 #endif
220 c
221       if ( codret.eq.0 ) then
222 c
223       iaux = 0
224 #ifdef _DEBUG_HOMARD_
225       write (ulsort,texte(langue,3)) 'SFNULI', nompro
226 #endif
227       call sfnuli ( imem(pcfaar), imem(pnumli), iaux,
228      >              lgetco, taetco,
229      >              ulsort, langue, codret )
230 c
231       endif
232 c
233 #ifdef _DEBUG_HOMARD_
234       if ( codret.eq.0 ) then
235 c
236       nompra = 'sfnuli'
237       iaux = 2
238       call utveri ( action, nomail, nompra, iaux,
239      >              ulsort, langue, codret )
240 c
241       endif
242 #endif
243 c
244 c====
245 c 4. la fin
246 c====
247 c
248 #ifdef _DEBUG_HOMARD_
249       if ( codret.eq.0 ) then
250 c
251       iaux = 2
252       call utveri ( action, nomail, nompro, iaux,
253      >              ulsort, langue, codret )
254 c
255       endif
256 #endif
257 c
258       if ( codret.ne.0 ) then
259 c
260 #include "envex2.h"
261 c
262       write (ulsort,texte(langue,1)) 'Sortie', nompro
263       write (ulsort,texte(langue,2)) codret
264 c
265       endif
266 c
267 #ifdef _DEBUG_HOMARD_
268       write (ulsort,texte(langue,1)) 'Sortie', nompro
269       call dmflsh (iaux)
270 #endif
271 c
272       end