[Tex/LaTex] Is it possible to have a Bézier curve with 3 control points in TikZ

tikz-pgf

In TikZ, it is possible to draw a Bézier curve of degree 3 with 2 control points p0, p1, p2, and p3 as follows:

\draw(p0)..controls (p1) and (p2)..(p3);

I am wondering whether there is a way to draw a Bézier curve with 5 points where 3 of them work as control points. That would then look like:

\draw(p0)..controls (p1) and (p2) and (p3)..(p4);

It looks like it is not available.

Best Answer

The fact that TikZ/PGF only has capabilities for cubic beziers is a facet of the output formats that it produces: those only support cubic beziers.

So to produce anything of higher degree, you would have to produce an approximation (indeed, TikZ/PGF approximates arcs by cubic beziers since PDF does not have a native arc command (Postscript does)). There are methods that could be used for implementing one, for example using a plot command, but as it would be an approximation and not a common feature, there is not - to my knowledge - an already inbuilt implementation. If you found an algorithm for approximating higher degree curves by cubic beziers, I can think of no reason why it would not be straightforward to implement one via some sort of to path magic.