]> SALOME platform Git repositories - modules/smesh.git/commitdiff
Salome HOME
mise à jour des cas-tests
authorGERALD NICOLAS <D68518@dsp0864451.atlas.edf.fr>
Tue, 26 Jan 2021 16:00:07 +0000 (17:00 +0100)
committerGERALD NICOLAS <D68518@dsp0864451.atlas.edf.fr>
Tue, 26 Jan 2021 16:00:07 +0000 (17:00 +0100)
src/Tools/blocFissure/CasTests/cylindre_2.py
src/Tools/blocFissure/CasTests/disquePerce.py
src/Tools/blocFissure/CasTests/faceGauche_2.py
src/Tools/blocFissure/CasTests/vis_1.py

index 2461457093df06bc879131a64eb90e84c3ced988..9b94dc3f2d6e56d18864e4d86bbe676af38df634 100644 (file)
@@ -63,13 +63,13 @@ class cylindre_2(cylindre):
   # ---------------------------------------------------------------------------
   def setReferencesMaillageFissure(self):
     self.referencesMaillageFissure = dict( \
-                                          Entity_Quad_Pyramid    = 1158,
                                           Entity_Quad_Quadrangle = 7028, \
                                           Entity_Quad_Hexa = 18366, \
                                           Entity_Node = 105035, \
                                           Entity_Quad_Edge = 735, \
                                           Entity_Quad_Triangle = 1056, \
                                           Entity_Quad_Tetra = 16305, \
+                                          Entity_Quad_Pyramid = 1158, \
                                           Entity_Quad_Penta = 384 \
                                           )
 
