Skip to main content

Geometric measurements

Every evaluated solid, part, and assembly exposes measure():
genus never uses a guessed value. A number is the exact sum of the genera of the connected components in the backend representation; null means that the backend or aggregate result cannot establish that quantity exactly. Manifold decomposes the mesh and sums each validated component genus. Stock and owned OCCT currently return null because their exposed native boundary lacks the edge-degeneracy primitive needed for a correct bounded B-Rep computation. Assemblies also return null: an occurrence mesh is an aggregate view, not a Boolean-unioned closed boundary. The inertia tensor uses the standard mechanics sign convention ∫((r · r)I - rrᵀ) dV about centerOfMass, expressed in world axes. It is a volumetric tensor until scaled by density. An empty result, which evaluate(document, { allowEmpty: true }) keeps with an EMPTY_RESULT warning, measures as zero volume and surface area, a null center of mass, a zero inertia tensor, a zero bounding box at the origin, and a finite non-negative tolerance on both bundled kernels.

Principal inertia

The result handles repeated or nearly repeated eigenvalues explicitly. In a sphere or symmetric cylinder, individual principal axes are not uniquely physical; consumers should inspect degeneracy/status rather than presenting an arbitrary axis as meaningful.

Axis queries

Axis directions are normalized and validated. Parallel-axis translation is applied when the requested axis does not pass through the centroid.

Physical mass properties

Parts and assemblies require authored mass density:
Then:
Density is stored in base unit kg/mm³. Helper constructors convert common engineering units without changing document semantics.

Assembly aggregation

Assembly physical properties transform each occurrence’s centroid and tensor, apply determinant volume scaling for affine placements, and combine them using the parallel-axis theorem. Mirrored occurrences remain positive mass; a nonuniform scale changes volume and inertia as geometry requires. Assembly measure() aggregates the same occurrence kernel measurements. Volume, center of mass, and inertia combine as above. Surface area sums each occurrence’s kernel area, scaled by the square of a uniform placement scale; only an occurrence placed with a nonuniform scale or shear uses the area of its default tessellation. Overlapping occurrences each count in full; they are not Boolean-unioned. The bounding box encloses every occurrence’s kernel bounding box after placement, so it is exact when every placement keeps the coordinate axes aligned (translations, axis scales, mirrors across coordinate planes, and quarter-turn rotations) and may be larger than the tight box for other rotations or mirror planes. tolerance is the largest occurrence kernel tolerance, scaled by its placement’s magnification. Missing density is a diagnostic, not zero mass. A BOM may still report known mass and massComplete: false while aggregate physical properties fail.

Combining external properties

combinePhysicalMassProperties combines already computed records after the caller has expressed them in the same world frame; it does not accept or apply placements itself. physicalMassProperties converts volumetric properties plus density into a physical record. These helpers are useful for integrations that combine InvariantCAD output with externally measured components.

Precision source

OCCT measures exact native shapes and verifies certain sweep volumes against analytic profile/path oracles, but does not currently report genus. Manifold provides native volume and surface-area measurements, integrates center of mass and inertia over its Float32 mesh (precision relative to the shape’s bounding-box size), and reports exact genus for its mesh representation. Check tolerance, nullable capabilities, and backend representation when comparing results across kernels; equality of authored intent does not promise byte-identical floating-point output.