Determine form of cubic polynomial given initial conditions

85 Views Asked by At

If I am given a function $P = ax^3 + bx^2 + cx + d$ and following:

$P(0) = P_1$,

$P(1) = P_2$,

$P^\prime(0) = v_0$,

$P^\prime(1) = v_1$.

How would I solve for $a$, $b$, $c$ and $d$?

Edit:

I have tried following:

$P(0) = P_1$ => d = P1

$P^\prime(0) = v_1$ => c = v1

However, I am not sure how would I solve for $a$ and $b$?

1

There are 1 best solutions below

0
On BEST ANSWER

$P(x)=ax^3+bx^2+cx+d$, $P'(x)=3ax^2+2bx+c$.

From condition 1, that $P(0)=P_1$, we learn that $d=P_1$.

From condition 2, that $P(1)=P_2$, we learn that $a+b+c+d=P_2=a+b+c+P_1$.

From condition 3, that $P′(0)=v_0$, we learn that $c=v_0$.

From condition 4, that $P′(1)=v_1$, we learn that $3a+2b+c=v_1=3a+2b+v_0$.

Thus, we can express

$a=P_2-(b+c+d)$.

$a=P_2-(b+c+P_1)$.

$a=\frac{v_1-v_0-2b}{3}$.

$a=\frac{v_1-c-2b}{3}$.

$b=P_2-(a+c+d)$.

$b=P_2-(a+c+P_1)$.

$b=\frac{v_1-v_0-3a}{2}$.

$b=\frac{v_1-c-3a}{2}$.

$c=v_0$.

$d=P_1$.