Skip to main content

evaluate

function evaluate(ps: number[][], t: number): number[]

Defined in local-properties-at-t/evaluate/double/evaluate.ts:20

Returns the resulting point of evaluating the given bezier curve at the given parameter t.

  • uses power bases conversion and subsequently Horner's Method to evaluate the polynomial in double precision floating point arithmetic.

The resulting point p is returned as the pair [x,y], where x and y are double precision floating point numbers.

Note!
Green circles are draggable!
0

Parameters:

NameTypeDescription
psnumber[][]an order 1, 2 or 3 bezier curve, e.g. [[0,0],[1,1],[2,1],[2,0]]
tnumberthe parameter value where the bezier should be evaluated