Salome HOME
Homard executable
[modules/homard.git] / src / tool / Gestion_MTU / gubila.F
1       subroutine gubila ( codfic )
2 c ______________________________________________________________________
3 c
4 c                             H O M A R D
5 c
6 c Outil de Maillage Adaptatif par Raffinement et Deraffinement d'EDF R&D
7 c
8 c Version originale enregistree le 18 juin 1996 sous le numero 96036
9 c aupres des huissiers de justice Simart et Lavoir a Clamart
10 c Version 11.2 enregistree le 13 fevrier 2015 sous le numero 2015/014
11 c aupres des huissiers de justice
12 c Lavoir, Silinski & Cherqui-Abrahmi a Clamart
13 c
14 c    HOMARD est une marque deposee d'Electricite de France
15 c
16 c Copyright EDF 1996
17 c Copyright EDF 1998
18 c Copyright EDF 2002
19 c Copyright EDF 2020
20 c ______________________________________________________________________
21 c
22 c but : - imprime les statistiques
23 c       - ferme toutes les unites logiques, sauf l'entree et la sortie
24 c         standard
25 c ______________________________________________________________________
26 c .        .     .        .                                            .
27 c .  nom   . e/s . taille .           description                      .
28 c .____________________________________________________________________.
29 c . codfic . e   .    1   . code pilotant le type d'info a imprimer    .
30 c ______________________________________________________________________
31 c
32 c====
33 c 0. declarations et dimensionnement
34 c====
35 c
36 c 0.1. ==> generalites
37 c
38       implicit none
39       save
40 c
41 #ifdef _DEBUG_HOMARD_
42       character*6 nompro
43       parameter ( nompro = 'GUBILA' )
44 #endif
45 c
46 #ifdef _DEBUG_HOMARD_
47 #include "genbla.h"
48 #endif
49 c
50 #include "gunbul.h"
51 #include "gulggt.h"
52 c
53 c 0.2. ==> communs
54 c
55 c 0.3. ==> arguments
56 c
57       integer codfic
58 c
59 c 0.4. ==> variables locales
60 c
61       integer ulsort
62       integer codref
63       integer iaux, jaux, code
64       integer gunmbr(lgunmb)
65       integer statut(mbmxul), lnomfi(mbmxul)
66 #ifdef _DEBUG_HOMARD_
67       integer langue
68 #endif
69 c
70       character*200 nomfic(mbmxul)
71 c
72 #ifdef _DEBUG_HOMARD_
73       integer nbmess
74       parameter ( nbmess = 3 )
75       character*80 texte(nblang,nbmess)
76 #endif
77 c
78 c 0.5. ==> initialisations
79 c ______________________________________________________________________
80 c
81 c===
82 c 1. recuperation de l'information
83 c===
84 c
85 #ifdef _DEBUG_HOMARD_
86 #include "impr01.h"
87 #endif
88 c
89       code = 1
90       call gutabl ( code, gunmbr, statut, nomfic, lnomfi )
91 c
92       ulsort = gunmbr(16)
93 #ifdef _DEBUG_HOMARD_
94       langue = gunmbr(17)
95 #endif
96 c
97 #ifdef _DEBUG_HOMARD_
98       write (ulsort,texte(langue,1)) 'Entree', nompro
99       call dmflsh (iaux)
100 #endif
101 c
102 c===
103 c 2. impressions recapitulatives
104 c===
105 c
106 c 2.1. ==> statistiques
107 c
108       call gustat ( gunmbr )
109 c
110 c 2.2. ==> etat des lieux au moment de l'appel
111 c
112       if ( codfic.ne.0 ) then
113 c
114         call guinfo
115 c
116       endif
117 c
118 c====
119 c 3. fermeture de toutes les unites logiques, sauf les standard et
120 c    sauf celle ou sont imprimes les messages du gestionnaire. Elle
121 c    sera fermee tout a la fin.
122 c====
123 c
124       do 3  , iaux = 1 , mbmxul
125 c
126         if ( statut(iaux).ge.3 .and. statut(iaux).le.5 .and.
127      >       iaux.ne.ulsort ) then
128 c
129           jaux = iaux
130           call guferm ( nomfic(iaux), lnomfi(iaux), jaux, codref )
131 c
132         endif
133 c
134     3 continue
135 c
136       if ( ulsort.ge.1 .and. ulsort.le.mbmxul ) then
137         if ( statut(ulsort).eq.3 ) then
138           call gufeul ( ulsort , codref )
139         else if ( statut(ulsort).ne.2 ) then
140           codref = 1
141         else
142           codref = 0
143         endif
144       else
145         codref = 1
146       endif
147 c
148       end