本文整理汇总了Python中geometry.Geometry.writeFEPOINT方法的典型用法代码示例。如果您正苦于以下问题:Python Geometry.writeFEPOINT方法的具体用法?Python Geometry.writeFEPOINT怎么用?Python Geometry.writeFEPOINT使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类geometry.Geometry
的用法示例。
在下文中一共展示了Geometry.writeFEPOINT方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1:
# 需要导入模块: from geometry import Geometry [as 别名]
# 或者: from geometry.Geometry import writeFEPOINT [as 别名]
deltaC_x = np.zeros((n_c,))
deltaC_r = np.zeros((n_c,))
deltaC_r[-1] = 10 #second to last element, set to 10
deltaC = np.array(zip(deltaC_x,deltaC_r))
geom.deform(centerbody=deltaC)
print "Run Time: ", time.time()-start_time
start_time = time.time()
geom.writeSTL('new.stl', ascii=False)
print "STL Write Time: ", time.time()-start_time
start_time = time.time()
geom.writeFEPOINT('deform.dat')
print "FEPoint Write Time: ", time.time()-start_time
#geometry.writeSTL('new.stl',body.coords.cartesian,ascii=False)
#centerbody.writeFEPOINT('deform.dat',body.coords.cartesian)
示例2:
# 需要导入模块: from geometry import Geometry [as 别名]
# 或者: from geometry.Geometry import writeFEPOINT [as 别名]
deltaC_c = np.array(zip(deltaC_cx,deltaC_cr))
deltaC_tx = np.zeros((n_c,))
deltaC_tr = np.zeros((n_c,))
# deltaC_tr[:-1] = 1 #second to last element, set to 10
deltaC_t = np.array(zip(deltaC_tx,deltaC_tr))
geom.deform(cowl=(deltaC_c,deltaC_t))
print "Run Time: ", time.time()-start_time
start_time = time.time()
geom.writeSTL('new.stl', ascii=False)
print "STL Write Time: ", time.time()-start_time
start_time = time.time()
geom.writeFEPOINT('new.fepoint')
import pylab as p
profile = geom.project_profile()
for point_set in profile:
X = point_set[:,0]
Y = point_set[:,1]
p.plot(X,Y)
p.show()