index 1f821426b51a4b23e6ca8c11fa7695488749d388..34211ce298147f8fa4b68426caf2925c93eaa0a1 100644 (file)
@@ -35,12 +35,14 @@ dicoParams = dict(nomCas            = 'disque',
 
   # ---------------------------------------------------------------------------
 
-referencesMaillageFissure = dict(Entity_Quad_Pyramid    = 610,
-                                 Entity_Quad_Triangle   = 1284,
-                                 Entity_Quad_Edge       = 393,
-                                 Entity_Quad_Penta      = 592,
-                                 Entity_Quad_Hexa       = 6952,
-                                 Entity_Node            = 51119,
-                                 Entity_Quad_Tetra      = 11672,
-                                 Entity_Quad_Quadrangle = 3000)
+referencesMaillageFissure = dict ( \
+                                  Entity_Quad_Quadrangle = 1630, \
+                                  Entity_Quad_Hexa = 3523, \
+                                  Entity_Node = 18874, \
+                                  Entity_Quad_Edge = 261, \
+                                  Entity_Quad_Triangle = 190, \
+                                  Entity_Quad_Tetra = 1322, \
+                                  Entity_Quad_Pyramid = 172, \
+                                  Entity_Quad_Penta = 64 \
+                                )
 
index d16921f501701acdf77455b62dac329f1ed6b907..bbddb58528e61202dfd291f7bd4a6f714fa8a746 100644 (file)
@@ -111,13 +111,13 @@ class faceGauche_2(fissureGenerique):
   # ---------------------------------------------------------------------------
   def setReferencesMaillageFissure(self):
     self.referencesMaillageFissure = dict( \
-                                          Entity_Quad_Pyramid    = 859,
-                                          Entity_Quad_Triangle   = 634,
-                                          Entity_Quad_Edge       = 323,
-                                          Entity_Quad_Penta      = 288,
-                                          Entity_Quad_Hexa       = 3435,
-                                          Entity_Node            = 44095,
-                                          Entity_Quad_Tetra      = 18400,
-                                          Entity_Quad_Quadrangle = 2542
+                                          Entity_Quad_Quadrangle = 2542, \
+                                          Entity_Quad_Hexa = 3435, \
+                                          Entity_Node = 44095, \
+                                          Entity_Quad_Edge = 323, \
+                                          Entity_Quad_Triangle = 634, \
+                                          Entity_Quad_Tetra = 18400, \
+                                          Entity_Quad_Pyramid = 859, \
+                                          Entity_Quad_Penta = 288 \
                                          )
 
index 4ddd3715bdeb1874e8be6dc8b434768489aafacb..164fc752d0e3ad1debdcdcfbb1ab9cc2f7344448 100644 (file)
@@ -47,47 +47,53 @@ class vis_1(fissureGenerique):
 
   # ---------------------------------------------------------------------------
   def genereMaillageSain(self, geometriesSaines, meshParams):
-    logging.info("genereMaillageSain %s", self.nomCas)
+    texte = "genereMaillageSain pour '{}'".format(self.nomCas)
+    logging.info(texte)
 
-    ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests/visSain.med"))
-    smesh.SetName(objetSain.GetMesh(), 'objetSain')
+    ([objetSain], _) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests", "visSain.med"))
+    smesh.SetName(objetSain.GetMesh(), "{}_objetSain".format(self.nomProbleme))
 
     return [objetSain, True] # True : maillage hexa
 
   # ---------------------------------------------------------------------------
   def setParamShapeFissure(self):
-    """
-    paramètres de la fissure pour méthode construitFissureGenerale
+    """paramètres de la fissure pour méthode construitFissureGenerale
+
     lgInfluence : distance autour de la shape de fissure a remailler (A ajuster selon le maillage)
     rayonPipe   : le rayon du pile maillé en hexa autour du fond de fissure
     convexe     : optionnel True : la face est convexe (vue de l'exterieur) sert si on ne donne pas de point interne
     pointIn_x   : optionnel coordonnée x d'un point dans le solide sain (pour orienter la face)
     """
-    logging.info("setParamShapeFissure %s", self.nomCas)
+    texte = "setParamShapeFissure pour '{}'".format(self.nomCas)
+    logging.info(texte)
     self.shapeFissureParams = dict(lgInfluence = 0.6,
                                    rayonPipe   = 0.1)
 
   # ---------------------------------------------------------------------------
   def genereShapeFissure( self, geometriesSaines, geomParams, shapeFissureParams):
-    logging.info("genereShapeFissure %s", self.nomCas)
+    """Importe la géométrie de la fissure et crée le groupe du fond de la fissure"""
+    texte = "genereShapeFissure pour '{}'".format(self.nomCas)
+    logging.info(texte)
 
     lgInfluence = shapeFissureParams['lgInfluence']
 
-    shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests/visFiss.brep"))
+    shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests", "visFiss.brep"))
     fondFiss = geompy.CreateGroup(shellFiss, geompy.ShapeType["EDGE"])
-    geompy.UnionIDs(fondFiss, [6, 8])
+    geompy.UnionIDs(fondFiss, [6, 8, 3])
     geompy.addToStudy( shellFiss, 'shellFiss' )
     geompy.addToStudyInFather( shellFiss, fondFiss, 'fondFiss' )
 
-
     coordsNoeudsFissure = genereMeshCalculZoneDefaut(shellFiss, 0.1 ,0.2)
 
     centre = None
+
     return [shellFiss, centre, lgInfluence, coordsNoeudsFissure, fondFiss]
 
   # ---------------------------------------------------------------------------
   def setParamMaillageFissure(self):
-    self.maillageFissureParams = dict(nomRep           = '.',
+    texte = "setParamMaillageFissure pour '{}'".format(self.nomCas)
+    logging.info(texte)
+    self.maillageFissureParams = dict(nomRep           = os.curdir,
                                       nomFicSain       = self.nomCas,
                                       nomFicFissure    = 'fissure_' + self.nomCas,
                                       nbsegRad         = 5,
@@ -103,6 +109,8 @@ class vis_1(fissureGenerique):
   def genereMaillageFissure(self, geometriesSaines, maillagesSains,
                             shapesFissure, shapeFissureParams,
                             maillageFissureParams, elementsDefaut, step):
+    texte = "genereMaillageFissure pour '{}'".format(self.nomCas)
+    logging.info(texte)
     maillageFissure = construitFissureGenerale(maillagesSains,
                                                shapesFissure, shapeFissureParams,
                                                maillageFissureParams, elementsDefaut, step)
@@ -110,12 +118,14 @@ class vis_1(fissureGenerique):
 
   # ---------------------------------------------------------------------------
   def setReferencesMaillageFissure(self):
-    self.referencesMaillageFissure = dict(Entity_Quad_Pyramid    = 1284,
-                                          Entity_Quad_Triangle   = 2336,
-                                          Entity_Quad_Edge       = 758,
-                                          Entity_Quad_Penta      = 984,
-                                          Entity_Quad_Hexa       = 6416,
-                                          Entity_Node            = 85673,
-                                          Entity_Quad_Tetra      = 35990,
-                                          Entity_Quad_Quadrangle = 4285)
+    self.referencesMaillageFissure = dict( \
+                                          Entity_Quad_Quadrangle = 4285 ,\
+                                          Entity_Quad_Hexa       = 6416, \
+                                          Entity_Node            = 85673, \
+                                          Entity_Quad_Edge       = 758, \
+                                          Entity_Quad_Triangle   = 2336, \
+                                          Entity_Quad_Tetra      = 35990, \
+                                          Entity_Quad_Pyramid    = 1284, \
+                                          Entity_Quad_Penta      = 984 \
+                                         )