Salome HOME
replace 'BOTTOM_FRICTION' by 'BOTTOM FRICTION'
[modules/hydro.git] / doc / salome / tutorial / interpolZ.py
index 0f55586bd9c5615c12f3eab5dbd25b33fb9d2619..cbee01a1cb5a5c77d26da5636e958da3f079d516 100644 (file)
@@ -14,6 +14,12 @@ dicoGroupeRegion= dict(litMineur  = 'garonne_1_litMineur',
                       riveDroite = 'garonne_1_riveDroite',
                       riveGauche = 'garonne_1_riveGauche',
                       )
+
+# --- méthode d'interpolation sur les nuages de points de bathymétrie
+#     interpolMethod = 0 : interpolation au point le plus proche
+#     interpolMethod = 1 : interpolation linéaire de l'altitude par triangulation du nuage de points
+interpolMethod = 0
+
 # --- valeur de Z à prendre quand le noeud n'est pas trouvé dans la région (détection de problèmes)                       
 zUndef = 90
 
@@ -31,7 +37,7 @@ theStudyId = salome.myStudyId
 from salome.hydrotools.interpolZ import interpolZ, createZfield2
 
 # --- Z interpolation Z sur la bathymetrie/altimetrie aux noeuds du maillage
-statz = interpolZ(nomCas, fichierMaillage, dicoGroupeRegion, zUndef)
+statz = interpolZ(nomCas, fichierMaillage, dicoGroupeRegion, zUndef, interpolMethod)
 
 # --- ajout d'un champ aux noeud, de nom "BOTTOM", content les valeurs Z
 createZfield2(fichierMaillage)