Tool for Cubic Bézier curve

matthiasobexer shared this problem 3 years ago

I have a problem with a task I have to do for an essay. Therefor I have to create a tool in Geogebra, which allows to plot a cubic béziercurve. I have already tested three different ways to create a cubic béziercurve: two different ones with the algorithm of de Casteljau and another one with the Bernstein-polynomials. The problem appears, when I want to create the tool. If f.e. I create four points (for the cubic-polynomial curve) and define with these four points another point y with the bernstein-weighting, I can create the béziercurve with the command Locus(y,t). But whenever I want to create a tool for this curve, the error message: "Opening file failed: processing of command: Locus(y,t)" appears. Does anyone have an idea where the problem is located? I've also attached a file which I hope will explain my problem concretely. I'm very thankful for any hint.

kind regards


Comments (1)


Hi, if you create this curve object as output of the tool instead of a Locus (the locus needs 5 inputs : the points and t, the curve needs only the 4 points), I think that it will work fine :

Curve(P_{0} (1 - t)³ + P_{1} 3(1 - t)² t + P_{2} 3 (1 - t) t² + P_{3} t³, t, 0, 1)

© 2022 International GeoGebra Institute