Salome HOME
Homard executable
[modules/homard.git] / src / tool / Suivi_Frontiere / sfconv.F
1       subroutine sfconv ( lgopti, taopti, lgopts, taopts,
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 - CONV de la geometrie du format MED au format C
25 c   -        -           ----
26 c ______________________________________________________________________
27 c .  nom   . e/s . taille .           description                      .
28 c .____________________________________________________________________.
29 c . lgopti . e   .   1    . longueur du tableau des options            .
30 c . taopti . e   . lgopti . tableau des options                        .
31 c . lgopts . e   .   1    . longueur du tableau des options caracteres .
32 c . taopts . e   . lgopts . tableau des options caracteres             .
33 c . lgetco . e   .   1    . longueur du tableau de l'etat courant      .
34 c . taetco . e   . lgetco . tableau de l'etat courant                  .
35 c . ulsort . e   .   1    . numero d'unite logique de la liste standard.
36 c . langue . e   .    1   . langue des messages                        .
37 c .        .     .        . 1 : francais, 2 : anglais                  .
38 c . codret . es  .    1   . code de retour des modules                 .
39 c .        .     .        . 0 : pas de probleme                        .
40 c .        .     .        . 2 : probleme avec la memoire               .
41 c .        .     .        . 3 : probleme avec le fichier               .
42 c .        .     .        . 5 : contenu incorrect                      .
43 c ______________________________________________________________________
44 c
45 c====
46 c 0. declarations et dimensionnement
47 c====
48 c
49 c 0.1. ==> generalites
50 c
51       implicit none
52       save
53 c
54       character*6 nompro
55       parameter ( nompro = 'SFCONV' )
56 c
57 #include "motcle.h"
58 #include "nblang.h"
59 c
60 c 0.2. ==> communs
61 c
62 #include "envex1.h"
63 c
64 c 0.3. ==> arguments
65 c
66       integer lgopti
67       integer taopti(lgopti)
68 c
69       integer lgopts
70       character*8 taopts(lgopts)
71 c
72       integer lgetco
73       integer taetco(lgetco)
74 c
75       integer ulsort, langue, codret
76 c
77 c 0.4. ==> variables locales
78 c
79       integer nretap, nrsset
80       integer iaux
81       character*6 saux
82       character*8 nohman
83       character*8 mafrmd, nocdfr, ncafdg
84 c
85       integer nbmess
86       parameter ( nbmess = 10 )
87       character*80 texte(nblang,nbmess)
88 c
89 c 0.5. ==> initialisations
90 c ______________________________________________________________________
91 c
92 c====
93 c 1. messages
94 c====
95 c
96 c 1.1. ==> les messages
97 c
98 #include "impr01.h"
99 c
100 #ifdef _DEBUG_HOMARD_
101       write (ulsort,texte(langue,1)) 'Entree', nompro
102       call dmflsh (iaux)
103 #endif
104 c
105       texte(1,4) = '(/,a6,'' CONVERSION DE LA FRONTIERE DISCRETE'')'
106       texte(1,5) = '(42(''=''),/)'
107 c
108       texte(2,4) = '(/,a6,'' CONVERSION OF DISCRETE BOUNDARY'')'
109       texte(2,5) = '(38(''=''),/)'
110 c
111 c 1.2. ==> le numero de sous-etape
112 c
113       nretap = taetco(1)
114       nrsset = taetco(2) + 1
115       taetco(2) = nrsset
116 c
117       call utcvne ( nretap, nrsset, saux, iaux, codret )
118 c
119 c 1.3. ==> le titre
120 c
121       write (ulsort,texte(langue,4)) saux
122       write (ulsort,texte(langue,5))
123 c
124 c====
125 c 2. les structures de base
126 c====
127 c
128 c 2.1. ==> le maillage HOMARD
129 c
130       nohman = taopts(3)
131 c
132 c 2.2. ==> le maillage MED de la frontiere
133 c
134       mafrmd = taopts(16)
135 c
136 c 2.3. ==> les groupes definissant la frontiere
137 c
138       ncafdg = taopts(17)
139 c
140 c====
141 c 3. traitement
142 c====
143 c
144       if ( codret.eq.0 ) then
145 c
146 #ifdef _DEBUG_HOMARD_
147       write (ulsort,texte(langue,3)) 'SFCON1', nompro
148 #endif
149       call sfcon1 ( taopti(11), taopti(39),
150      >              nohman, mafrmd, nocdfr, ncafdg,
151      >              ulsort, langue, codret )
152 c
153       endif
154 c
155       if ( codret.eq.0 ) then
156 c
157       taopts(16) = nocdfr
158 c
159       endif
160 c
161 c====
162 c 4. la fin
163 c====
164 c
165       if ( codret.ne.0 ) then
166 c
167 #include "envex2.h"
168 c
169       write (ulsort,texte(langue,1)) 'Sortie', nompro
170       write (ulsort,texte(langue,2)) codret
171 c
172       endif
173 c
174 #ifdef _DEBUG_HOMARD_
175       write (ulsort,texte(langue,1)) 'Sortie', nompro
176       call dmflsh (iaux)
177 #endif
178 c
179       end