2
$\begingroup$

A Natural Cubic Spline S on $[0,2]$ is defined by:

S(x)= $$S_0(x)=1+2x-x^3 \to 0 \leq x < 1 $$ $$S_1(x)=2+b(x-1)+c(x-1)^2+d(x-1)^3 \to 1 \leq x \leq 2$$

Find b,c and d

This question seems simple I am just not sure how to go about it. Can someone please guide me as to how to find the solution

1 Answers 1

5

Spline of order $k$ should have continuous derivatives up to order $k-1$. In this case,

$$S_0(1) = S_1(1)$$ $$S_0'(1) = S_1'(1)$$ $$S_0''(1) = S_1''(1)$$

Since this is a natural cubic spline, the second derivative at the first node $(x=0)$ and at the last node $(x=2)$ should be $0$.

and then you can solve for $b, c, d$.

  • 0
    $S_0(1)=S_1(1)$ Is confusing me since in essence it doesn't really provide any new information2012-09-28
  • 0
    Can you expound a little bit more. I am quite new to this and not exactly sure what to do2012-09-28
  • 0
    From the first derivative i have the following equation $$-1=b+2c+3d$$ and from the second derivative I have $$-6=2c+6d$$2012-09-28
  • 0
    What would I do next?2012-09-28
  • 1
    @math101 The first derivative gives $b=-1$ and second derivative gives $-6=2c$. The condition at the last node $(x=2)$ gives $2c+6d=0$.2012-09-28
  • 0
    That is the correct answer. But how did you get that? I am still quite confused for some odd reason2012-09-28
  • 0
    Ok I found my blunder. Thanks @Patrick Li2012-09-28