Fast and Accurate Computation of Polyhedral Mass Properties

Brian Mirtich
University of California, Berkeley

This paper appears in issue Volume 1, Number 2.
Purchase this issue from the akpeters.com web site.

Abstract

The location of a body’s center of mass, and its moments and products of inertia about various axes are important physical quantities needed for any type of dynamic simulation or physically based modeling. We present an algorithm for automatically computing these quantities for a general class of rigid bodies: those composed of uniform density polyhedra. The mass integrals may be converted into volume integrals under these assumptions, and the bulk of the paper is devoted to the computation of these volume integrals. Our algorithm is based on a three step reduction of the volume integrals to successively simpler integrals. The algorithm is designed to minimize the numerical errors that can result from poorly conditioned alignment of polyhedral faces. It is also designed for efficiency. All required volume integrals of a polyhedron are computed together during a single walk over the boundary of the polyhedron; exploiting common subexpressions reduces floating point operations. We present numerical results detailing the speed and accuracy of the algorithm, and also give a complete low level pseudocode description.

Author Information

Brian Mirtich, University of California, Berkeley, Berkeley, CA mirtich@cs.berkeley.edu

Source Code

Downloadable tar file contains C source code and a README file with instructions.

Revision history:

  • 26 Jan 1996
    • Program creation.
  • 3 Aug 1996
    • Corrected bug arising when polyhedron density is not 1.0.
    • Changes confined to function main().
    • Thanks to Zoran Popovic for catching this one.
  • 27 May 1997
    • Corrected sign error in translation of inertia product
    • terms to center of mass frame.
    • Changes confined to function main(). Thanks to Chris Hecker.

BibTeX Entry

@article{Mirtich96,
  author = "Brian Mirtich",
  title = "Fast and Accurate Computation of Polyhedral Mass Properties",
  journal = "journal of graphics tools",
  volume = "1",
  number = "2",
  pages = "31-50",
  year = "1996",
}