The Centroid Coordinates Product Moments is not available in RhinoCommon's Area Mass Properties

Hello,

The Product Moments is accessible through the GUI’s Analyze > Mass Properties > Area Moments.

However, it is lacking in the RhinoCommon class:
https://developer.rhino3d.com/api/RhinoCommon/html/T_Rhino_Geometry_AreaMassProperties.htm

FYI, I want to access it through Grasshopper.
Also, the WorldCoordinatesProductMoments is available in RhinoCommon, but I believe the Huygens-Steiner theorem of transport only applies when the original axis goes through the centroid of the surface. If anyone has a clue on a more general transport theorem, I am also interested.

Thanks!

@GregArden, can you help with this?

That was an oversight in RhinoCommon we will get it added. In the mean time you could do a little arithmetic with the WorldCoordinate moments.

The xy product moment about the centroid (cx, cy, cz) is the integral of
(x-cx)(y-cy) dm = xy dm - cx * y dm - cy * x dm + cx * cy * dm.

So CentroidCoordintes_ProductMoment_xy can be computed from WorldCoordintesProductMoments, WProd, and WorldCoordintesFirstMoments WFirst as
WProd.x - cx * WFirst.y - cy * WFirst.x - cx* cy * Area

Hi @taquet,

Here is a link you can use to track the issue:

https://mcneel.myjetbrains.com/youtrack/issue/RH-58117

– Dale

Thank you for the replies!

@GregArden great, thanks! Forgot to think about the simple arithmetics.

@dale Do I need to create an account? The link gives me a “Nope, can’t find it”

Just realized that the Product Moments about the Centroid Coordinates Axes is not available either in the GUI, I mistook the Product Moments about the World Coordinates Axes for the Product Moments about the Centroid Coordinates Axes in my original post.

Hi - you should be able to view RH-58117 now.
-wim

Thanks!

RH-58117 is fixed in the latest Service Release

1 Like

Awesome! Thanks :slight_smile: