I used Tim Lamber's algorithm to draw a natural spline cubic curve.
NatCubic class
NatCubic class compute the coefficients of the cubics (a b c d) of an array of points.
a + b*u + c*u^2 + d*u^3 0<=u <1
and Cubic class compute the points on the curve at time t in [0-1].
b in Cubic class is the derivatives at the knots at i
My question is: how to find the tangent at t >0 <1
Thank you!
PS :
for clarify my question, I search the tangent at time t, eg 0.5 to using pre-computed coeficients (abcd) of each control point. This is to avoid calculating the point(t+1) to find the tangent by, y(i +1) - y(i-1)
sorry for my poor english.