Salome HOME
begin test correction
[modules/hydro.git] / doc / salome / examples / h013_caseDigueManualMesh.py
index 032dc23459bcf16176e83fe8c3a51965be3a4f86..c19c290c797b5de6f684ab8ca07997000f78826e 100644 (file)
@@ -8,9 +8,9 @@ import salome
 
 salome.salome_init()
 theStudy = salome.myStudy
-  
+
 #----------------------
-# --- HYDRO 
+# --- HYDRO
 #----------------------
 
 from HYDROPy import *
@@ -372,7 +372,7 @@ garonne_2_digue.SetName("garonne_2_digue")
 garonne_2_entry = garonne_2.Export( theStudy._get_StudyId() )
 
 #----------------------
-# --- Geometry 
+# --- Geometry
 #----------------------
 
 # Get geometry shape and print debug information
@@ -403,7 +403,7 @@ SectionsDigue = geompy.CreateGroup(HYDRO_garonne_2, geompy.ShapeType["EDGE"])
 geompy.UnionIDs(SectionsDigue, [46, 50])
 geompy.addToStudyInFather( HYDRO_garonne_2, SectionsDigue, 'SectionsDigue' )
 
-# --- recreate subshapes already exported from HYDRO to get access from Python 
+# --- recreate subshapes already exported from HYDRO to get access from Python
 #garonne_2_domaineEtendu_Outer = geompy.CreateGroup(HYDRO_garonne_2, geompy.ShapeType["EDGE"])
 #geompy.UnionIDs(garonne_2_domaineEtendu_Outer, [4, 11, 17, 24, 26, 28, 14, 19, 20, 22, 31, 39, 41, 33, 35, 37])
 #garonne_2_digue_Left_Bank = geompy.CreateGroup(HYDRO_garonne_2, geompy.ShapeType["EDGE"])
@@ -417,13 +417,17 @@ geompy.addToStudyInFather( HYDRO_garonne_2, SectionsDigue, 'SectionsDigue' )
 #garonne_2_digue_Right_Bank = geompy.CreateGroup(HYDRO_garonne_2, geompy.ShapeType["EDGE"])
 #geompy.UnionIDs(garonne_2_digue_Right_Bank, [48])
 
-controlGeomProps(geompy, riveGauche,  39489.5116033, 35889668.8348)
+#controlGeomProps(geompy, riveGauche,  39489.5116033, 35889668.8348)
+#controlGeomProps(geompy, digue,       10340.1424233,   102887.6201)
+#controlGeomProps(geompy, litMineur,   30337.5484919,  3646827.74981)
+#controlGeomProps(geompy, riveDroite,  32012.3432411,  26177085.4601)
+controlGeomProps(geompy, riveGauche,  39493.270283, 35845790.613557)
 controlGeomProps(geompy, digue,       10340.1424233,   102887.6201)
-controlGeomProps(geompy, litMineur,   30337.5484919,  3646827.74981)
-controlGeomProps(geompy, riveDroite,  32012.3432411,  26177085.4601)
+controlGeomProps(geompy, litMineur,   30337.548492,  3488480.304388)
+controlGeomProps(geompy, riveDroite,  32012.343241, 25998769.23615)
 
 #----------------------
-# --- Meshing 
+# --- Meshing
 #----------------------
 
 import  SMESH, SALOMEDS
@@ -507,7 +511,7 @@ digue_2 = garonne_2.GroupOnGeom(digue,'digue',SMESH.NODE)
 SectionsGaronne_3 = garonne_2.GroupOnGeom(SectionsGaronne,'SectionsGaronne',SMESH.NODE)
 
 
-med_file = r'/garonne_2.med'
+med_file = r'/tmp/garonne_2.med'
 
 try:
   os.remove(med_file)
@@ -517,11 +521,16 @@ except OSError:
 garonne_2.SetAutoColor( 1 )
 garonne_2.ExportMED( med_file, 0, SMESH.MED_V2_2, 1, None ,1)
 
-controlMeshStats(garonne_2, 5247, 717, 10075)
+#controlMeshStats(garonne_2, 5247, 717, 10075)
+#controlSubMeshStats(litMineur_2, 2384)
+#controlSubMeshStats(riveDroite_1, 2348)
+#controlSubMeshStats(riveGauche_1, 5343)
+#controlSubMeshStats(digue_1, 0)
+controlMeshStats(garonne_2, 6190, 691, 12201)
 controlSubMeshStats(litMineur_2, 2384)
-controlSubMeshStats(riveDroite_1, 2348)
-controlSubMeshStats(riveGauche_1, 5343)
-controlSubMeshStats(digue_1, 0)
+controlSubMeshStats(riveDroite_1, 2400)
+controlSubMeshStats(riveGauche_1, 6585)
+controlSubMeshStats(digue_1, 832)
 
 if salome.sg.hasDesktop():
   salome.sg.updateObjBrowser(1)