Offset in computeCenterOfMass
Issue #2
closed
I guess the center of mass is computed by CenterOfMass = sum(tetrahedron COM times tetrahedron volume) / overall volume
In such case, the code should be cmd += (p1+p2+p3) * (cvol/4.0) instead of cmd += (p1+p2+p3) * (cvol/3.0)
The current implementation thus causes some offsets when this function is called in volume-preserving mesh smoothing.
Comments (2)
-
-
- changed status to closed
Fixed
- Log in to comment
Hi Li Xiaosheng, thanks for pointing this out, and sorry for the slow reply! I'll fix that right away...