Salome HOME
bos #29171 Refactor testing procedure
[modules/smesh.git] / doc / examples / modifying_meshes_ex07.py
diff --git a/doc/examples/modifying_meshes_ex07.py b/doc/examples/modifying_meshes_ex07.py
new file mode 100644 (file)
index 0000000..898c3a2
--- /dev/null
@@ -0,0 +1,12 @@
+# Add Tetrahedron
+
+from mechanic import *
+
+# add node
+n1 = mesh.AddNode(50, 10, 0)
+if n1 == 0: print("KO node addition.")
+
+# add tetrahedron
+t1 = mesh.AddVolume([n1, 38, 39, 246])
+if t1 == 0: print("KO tetrahedron addition.")
+else:       print("New Tetrahedron has been added with ID ", t1)