In mathematics, the superquadrics (also superquadratics) are a family of geometric shapes defined by formulas that resemble those of elipsoids and other quadrics, except that the squaring operations are replaced by arbitrary powers. The superquadrics include many shapes that resemble cubes, octahedra, cylinders, lozenges and spindles, with rounded or sharp corners. Because of their flexibility and relative simplicity, they are popular geometric modeling tools, especially in computer graphics.
The basic superquadric has the formula
where r, s, and t are positive real numbers that determine the main features of the superquadric. Namely:
- less than 1: a pointy octahedron with concave faces and sharp edges.
- exactly 1: a regular octahedron.
- between 1 and 2: an octahedron with convex faces, blunt edges and blunt corners.
- exactly 2: a sphere
- greater than 2: a cube with rounded edges and corners.
- infinite (in the limit): a cube
Each exponent can be varied independently to obtain combined shapes.
Parametric equations in terms of surface parameters u and v (longitude and latitude) are
where the auxiliary functions are
and the sign function sgn(x) is