3D封闭网格汽车对象的体积 [英] Volume of a 3D closed mesh car object

查看:107
本文介绍了3D封闭网格汽车对象的体积的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个3D封闭的网格汽车对象,该对象的表面组成 三角形.我想计算其体积,体积中心和惯性张量.

I have a 3D closed mesh car object having a surface made up triangles. I want to calculate its volume, center of volume and inertia tensor.

你能帮我吗

关于. 乔治

推荐答案

用于音量...

对于每个三角形小平面,请查找其角点.呼叫'em P,Q,R.
计算此数量(我称其为部分体积")

For each triangular facet, lookup its corner points. Call 'em P,Q,R.
Compute this quantity (I call it "partial volume")

pv =  PxQyRz + PyQzRx + PzQxRy - PxQzRy - PyQxRz - PzQyRx

将所有方面的这些加在一起并除以6.

Add these together for all facets and divide by 6.

重要!从外面看,每个小平面的P,Q,R必须顺时针排列. (或所有逆时针,只要在所有方面都保持一致即可.)

Important! The P,Q,R for each facet must be arranged clockwise as seen from outside. (Or all counter-clockwise, as long as it's consistent for all facets.)

如果网格具有任何四边形,只需将连接一对相对角的对角线临时幻化即可.这样就变成了两个三角形.

If the mesh has any quadrilaterals, just temporarily hallucinate a diagonal joining one pair of opposite corners. That makes it into two triangles.

实用的计算改进:在对P,Q和R进行数学运算之前,减去一些中心"点C的坐标.这可以是质心,即最小/最大x,y和z之间的中点,或者网格内或网格附近的任何方便点.这有助于最大程度地减少截断错误,从而获得更准确的音量.

Practical computationial improvement: Before doing math with P,Q and R, subtract the coordinates of some "center" point C. This can be the center of mass, a midpoint between the min/max x, y and z, or any convenient point inside or near the mesh. This helps minimize truncation errors for more accurate volumes.

这篇关于3D封闭网格汽车对象的体积的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