MATH 417 Lecture 7

From Notes
Jump to navigation Jump to search

« previous | Tuesday, February 4, 2014 | next »


Review

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle f[x_0, x_1, \ldots, x_n] = \begin{cases} f^{(n)}(x_0) & x_0 = x_1 = \dots = x_n \\ \frac{f[x_1, x_2, \ldots, x_n] - f[x_0, \ldots, x_{n-1}}{x_n - x_0} & x_0 \ne x_n \end{cases}}

Finite and Divided Differences

Definition of finite difference:

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \begin{align} \Delta_h \, g(x_0) &= g(x_0 + h) - g(x_0) \\ \Delta_h^{n+1} f(x_0) &= \Delta_h^n \, f(x_0 + h) - \Delta_h^{n} \, f(x_0) \\ \Delta_h^0 f(x_0) &= f(x_0) \end{align}}


If points are equidistant, then

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \begin{align} f[x_0, x_1] &= \frac{f(x_0+h) - f(x_0)}{h} = \frac{\Delta_h \, f(x_0)}{h} \\ f[x_0, x_1 + h, x_2 + 2h, \ldots, x_n] &= \frac{(-1)^n}{n! \, h^n} \, \sum_{k=0}^n f(x_0 + kh) \, (-1)^k \, \binom{n}{k} \end{align}}


Interpolating Polynomials

Lagrange Polynomials

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle p(x) = \sum f(x_j) \, L_{n,j}(x)} , where Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle L_{n,j} = \prod_{i=0}^n \frac{x-x_i}{x_j-x_i}}

Basis for space of polynomials Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle P_n} is

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \left\{ \frac{(x-x_1) \, \dots \, (x-x_n)}{(x_0 - x_1) \, \dots \, (x_0 - x_n)} , \frac{(x-x_0) \, (x-x_2) \, \dots \, (x-x_n)}{(x_1 - x_0) \, (x_1 - x_2) \, \dots \, (x_1 - x_n)} , \ldots , \frac{(x-x_0) (x-x_1) \dots (x-x_{n-1})}{(x_n-x_0) (x_n-x_1) \dots (x_n - x_{n-1}} \right\}}

There are Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle n+1} independent functions in Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle P_n} .


Newton Polynomials

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle p(x) = f(x_0) + f[x_0,x_1] (x-x_0) + f[x_0,x_1,x_2] (x-x_0)(x-x_1) + \dots + f[x_0, x_1, \ldots, x_n] (x-x_0) \dots (x-x_{n-1})}

Basis for space of polynomials Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle P_n} is

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \left\{ 1, x-x_0, (x-x_0)(x-x_1), (x-x_0)(x-x_1)(x-x_2), \ldots \right\}}


Hermite Polynomials

Interpolate function and derivative:

Find Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_{2n+1}(x)} such that Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_{2n+1}(x_j) = f(x_j)} and Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_{2n+1}'(x_j) = f'(x_j)} for Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle j = 0, 1, \ldots, n} .


Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_{2n+1} = \sum_{j=0}^n f(x_j) \, H_{n,j}(x) + \sum_{j=0}^n f'(x_j) \hat{H}_{n,j}(x)}

Find Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \hat{H}_{n,j}(x)}

Restrictions:

  • Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \hat{H}_{n,j}(x_i) = 0} for all Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle i}
  • Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \hat{H}_{n,j}'(x_i) = 0} if Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle i \ne j}
  • Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \frac{\mathrm{d}\hat{H}_{n,j}}{\mathrm{d}x}(x_j) = 1}

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \hat{H}_{n,j}(x) = \alpha \, (x-x_j) \, (L_{n,j}(x))^2} , where Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \alpha} is some constant

Take derivative to find Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \alpha} :

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \hat{H}_{n,j}'(x) = \alpha L_{n,j}^2(x_j) + \cancel{\alpha \, (x_j-x_j)2 L_{n,j}(x_j) \, L_{n,j}'(x_j)}}

