General way of modeling Bézier curves and circles

bezier-curvecirclesgeometry

So it turns out that you can't totally model circles with Bézier curves:

How to create circle with Bézier curves?

I'm wondering if there is a mathematical system or construction that unifies circles, straight lines, and Bézier curves into a single formalism. I get that you could just say that formalism is "equations", but I'm wondering if there is anything in between each of these specific categories, and the general category of equations, for modeling these 3 different kinds of pretty general geometric constructions.

In SVG you can model ellipses or parts of ellipses with the a or A command:

M 0 50 L 10 50 A 30 20, 0, 0 0, 90 50 L 100 50

While for Bézier curves you use the c or C command.

M100,250 C100,100 400,100 400,250

Likewise, for lines you use other commands.

Basically I'm wondering, independent of SVG, if there is any unified system for this.

Best Answer

Lines, circular arcs, and Bézier curves can all be represented exactly as rational Bézier curves. These are a generalization of the polynomial Bézier curves that many people know and love.

Rational Bézier curves can also represent pieces of other types of conic curves (parabolas, ellipses, hyperbolas), in addition to circular arcs.

A NURBS curve is just a sequence of rational Bézier curves strung together end-to-end so that (usually) they join smoothly.

Related Question