List the values of x separately from the values of y for all the points. For example, given the four points (0, 0), (2, 0), (3, 2) and (4, 4), the x values are x0 = 0, x1 = 2, x2 = 3 and x3 = 4. The y values are y0 = 0, y1 = 0, y2 = 2 and y3 = 4.
Calculate the x coefficients according to the following formulas: cx = 3(x1 - x0), bx = 3(x2 - x1) - cx, and ax = x3 - x0 - cx - bx. For example, cx = 3(2 - 0) = 6, bx = 3(3 - 2) - 6 = -3 and ax = 4 - 0 - 6 + 3 = 1.
Substitute the x coefficients in the parametric equation xt = ax*t^3 + bx*t^2 + cx*t + x0. For example, xt = t^3 - 3*t^2 + 6*t.
Calculate the y coefficients according to the following formulas: cy = 3(y1 - y0), by = 3(y2 - y1) - cy, and ay = y3 - y0 - cy - by. For example, cy = 3(0 - 0) = 0, by = 3(2 - 0) - 0 = 6 and ay = 4 - 0 - 0 - 6 = -2.
Substitute the y coefficients in the parametric equation yt = ay*t^3 + by*t^2 + cy*t + y0. For example, yt = -2*t^3 + 6*t^2.
Evaluate the parametric equations for a set of values for t ranging from 0 to 1 such as {0, 0.2, 0.4, 0.6, 0.8, 1}. For example, the resulting values for xt would be {0, 1.09, 1.98, 2.74, 3.39, 4}, and the values for yt would be {0, 0.22, 0.83, 1.73, 2.82, 4}.
Combine the values of xt and yt to form a set of coordinate pairs. In other words, the first coordinate pair would consist of the first value of xt and the first value of yt. The second pair would consist of the second values of xt and yt, and so on. Plot the points and connect them to form the Bézier curve. In the given example, the coordinate pairs would be (0, 0), (1.09, 0.22), (1.98, 0.83), (2.74, 1.73), (3.39, 2.82) and (4, 4).