Therefore Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \alpha = 1} .

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \hat{H}_{n,j}(x) = (x-x_j) \, \left( L_{n,j}(x) \right)^2}


Find Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_{n,j}}

Restrictions:

  • Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_{n,j}(x_i) = 0} for Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle i \ne j}
  • Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_{n,j}(x_j) = 1}
  • Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H'_{n,j}(x_i) = 0} for all Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle i} .

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_{n,j}(x) = \left( L_{n,j}(x) \right)^2 \, (1 + a(x-x_j))} , where Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle a} is some constant.

Differentiating this function reveals Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle a = 2 \, L_{n,j}'(x_j)} . Therefore

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_{n,j}(x) \left( L_{n,j}(x) \right)^2 \, \left( 1 - 2 \, L_{n,j}'(x_j) \, (x - x_j) \right)}


Example

Use Newton's and Hermite's method to compute Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_{2n+1}} for Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle n = 2} (Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_5} )

Newton
Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle x} 0 1 2
Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle f} 4 1 7
Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle f'} 5 0 1

Starting point is

x f(x)
0  4
      5
0  4

1  1
      0
1  1

2  7
      1
2  7

Completed table is

x f(x)
0  4
       5
0  4      -8
      -3       11
1  1       3       -19/4
       0      3/2         -3/4
1  1       6       -25/4
       6      -11
2  7      -5
       1 
2  7

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \begin{align} H_5(x) &\to 0, 0, 1, 1, 2, 2 \\ &= 4 + 5x - 8x^2 + 11x^2(x-1) - \frac{19}{4} x^2(x-1)^2 - \frac{3}{4} x^2(x-1)^2(x-2) &= 7 + (x-2) - 5(x-2)^2 - 11(x-2)^2(x-1) - \frac{25}{4}(x-2)^2(x-1)^2 - \frac{3}{4}(x-2)^2(x-1)^2 x \end{align}}


Hermite

First we need the lagrange polynomials:

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \begin{align} L_{2,0}(x) &= \frac{(x-1)(x-2)}{(0-1)(0-2)} = \frac{1}{2} (x-1)(x-2) \\ L_{2,1}(x) &= \frac{(x-0)(x-2)}{(1-0)(1-2)} = -x(x-2) \\ L_{2,2}(x) &= \frac{(x-0)(x-1)}{(2-0)(2-1)} = \frac{1}{2} x(x-1) \end{align}}

Therefore, plugging these into the Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \hat{H}} -part of our formula for Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_{2n+1}} gives

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_5(x) = 5x \, \left( \frac{(x-1)(x-2)}{2} \right)^2 + 0 + 1 (x-2) \left( \frac{x(x-1)}{2} \right)^2 + \dots}


Now we need to find the derivatives of our lagrange polynomials above:

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \begin{align} L_{2,0}'(x) &= x-\frac{3}{2} \\ L_{2,1}'(x) &= -2x + 2 \\ L_{2,2}'(x) &= x-\frac{1}{2} \end{align}}

Evaluated at our points, we get

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle \begin{align} L_{2,0}'(0) &= -\frac{3}{2} \\ L_{2,1}'(1) &= 0 \\ L_{2,2}'(2) &= \frac{3}{2} \end{align}}

Plugging these values into the Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H} -part of our formula for Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_{2n+1}} gives

Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle H_5(x) = 4 \cdot \frac{(x-1)^2(x-2)^2}{4} \left( 1-2 \left( -\frac{3}{2} \right) x \right) + 1 \cdot x^2(x-2)^2 + 7 \cdot \frac{x^2(x-1)^2}{4} \left( 1 - 2 \cdot \frac{3}{2} (x-2) \right) + 5x \, \left( \frac{(x-1)(x-2)}{2} \right)^2 + 0 + 1 (x-2) \left( \frac{x(x-1)}{2} \right)^2}


Quiz

Nothing from section 3.5

Most likely something to do with interpolating polynomials (if no method is specified, use Newton)