netgen/python/mesh.py

22 lines
291 B
Python
Raw Normal View History

2014-08-30 03:05:50 +06:00
import sys
sys.path.append("/opt/netgen/lib")
from libmesh.meshing import *
from libcsg.csg import *
2014-08-31 18:12:31 +06:00
geo = CSGeometry("shaft.geo")
2014-08-30 03:05:50 +06:00
param = MeshingParameters()
2014-08-31 18:12:31 +06:00
param.maxh = 10
2014-08-31 15:14:18 +06:00
print (param)
2014-08-30 03:05:50 +06:00
m1 = GenerateMesh (geo, param)
2014-08-31 18:12:31 +06:00
import exportNeutral
exportNeutral.Export (m1, "shaft.mesh")
2014-08-30 03:05:50 +06:00