2015-11-03

3 Point Parabola (Spline)


https://scratch.mit.edu/projects/86400200/ 

P is generated according to the following formula.

Q = (1-t)*A + t*B
R = (1-t)*B + t*C

P = (1-t)*Q+ t*R




I will try to simplify equation on next project.


P = (1-t)*((1-t)*A + t*B)+ t*((1-t)*B + t*C)

P = (1-t)*((1*A-t*A) + t*B)+ t*((1*B-t*B) + t*C)

P = (1-t)*((1*A-t*A) + t*B) + t*(1*B-t*B + t*C)

P = (1-t)*(1*A - t*A + t*B) + t*(1*B-t*B + t*C)

P = (1*(1*A - t*A + t*B)) -t*(1*A - t*A + t*B) + t*(1*B-t*B + t*C)

P = (1*A - t*A + t*B) -(t*A - t*t*A + t*t*B) + t*(1*B-t*B + t*C)

P = (A - t*A + t*B) -(t*A - t*t*A + t*t*B) + (t*B-t*t*B + t*t*C)

P = A - t*A + t*B -t*A + t*t*A – t*t*B + t*B -t*t*B + t*t*C

P = A - t*A -t*A + t*t*A + t*B - t*t*B + t*B -t*t*B + t*t*C

P = A - 2t*A + t*t*A + 2t*B - 2*t*t*B + t*t*C

P = A - 2t*A + 2t*B + t*t*A - 2*t*t*B + t*t*C

P = A - 2t*(A+B) + t*t*(A - 2*B + C)

OR


P = (1-t)(1-t)A + (t * (1-t) + t * (1-t)) * B + t*t*c

t* (1-t) = t- t*t

P = (1-t)(1-t)A + (2t - 2t*t) * B + t*t*C

P = (1-t)(1-t)A + 2t *B - 2*t*t* B + t*t*C

(1-t)(1-t) = 1 – t -t + t*t

P = A -2*t*A+ t*t*A + 2t *B - 2*t*t* B + t*t*C


Hiç yorum yok: