Salome HOME
06513aed17627a91c1657bdfa7e8906d10cf8f0a
[tools/eficas.git] / Telemac / stbtel_cata_auto.py
1
2 # -*- coding: latin-1 -*-
3
4 from Accas import *
5 class DateJJMMAAAA:
6   def __init__(self):
7     self.ntuple=3
8
9   def __convert__(self,valeur):
10     if type(valeur) == types.StringType: return None
11     if len(valeur) != self.ntuple: return None
12     return valeur
13
14   def info(self):
15     return "Date : jj/mm/aaaa "
16
17   __repr__=info
18   __str__=info
19
20 class grma(GEOM):
21   pass
22
23 import types
24 class Tuple:
25   def __init__(self,ntuple):
26     self.ntuple=ntuple
27
28   def __convert__(self,valeur):
29     if type(valeur) == types.StringType:
30       return None
31     if len(valeur) != self.ntuple:
32       return None
33     return valeur
34
35   def info(self):
36     return "Tuple de %s elements" % self.ntuple
37
38
39
40 JdC = JDC_CATA (code = 'STBTEL',
41                 execmodul = None,
42                 )
43 # =======================================================================
44 # Catalog entry for the MAP function : c_pre_interfaceBody_mesh
45 # =======================================================================
46
47 VERSION_CATALOGUE="TRUNK_20201028"
48 # -----------------------------------------------------------------------
49 TREATMENT = PROC(nom= "TREATMENT",op = None,
50 # -----------------------------------------------------------------------
51 #   -----------------------------------
52     MINIMUM_DISTANCE_BETWEEN_TWO_POINTS = SIMP(statut ='o',
53 #   -----------------------------------
54         typ = 'R',
55         defaut = 1.E-5,
56         fr = """Distance (en metres)en dessous de laquelle deux noeuds sont consideres
57 comme confondus par \stbtel, lors de la verification des resultats
58 fournis par le mailleur. Lorsque deux noeuds sont confondus, l''un
59 d''entre eux est elimine, et tous les noeuds du maillage sont
60 renumerotes.""",
61         ang = """Distance (in meters) below which two nodes are considered as identical
62 by \stbtel when the results supplied by the mesh generator are being
63 checked. When two nodes occur at the same place, one of them is
64 eliminated and all the mesh nodes are renumbered.""",
65     ),
66 #   -----------------------------------
67     MESH_GENERATOR = SIMP(statut ='o',
68 #   -----------------------------------
69         typ = 'TXM',
70         into = ['SUPERTAB4','SUPERTAB6','MASTER2','SIMAIL','SELAFIN','TRIGRID','ADCIRC','FASTTABS'],
71         defaut = 'MASTER2',
72         fr = """Nom du mailleur utilise pour la creation du \telkey{FICHIER UNIVERSEL}.
73 Ce peut etre :
74 \begin{itemize}
75 \item SUPERTAB6 (version 6 du mailleur SUPERTAB),
76 \item SUPERTAB4 (version 4 du mailleur SUPERTAB),
77 \item MASTER2 (version 2 du mailleur MASTER-SERIES),
78 \item SIMAIL,
79 \item SELAFIN (afin de modifier un maillage deja utilise, comme pour :
80 \begin{itemize}
81 \item interpoler de nouveau fonds
82 \item eliminer des dependances arrieres
83 \item coupe triangles surcontraints),
84 \end{itemize}
85 \item TRIGRID,
86 \item FASTTABS.
87 \end{itemize}""",
88         ang = """Name of the mesh generator used for preparing the \telkey{UNIVERSAL
89 FILE}. It will be selected among the following:
90 \begin{itemize}
91 \item SUPERTAB6 (version 6 of SUPERTAB mesh generator),
92 \item SUPERTAB4 (version 4 of SUPERTAB mesh generator),
93 \item MASTER2 (version 2 of MASTER-SERIES mesh generator),
94 \item SIMAIL,
95 \item SELAFIN (in order to modify a mesh already used, as for example :
96 \begin{itemize}
97 \item to interpolate a new bathymetry
98 \item to eliminate backward dependencies
99 \item to cut overstressed triangles ),
100 \end{itemize}
101 \item TRIGRID,
102 \item FASTTABS.
103 \end{itemize}""",
104     ),
105 #   -----------------------------------
106     b_MESH_GENERATORG = BLOC(condition="MESH_GENERATOR == 'TRIGRID'",
107 #   -----------------------------------
108 #       -----------------------------------
109         BOTTOM_CORRECTION_OF_TRIGRID = SIMP(statut ='o',
110 #       -----------------------------------
111             typ = 'R',
112             defaut = 0.,
113             fr = """Fixe la valeur a ajouter a la bathymetrie lue dans le fichier
114 gemere par Trigrid.""",
115             ang = """Value to be added at the bottom value read in the Trigrid file""",
116         ),
117     ),
118 #   -----------------------------------
119     b_MESH_GENERATORH = BLOC(condition="MESH_GENERATOR in ['FASTTABS', 'TRIGRID']",
120 #   -----------------------------------
121 #       -----------------------------------
122         BATHYMETRY_IN_THE_UNIVERSAL_FILE = SIMP(statut ='o',
123 #       -----------------------------------
124             typ = bool,
125             defaut = False,
126             fr = """Permet de relire la bathymetrie directement dans le fichier de
127 maillage (Trigrid ou Fasttabs).""",
128             ang = """The bathymetry will be read in the mesh file (Trigrid or Fasttabs).""",
129         ),
130 #       -----------------------------------
131         MESH_ADDITIONAL_DATA_FILE = SIMP(statut ='o',
132 #       -----------------------------------
133             typ = ('Fichier','All Files (*)'),
134             defaut = '',
135             fr = """Nom du fichier additionnel. Ce fichier a une signification
136 differente en fonction du mailleur choisi.
137 \begin{itemize}
138 \item Trigrid : Fichier contenant la table de connectivites
139 (obligatoire).
140 \item Fasttabs : Fichier contenant les conditions limites (optionnel).
141 \end{itemize}""",
142             ang = """Name of the additionql file. The meaning of this file depend on the
143 type of mesh generator.
144 \begin{itemize}
145 \item Trigrid : containing the connectivity table built (mandatory).
146 \item Fasttabs  : boundary condition file built by Fasttabs (optional).
147 \end{itemize}""",
148         ),
149     ),
150 #   -----------------------------------
151     b_MESH_GENERATORI = BLOC(condition="MESH_GENERATOR == 'FASTTABS'",
152 #   -----------------------------------
153 #       -----------------------------------
154         BOUNDARY_CONDITIONS_IN_THE_ADDITIONAL_FILE = SIMP(statut ='o',
155 #       -----------------------------------
156             typ = bool,
157             defaut = False,
158             fr = """Permet de relire les conditions limites dans le fichier
159 additionnel (Fasttabs).""",
160             ang = """The boundary condition will be read in the additional file
161  (Fasttabs).""",
162         ),
163 #       -----------------------------------
164         b_BOUNDARY_CONDITIONS_IN_THE_ADDITIONAL_FILEG = BLOC(condition="BOUNDARY_CONDITIONS_IN_THE_ADDITIONAL_FILE == True",
165 #       -----------------------------------
166 #           -----------------------------------
167             BOUNDARY_UNIVERSAL_FILE = SIMP(statut ='o',
168 #           -----------------------------------
169                 typ = ('Fichier','All Files (*)'),
170                 defaut = '',
171                 fr = """Nom du fichier construit par le mailleur, a partir duquel \stbtel va
172 travailler.""",
173                 ang = """Name of the file created by the mesh generator, and from which \stbtel
174 will work.""",
175             ),
176         ),
177     ),
178 #   -----------------------------------
179     BINARY_STANDARD = SIMP(statut ='f',
180 #   -----------------------------------
181         typ = 'TXM',
182         into = ['STD','IBM','I3E'],
183         defaut = 'STD',
184         fr = """Adapte l''ecriture du \telkey{FICHIER DE GEOMETRIE POUR TELEMAC} au
185 standard binaire choisi pour celui-ci. Ce peut etre :
186 \begin{itemize}
187 \item IBM : binaire IBM,
188 \item I3E : binaire HP,
189 \item STD : prend par defaut le binaire de la machine sur laquelle
190             l''utilisateur travaille. Ce sont alors des ordres READ et
191             WRITE normaux qui sont utilises.
192 \end{itemize}""",
193         ang = """Matches the writing of the \telkey{GEOMETRY FILE FOR TELEMAC} to the
194 binary standard chosen for the latter. It will be selected among the
195 following:
196 \begin{itemize}
197 \item IBM: IBM binary,
198 \item I3E: HP binary,
199 \item STD: takes by default the binary on the computer with which
200           the user is working. The normal READ and WRITE commands
201           are then used.
202 \end{itemize}""",
203     ),
204 #   -----------------------------------
205     UNIVERSAL_FILE = SIMP(statut ='o',
206 #   -----------------------------------
207         typ = ('Fichier','All Files (*)'),
208         defaut = '',
209         fr = """Nom du fichier construit par le mailleur, a partir duquel \stbtel va
210 travailler.""",
211         ang = """Name of the file created by the mesh generator, and from which \stbtel
212 will work.""",
213     ),
214 #   -----------------------------------
215     GEOMETRY_FILE_FORMAT_FOR_TELEMAC = SIMP(statut ='o',
216 #   -----------------------------------
217         typ = 'TXM',
218         into = ['','SERAFIN','SERAFIND','MED'],
219         defaut = '',
220         fr = """Format du fichier qui contiendra le maillage, et qui servira pour
221 les calculs \telemac{2D}. Si aucun format n''est donné il prendra
222 soit le même format que le fichier universel si il est en
223 SERAFIN/SERAFIND sinon SERAFIN""",
224         ang = """Format of the file that will contain the mesh data,
225 and to be used in \telemac{2D} computations.
226 If no format is given it will take the format of the universal
227 file (if it is SERAFIN file) SERAFIN otherwise""",
228     ),
229 #   -----------------------------------
230     GEOMETRY_FILE_FOR_TELEMAC = SIMP(statut ='o',
231 #   -----------------------------------
232         typ = ('Fichier','All Files (*)','Sauvegarde'),
233         defaut = '',
234         fr = """Nom du fichier qui contiendra le maillage mis au format SELAFIN, et
235 qui servira pour les calculs \telemac{2D}.""",
236         ang = """Name of the file that will contain the mesh data to SELAFIN format,
237 and to be used in \telemac{2D} computations.""",
238     ),
239 #   -----------------------------------
240     BOUNDARY_CONDITIONS_FILE = SIMP(statut ='o',
241 #   -----------------------------------
242         typ = ('Fichier','All Files (*)','Sauvegarde'),
243         defaut = '',
244         fr = """Nom du fichier qui contiendra les conditions aux limites lues dans le
245 \telkey{FICHIER UNIVERSEL}, et qui servira pour les calculs
246 \telemac{2D}. (les conditions aux limites sont definies lors de la
247 realisation du maillage, au moyen de couleurs affectees aux noeuds des
248 frontieres du domaine de calcul).""",
249         ang = """Name of the file that will contain the boundary conditions being read
250 from the \telkey{UNIVERSAL FILE}, and to be used in \telemac{2D}
251 computations. (The boundary conditions are defined when preparing the
252 meshes, through colours that are allotted to the nodes of the
253 computation domain boundaries).""",
254     ),
255 #   -----------------------------------
256     OVERSTRESSED_TRIANGLES_CUTTING = SIMP(statut ='o',
257 #   -----------------------------------
258         typ = bool,
259         defaut = False,
260         fr = """Un triangle surcontraint est tel que ses trois noeuds soient situes
261 sur une frontiere du domaine de calcul. La presence de tels triangles
262 peut entrainer des instabilites lors des calculs realises par
263 TELEMAC 2D.\\
264 Cette option permet, en creant un noeud place au barycentre de des
265 triangles surcontraints, d''eviter de tels problemes.""",
266         ang = """An overstressed triangle is one whose three nodes are located along a
267 boundary of the computational domain. The occurrence of such triangles
268 may bring about instabilities in the computations made by TELEMAC 2D.
269 Such problems can be prevented by this option, through the creation of
270 a node at the geometric centres of the overstressed triangles.""",
271     ),
272 #   -----------------------------------
273     ELIMINATION_OF_BACKWARD_DEPENDENCIES = SIMP(statut ='o',
274 #   -----------------------------------
275         typ = bool,
276         defaut = True,
277         fr = """Permet de renumeroter les noeuds du maillage de maniere a eliminer les
278 dependances arrieres et autoriser ainsi le forcage de la vectorisation
279 lorsque les calculs TELEMAC 2D son effectues sur CRAY.\\
280 \begin{WarningBlock}{Attention :}
281 Un nombre minimum d''environ 500 noeuds est requis pour
282 l''activation de cette option.
283 \end{WarningBlock}""",
284         ang = """Provides for renumbering of the mesh nodes in order to eliminate the
285 backward dependencies, thereby enabling a forced vectorisation when
286 the TELEMAC 2D computations are made on a CRAY.\\
287 \begin{WarningBlock}{Warning:}
288 About 500 nodes is the least number required for activating
289 this option.
290 \end{WarningBlock}""",
291     ),
292 #   -----------------------------------
293     NODES_RENUMBERING = SIMP(statut ='o',
294 #   -----------------------------------
295         typ = bool,
296         defaut = False,
297         fr = """Permet d''utiliser le nouveau type de stockage des matrices.""",
298         ang = """Necessary to use the new storage scheme for the matrix.""",
299     ),
300 #   -----------------------------------
301     WRITING_NODE_COLOURS = SIMP(statut ='o',
302 #   -----------------------------------
303         typ = bool,
304         defaut = False,
305         fr = """Option non activee.""",
306         ang = """Option not activated""",
307     ),
308 #   -----------------------------------
309     BOTTOM = FACT(statut='f',
310 #   -----------------------------------
311 #       -----------------------------------
312         MAXIMUM_NUMBER_OF_BATHYMETRIC_POINTS = SIMP(statut ='o',
313 #       -----------------------------------
314             typ = 'I',
315             defaut = 20000,
316             fr = """Permet de dimensionner le tableau utilise pour la lecture, dans les
317 \telkey{FICHIERS DES FONDS}, des points releves a la table a
318 digitaliser.""",
319             ang = """Designed for dimensioning the array that is used for reading, in the
320 \telkey{BOTTOM TOPOGRAPHY FILES}, the points recorded at the digitizing
321 tablet.""",
322         ),
323 #       -----------------------------------
324         MINIMUM_DISTANCE_AT_BOUNDARY = SIMP(statut ='o',
325 #       -----------------------------------
326             typ = 'R',
327             defaut = 0.,
328             fr = """L''interpolation de la bathymetrie sur les noeuds du maillage est
329 realisee de la facon suivante. Pour chaque noeud du maillage, on
330 decoupe le plan en 4 quadrans. Dans chacun de ces quadrans, on cherche
331 le point releve a la table a digitaliser le plus proche. On affecte
332 alors au noeud considere une profondeur correspondant a la moyenne,
333 ponderee par la distance a ce noeud, des profondeurs en chacun des 4
334 points precedemment trouves.\\
335 On verifie toutefois que, lors de la recherche des points, les
336 frontieres du domaine ne sont pas franchies, de maniere a ne pas
337 introduire d''aberration dans la bathymetrie.\\
338 Ce mot-cle permet alors de definir la distance minimale aux frontieres
339 du domaine en dessous de laquelle on refuse de prendre en compte les
340 points releves.""",
341             ang = """The bathymetric data at the mesh nodes are interpolated. At each mesh
342 node, the plane is cut into 4 quadrants in each of which, among the
343 points recorded at the digitizing tablet, the closest one to the node
344 being considered is searched for.\\
345 This node is thenn given a depth corresponding to the mean depth at
346 each of the 4 points previously found, these depths being weighted
347 by the distance to the node.\\
348 When searching for the points in the quadrants, however, one shall
349 make sure the boundaries aare not overstepped in order to prevent
350 aberrations from being introduced into the bathymetric data.\\
351 The keyword can then be used for specifying the minimum distance to
352 the boundaries below which the recorded points should be ignored.""",
353         ),
354 #       -----------------------------------
355         BOTTOM_TOPOGRAPHY_FILES = SIMP(statut ='o',
356 #       -----------------------------------
357             typ = ('Fichier','All Files (*)'),
358             defaut = '',
359             fr = """Nom du fichier contenant la bathymetrie (au standard SINUSX), qui
360 servira pour la definition, par interpolation, de la profondeur en
361 chaque point du maillage.""",
362             ang = """Name of the file containing the bathymetric points (to SINUSX
363 standard), to be used, through interpolation, for defining the depth
364 at each point of the mesh.""",
365         ),
366 #       -----------------------------------
367         BOTTOM_TOPOGRAPHY_FILES_2 = SIMP(statut ='f',
368 #       -----------------------------------
369             typ = ('Fichier','All Files (*)'),
370             defaut = '',
371             fr = """Nom du fichier contenant la bathymetrie (au standard SINUSX), qui
372 servira pour la definition, par interpolation, de la profondeur en
373 chaque point du maillage.""",
374             ang = """Name of the file containing the bathymetric points (to SINUSX
375 standard), to be used, through interpolation, for defining the depth
376 at each point of the mesh.""",
377         ),
378 #       -----------------------------------
379         BOTTOM_TOPOGRAPHY_FILES_3 = SIMP(statut ='f',
380 #       -----------------------------------
381             typ = ('Fichier','All Files (*)'),
382             defaut = '',
383             fr = """Nom du fichier contenant la bathymetrie (au standard SINUSX), qui
384 servira pour la definition, par interpolation, de la profondeur en
385 chaque point du maillage.""",
386             ang = """Name of the file containing the bathymetric points (to SINUSX
387 standard), to be used, through interpolation, for defining the depth
388 at each point of the mesh.""",
389         ),
390 #       -----------------------------------
391         BOTTOM_TOPOGRAPHY_FILES_4 = SIMP(statut ='f',
392 #       -----------------------------------
393             typ = ('Fichier','All Files (*)'),
394             defaut = '',
395             fr = """Nom du fichier contenant la bathymetrie (au standard SINUSX), qui
396 servira pour la definition, par interpolation, de la profondeur en
397 chaque point du maillage.""",
398             ang = """Name of the file containing the bathymetric points (to SINUSX
399 standard), to be used, through interpolation, for defining the depth
400 at each point of the mesh.""",
401         ),
402 #       -----------------------------------
403         BOTTOM_TOPOGRAPHY_FILES_5 = SIMP(statut ='f',
404 #       -----------------------------------
405             typ = ('Fichier','All Files (*)'),
406             defaut = '',
407             fr = """Nom du fichier contenant la bathymetrie (au standard SINUSX), qui
408 servira pour la definition, par interpolation, de la profondeur en
409 chaque point du maillage.""",
410             ang = """Name of the file containing the bathymetric points (to SINUSX
411 standard), to be used, through interpolation, for defining the depth
412 at each point of the mesh.""",
413         ),
414     ),
415 #   -----------------------------------
416     EXTRACTION = FACT(statut='f',
417 #   -----------------------------------
418 #       -----------------------------------
419         NUMBER_OF_VERTICES_OF_THE_POLYGON_TO_EXTRACT_THE_MESH = SIMP(statut ='o',
420 #       -----------------------------------
421             typ = 'I',
422             defaut = 0,
423             fr = """Lorsque l''on souhaite extraire une partie du maillage, permet de
424 definir le nombre de sommets du polygone a l''interieur duquel le
425 maillage sera effectivement extrait.\\
426 \begin{WarningBlock}{Attention :}
427 Ce polygone doit etre convexe et les coordonnees des sommets donnes dans
428 l''ordre trigonometrique.  \end{WarningBlock}""",
429             ang = """When you want to extract a piece of the mesh, this key-word fixes
430 the number of vertices of a polygon inside of which the mesh will be
431 finally extracted.\\
432 \begin{WarningBlock}{Warning:}
433 This polygon should have a convex shape and the coordinates of the
434 vertices be given with an anti clock wise order.
435 \end{WarningBlock}""",
436         ),
437 #       -----------------------------------
438         b_NUMBER_OF_VERTICES_OF_THE_POLYGON_TO_EXTRACT_THE_MESHG = BLOC(condition="NUMBER_OF_VERTICES_OF_THE_POLYGON_TO_EXTRACT_THE_MESH > 0",
439 #       -----------------------------------
440 #           -----------------------------------
441             ABSCISSAE_OF_THE_VERTICES_OF_THE_POLYGON_TO_EXTRACT_THE_MESH = SIMP(statut ='o',
442 #           -----------------------------------
443                 typ = 'R', min=0, max='**',
444                 defaut = [0,0,0,0,0,0,0,0,0],
445                 fr = """Lorsque l''on souhaite extraire une partie du maillage,
446 permet de definir les abscisses des sommets du polygone a l''interieur
447 duquel le maillage sera effectivement extrait.
448 \begin{WarningBlock}{Attention :}
449 ce polygone doit etre convexe et les coordonnees des
450 sommets donnes dans l''ordre trigonometrique.
451 \end{WarningBlock}""",
452                 ang = """When you want to extract a piece of the mesh, this key-word fixes
453 the abscissae of the vertices of a polygon inside of which the mesh
454 will be finally extracted.\\
455 \begin{WarningBlock}{Warning:}
456 This polygon should have a convex shape and the coordinates
457 of the vertices be given with an anti clock wise order.
458 \end{WarningBlock}""",
459             ),
460 #           -----------------------------------
461             ORDINATES_OF_THE_VERTICES_OF_THE_POLYGON_TO_EXTRACT_THE_MESH = SIMP(statut ='o',
462 #           -----------------------------------
463                 typ = 'R', min=0, max='**',
464                 defaut = [0,0,0,0,0,0,0,0,0],
465                 fr = """Lorsque l''on souhaite extraire une partie du maillage,
466 permet de definir les ordonnees des sommets du polygone a l''interieur
467 duquel le maillage sera effectivement extrait.\\
468 \begin{WarningBlock}{Attention :}
469 Ce polygone doit etre convexe et les coordonnees des
470 sommets donnes dans l''ordre trigonometrique.
471 \end{WarningBlock}""",
472                 ang = """When you want to extract a piece of the mesh, this key-word fixes
473 the ordinates of the vertices of a polygon inside of which the mesh
474 will be finally extracted.\\
475 \begin{WarningBlock}{Warning:}
476 This polygon should have a convex shape and the coordinates
477 of the vertices be given with an anti clock wise order.
478 \end{WarningBlock}""",
479             ),
480 #           -----------------------------------
481             PROJECTION_AFTER_EXTRACTION = SIMP(statut ='o',
482 #           -----------------------------------
483                 typ = bool, min=0, max='**',
484                 defaut = [True ],
485                 fr = """Lors d''une extraction de maillage suivant un polygone, projette ou
486 non le maillage extrait sur les aretes du polygone.""",
487                 ang = """When a mesh is extracted inside a polygon, indicates whether the mesh
488 should be projected through the faces of the polygon or not.""",
489             ),
490         ),
491     ),
492 #   -----------------------------------
493     REFFINEMENT = FACT(statut='f',
494 #   -----------------------------------
495 #       -----------------------------------
496         CUTTING_ELEMENTS_IN_FOUR = SIMP(statut ='o',
497 #       -----------------------------------
498             typ = bool,
499             defaut = False,
500             fr = """Decoupe chaque element du mayage en quatre elements homothetiques
501 en joignant les milieux des aretes.""",
502             ang = """Cuts every element of the mesh in four homothetic elements
503 by joigning the middle points of each side.""",
504         ),
505 #       -----------------------------------
506         NUMBER_OF_VERTICES_OF_THE_POLYGON_TO_REFINE_THE_MESH = SIMP(statut ='f',
507 #       -----------------------------------
508             typ = 'I',
509             defaut = 0,
510             fr = """Lorsque l''on souhaite raffiner une partie du maillage,
511 permet de definir le nombre de sommets du polygone a l''interieur
512 duquel le maillage sera effectivement raffine.\\
513 \begin{WarningBlock}{Attention:}
514 Ce polygone doit etre convexe et les coordonnees des
515 sommets donnes dans l''ordre trigonometrique.
516 \end{WarningBlock}""",
517             ang = """When you want to refine a piece of the mesh, this key-word fixes
518 the number of vertices of a polygon inside of which the mesh will be
519 finally refined.\\
520 \begin{WarningBlock}{ATTENTION:}
521 This polygon should have a convex shape and the coordinates
522 of the vertices be given with an anti clock wise order.
523 \end{WarningBlock}""",
524         ),
525 #       -----------------------------------
526         b_NUMBER_OF_VERTICES_OF_THE_POLYGON_TO_REFINE_THE_MESHG = BLOC(condition="NUMBER_OF_VERTICES_OF_THE_POLYGON_TO_REFINE_THE_MESH > 0",
527 #       -----------------------------------
528 #           -----------------------------------
529             ABSCISSAE_OF_THE_VERTICES_OF_THE_POLYGON_TO_REFINE_THE_MESH = SIMP(statut ='o',
530 #           -----------------------------------
531                 typ = 'R', min=0, max='**',
532                 defaut = [0,0,0,0,0,0,0,0,0],
533                 fr = """Lorsque l''on souhaite raffiner une partie du maillage,
534 permet de definir les abscisses des sommets du polygone a l''interieur
535 duquel le maillage sera effectivement raffine.\\
536 \begin{WarningBlock}{Attention :}
537 ce polygone doit etre convexe et les coordonnees des
538 sommets donnes dans l''ordre trigonometrique.
539 \end{WarningBlock}""",
540                 ang = """When you want to refine a piece of the mesh, this key-word fixes
541 the abscissae of the vertices of a polygon inside of which the mesh
542 will be finally refined.\\
543 \begin{WarningBlock}{Warning:}
544 This polygon should have a convex shape and the coordinates
545 of the vertices be given with an anti clock wise order.
546 \end{WarningBlock}""",
547             ),
548 #           -----------------------------------
549             ORDINATES_OF_THE_VERTICES_OF_THE_POLYGON_TO_REFINE_THE_MESH = SIMP(statut ='o',
550 #           -----------------------------------
551                 typ = 'R', min=0, max='**',
552                 defaut = [0,0,0,0,0,0,0,0,0],
553                 fr = """Lorsque l''on souhaite raffiner une partie du maillage,
554 permet de definir les ordonnees des sommets du polygone a l''interieur
555 duquel le maillage sera effectivement raffine.\\
556 \begin{WarningBlock}{Attention :}
557 ce polygone doit etre convexe et les coordonnees des
558 sommets donnes dans l''ordre trigonometrique.
559 \end{WarningBlock}""",
560                 ang = """When you want to refine a piece of the mesh, this key-word fixes
561 the ordinates of the vertices of a polygon inside of which the mesh
562 will be finally refined.\\
563 \begin{WarningBlock}{Warning:}
564 This polygon should have a convex shape and the coordinates
565 of the vertices be given with an anti clock wise order.
566 \end{WarningBlock}""",
567             ),
568         ),
569     ),
570 #   -----------------------------------
571     DRY_ELEMENTS = FACT(statut='f',
572 #   -----------------------------------
573 #       -----------------------------------
574         DRY_ELEMENTS_ELIMINATION = SIMP(statut ='o',
575 #       -----------------------------------
576             typ = bool,
577             defaut = False,
578             fr = """Lors du traitement d''un fichier de resultats issu de \telemac{2D},
579 permet d''activer l''elimination des elements secs.""",
580             ang = """When using a \telemac{2D} results file, this keyword activates the
581 dry elements elimination.""",
582         ),
583 #       -----------------------------------
584         PARTIALLY_DRY_ELEMENTS_ELIMINATION = SIMP(statut ='o',
585 #       -----------------------------------
586             typ = bool,
587             defaut = False,
588             fr = """Lors de l''elimination des elements secs, permet de specifier si
589 on traite les elements parteillement secs (au moins un noeud sec).""",
590             ang = """When removing dry elements, specify if the partially dry elements are
591 treated (at least one dry node).""",
592         ),
593 #       -----------------------------------
594         DRY_LIMIT = SIMP(statut ='o',
595 #       -----------------------------------
596             typ = 'R',
597             defaut = 0.1,
598             fr = """Fixe la valeur du seuil (en metre) de hauteur d''eau en dessous
599 duquel un noeud est considere comme sec.""",
600             ang = """Limit of water depth value (in meter) under which the node is
601 considered as dry node.""",
602         ),
603 #       -----------------------------------
604         STORAGE_OF_ALL_TIME_STEPS = SIMP(statut ='o',
605 #       -----------------------------------
606             typ = bool,
607             defaut = False,
608             fr = """Lors du traitement d''elimination des elements secs, permet de
609 specifier si on restocke tous les pas de temps dans le fichier
610 resultat""",
611             ang = """When treating dry elements elimination, specify that
612 all time steps are to be stored in the results file.""",
613         ),
614     ),
615 )
616 # -----------------------------------------------------------------------
617 CONVERTER_INFO = PROC(nom= "CONVERTER_INFO",op = None,
618 # -----------------------------------------------------------------------
619 #   -----------------------------------
620     DEBUG = SIMP(statut ='o',
621 #   -----------------------------------
622         typ = bool,
623         defaut = False,
624         fr = """Permet d activer le mode debuggage.""",
625         ang = """Activate the debug mode.""",
626     ),
627 #   -----------------------------------
628     CONVERTER = SIMP(statut ='o',
629 #   -----------------------------------
630         typ = bool,
631         defaut = False,
632         fr = """Permet d activer le module de conversion.""",
633         ang = """Activate the conversion module.""",
634     ),
635 #   -----------------------------------
636     INPUT = FACT(statut='o',
637 #   -----------------------------------
638 #       -----------------------------------
639         INPUT_FILE_FORMAT = SIMP(statut ='o',
640 #       -----------------------------------
641             typ = 'TXM',
642             into = ['SERAFIN','SERAFIND','MED','UNV','CGNS'],
643             defaut = 'SERAFIN',
644             fr = """Specifie le format du fichier d entree""",
645             ang = """Specify input file format""",
646         ),
647 #       -----------------------------------
648         INPUT_FILE = SIMP(statut ='o',
649 #       -----------------------------------
650             typ = ('Fichier','All Files (*)'),
651             defaut = '',
652             fr = """Nom du fichier a convertir.""",
653             ang = """Name of the file to convert.""",
654         ),
655 #       -----------------------------------
656         BOUNDARY_FILE = SIMP(statut ='f',
657 #       -----------------------------------
658             typ = ('Fichier','All Files (*)'),
659             defaut = '',
660             fr = """Nom du fichier des conditions limites""",
661             ang = """Name of the boundary condition file""",
662         ),
663 #       -----------------------------------
664         LOG_FILE = SIMP(statut ='f',
665 #       -----------------------------------
666             typ = ('Fichier','All Files (*)'),
667             defaut = '',
668             fr = """Nom du fichier complementaire pour le format UNV""",
669             ang = """Name of the complementary file for the UNV format""",
670         ),
671 #       -----------------------------------
672         BOUNDARY_CONDITION_IN_SERAFIN_FORMAT = SIMP(statut ='o',
673 #       -----------------------------------
674             typ = bool,
675             defaut = False,
676             fr = """Fichier de conditions limites dans le cas d''une conversion depuis
677 SERAFIN.""",
678             ang = """Boundary condition file when converting from SERAFIN.""",
679         ),
680     ),
681 #   -----------------------------------
682     OUTPUT = FACT(statut='o',
683 #   -----------------------------------
684 #       -----------------------------------
685         OUTPUT_FILE_FORMAT = SIMP(statut ='o',
686 #       -----------------------------------
687             typ = 'TXM',
688             into = ['SERAFIN','SERAFIND','MED','UNV','CGNS','VTK','CGNS'],
689             defaut = 'SERAFIN',
690             fr = """Specifie le format du fichier de sortie""",
691             ang = """Specify output file format""",
692         ),
693 #       -----------------------------------
694         OUTPUT_FILE = SIMP(statut ='o',
695 #       -----------------------------------
696             typ = ('Fichier','All Files (*)','Sauvegarde'),
697             defaut = '',
698             fr = """Nom du fichier converti""",
699             ang = """Name of the converted file""",
700         ),
701 #       -----------------------------------
702         OUTPUT_BOUNDARY_FILE = SIMP(statut ='f',
703 #       -----------------------------------
704             typ = ('Fichier','All Files (*)','Sauvegarde'),
705             defaut = '',
706             fr = """Nom du fichier des conditions limites pour le fichier converti""",
707             ang = """Name of the boundary file for the converted file""",
708         ),
709 #       -----------------------------------
710         OUTPUT_LOG_FILE = SIMP(statut ='f',
711 #       -----------------------------------
712             typ = ('Fichier','All Files (*)','Sauvegarde'),
713             defaut = '',
714             fr = """Nom du fichier complementaire pour le fichier converti""",
715             ang = """Name of the complementary file for the converted file""",
716         ),
717     ),
718 #   -----------------------------------
719     TRANSLATION_INFO = FACT(statut='o',
720 #   -----------------------------------
721 #       -----------------------------------
722         TRANSLATION = SIMP(statut ='o',
723 #       -----------------------------------
724             typ = bool,
725             defaut = False,
726             fr = """Permet d activer la translation de maillage.""",
727             ang = """Activate the translation of the mesh.""",
728         ),
729 #       -----------------------------------
730         b_TRANSLATIONG = BLOC(condition="TRANSLATION == True",
731 #       -----------------------------------
732 #           -----------------------------------
733             X_TRANSLATION = SIMP(statut ='o',
734 #           -----------------------------------
735                 typ = 'R',
736                 defaut = 0.,
737                 fr = """Translation selon x""",
738                 ang = """Translation on the x axes""",
739             ),
740 #           -----------------------------------
741             Y_TRANSLATION = SIMP(statut ='o',
742 #           -----------------------------------
743                 typ = 'R',
744                 defaut = 0.,
745                 fr = """Translation selon y""",
746                 ang = """Translation on the y axes""",
747             ),
748         ),
749     ),
750 )
751 # -----------------------------------------------------------------------
752 SETTINGS = PROC(nom= "SETTINGS",op = None,
753 # -----------------------------------------------------------------------
754 #   -----------------------------------
755     PARALLEL_PROCESSORS = SIMP(statut ='o',
756 #   -----------------------------------
757         typ = 'I',
758         defaut = 0,
759         fr = """Nombre de processeurs en calcul parallele
760 \begin{itemize}
761 \item 0 : 1 machine, compilation sans bibliotheque de parallelisme
762 \item 1 : 1 machine, compilation avec bibliotheque de parallelisme
763 \item 2 : 2 processeurs ou machines en parallele
764 \item etc\ldots
765 \end{itemize}""",
766         ang = """Number of processors for parallel processing
767 \begin{itemize}
768 \item 0 : 1 machine, compiling without parallel library
769 \item 1 : 1 machine, compiling with a parallel library
770 \item 2 : 2 processors or machines in parallel
771 \item etc\ldots
772 \end{itemize}""",
773     ),
774 #   -----------------------------------
775     FORTRAN_FILE = SIMP(statut ='o',
776 #   -----------------------------------
777         typ = ('Fichier','All Files (*)'),
778         defaut = '',
779         fr = """Nom du fichier Fortran a soumettre.
780 Il ne sert a priori qu''a dimensionner les tableaux utilises par
781 \stbtel, mais peut contenir des sous-programmes modifies ou propres a
782 l''utilisateur.""",
783         ang = """Name of Fortran file to be entered.
784 It is a priori only designed for dimensioning the arrays that are
785 used by \stbtel, but it may contain either modified or user-written
786 subroutines.""",
787     ),
788 #   -----------------------------------
789     VECTOR_LENGTH = SIMP(statut ='o',
790 #   -----------------------------------
791         typ = 'I',
792         defaut = 1,
793         fr = """Permet de fixer, sur machine vectorielle, la longueur du vecteur.""",
794         ang = """Designed for dimensioning the vector length on vector machine.""",
795     ),
796 )
797 # -----------------------------------------------------------------------
798 INTERNAL = PROC(nom= "INTERNAL",op = None,
799 # -----------------------------------------------------------------------
800     UIinfo = {"groupes": ("CACHE")},
801 #   -----------------------------------
802     STEERING_FILE = SIMP(statut ='o',
803 #   -----------------------------------
804         typ = ('Fichier','All Files (*)'),
805         defaut = '',
806         fr = """Nom du fichier contenant les references des fichiers et les options
807 du calcul a realiser.""",
808         ang = """Name of the file that contains the file references and of options for
809 the computation to be made.""",
810     ),
811 #   -----------------------------------
812     DICTIONARY = SIMP(statut ='o',
813 #   -----------------------------------
814         typ = ('Fichier','All Files (*)'),
815         defaut = 'stbtel.dico',
816         fr = """Dictionnaire des mots cles.""",
817         ang = """Key word dictionary.""",
818     ),
819 )
820 TEXTE_NEW_JDC = "\
821 "
822 Ordre_Des_Commandes = (
823 'TREATMENT',
824 'CONVERTER_INFO',
825 'SETTINGS',
826 'INTERNAL')
827 try:
828     import TelApy
829     source = "eficas"
830 except Exception as excpt:
831     source = "Telemac"
832 enum = source+'.stbtel_enum_auto'
833 dicoCasEn = source+'.stbtel_dicoCasEnToCata'
834 dicoCasFr = source+'.stbtel_dicoCasFrToCata'