Beruflich Dokumente
Kultur Dokumente
Cuando se quieren estimar valores intermedios a un conjunto de datos precisos, el mtodo mas usado es la interpolacin polinomial. pn ( x) = a0 + a1 x + a2 x 2 + L + an x n Aunque existe un nico polinomio de grado n que pasa por n+1 puntos, hay una variedad de formatos matemticos en los que se puede expresar ese polinomio, entre ellos: La forma de Newton. La forma de Lagrange.
13/03/2010 Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
La Figura siguiente muestra el segmento de recta que une dos puntos, la parbola que pasa por tres puntos y la cbica que pasa por cuatro puntos. En general, puede demostrarse que por n +1 puntos diferentes pasa un nico polinomio de grado n
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Qu es interpolacin?
Dados n puntos (x0,y0), (x1,y1), (xn,yn) se quiere encontrar un valor de la variable dependiente y en un valor de x que no esta en la lista.
13/03/2010 Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Funciones interpolantes
Los polinomios son las funciones que se usan mas frecuentemente como interpolantes porque son fciles de Evaluar Derivar Integrar Manipular
13/03/2010 Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Ejemplo:
El brazo de un robot se usa para verificar, como control de calidad, el tamao del radio de seis agujeros que estn en una placa rectangular de 15 X 10 pulgadas. Las coordenadas de los agujeros son
x (m) y (m)
Path of a robot 8 7 6 5 4 3 2 1 0 0 5 X 10 15
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Problema
Se quiere construir el camino mas corto que pase por los seis puntos.
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Mtodo Directo
Dados n+1 puntos (x0,y0), (x1,y1),, (xn,yn), se quiere construir un polinomio de grado n que pase por todos los datos:
y = pn ( x) = a0 + a1 x + .................... + an x n
donde a0, a1,, an son constantes reales. Primero se deben establecer las n+1 ecuaciones para encontrar las n+1 incgnitas. Para aproximar el valor de y en un punto x, se substituye el valor x en el polinomio de interpolacin .
13/03/2010 Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Interpolacin Lineal
y ( x ) = a 0 + a1 x
ys f ( range) f x desired 7.14 7.2 7.2
7.18
7.16
7.12
7.1
7.1 7.08 x s 10
0
5 x s , range, x desired
10 x s + 10
1
De donde
13/03/2010 Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Interpolacin Cuadrtica
y ( x ) = a 0 + a1 x + a 2 x
2
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Interpolacin Cuadrtica
7.56258
7.5
ys f ( range) f x desired 7
6.5
2 2
2.5
3.5
4.5
5.5 5.25
13/03/2010
Chapter 18
x s , range, x desired
10
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Tabla comparativa
Orden del Polinomio Posicin del brazo para x=4 Error porcentual estimado 1 7.1111 ---------2 7.2735 2.235%
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
11
12
13
Path of a robot
10 9 8 7 6 5 4 3.5 3 2 1 0 0 2 4 6 X 8 10 12 Y 7.2 7.1 6 5 5
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
14
15
16
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
17
f ( x1 ) f ( x0 ) ( x x0 ) p1 ( x) = f ( x0 ) + Frmula de Newton x1 x0
interpolacin lineal
p1(x) denota al polinomio de interpolacin de grado uno, es decir, la recta que pasa por los dos puntos.
13/03/2010 Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
18
Figure 18.2
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
19
Interpolacin Cuadrtica
Si tenemos tres datos, la interpolacin puede mejorarse si introducimos la curvatura en la recta que conecta los puntos, en este caso el polinomio queda como:
p2 ( x) = b0 + b1 ( x x0 ) + b2 ( x x0 )( x x1 )
Las condiciones de interpolacin son:
x = x0 x = x1 b0 = f ( x0 ) f ( x1 ) f ( x0 ) b1 = x x0 f ( x2 ) f ( x1 ) f ( x1 ) f ( x0 ) x2 x1 x1 x0 b2 = x 2 x0
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
x = x2
13/03/2010
20
f [ xi , x j , xk ] = M
13/03/2010
f [ xn , xn1 ,K, x1 , x0 ] =
21
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
f (x2 )
f [ x2 , x1 , x0 ] f [ x3 , x2 , x1 ] f [ x3 , x2 , x1 , x0 ]
22
Ventajas de la representacin de Newton Problema mejor condicionado Si se agrega un punto nuevo no es necesario repetir los clculos menor nmero de operaciones para generar matriz de coeficientes y resolver el sistema de ecuaciones que es triangular inferior
13/03/2010 Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
23
x1 = 6 x3 = 5
f ( x1 ) = 1.791759 f ( x3 ) = 1.6094381
x2 = 4 f ( x2 ) = 1.386294
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
24
Fig 18.3
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
25
Fig 18.4
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
26
Fig 18.6
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
27
El error de interpolacin
La estructura del polinomio de interpolacin es similar al polinomio de Taylor. Para el polinomio de interpolacin de grado n existe una frmula anloga para el error: es un punto interior f ( x) = pn ( x) + Rn ( x) donde
f ( ) Rn ( x) = ( x x0 )( x x1 ) L ( x xn ) (n + 1)!
( n +1)
Rn ( x ) = f [ x, xn , xn1 ,K, x0 ]( x x0 )( x x1 )L ( x xn )
13/03/2010 Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
28
Estimacin del error de interpolacin Del teorema del error se obtiene el siguiente subproducto
f ( n +1) ( ) f [ x, xn , xn 1 , K , x0 ] = para algun (n + 1)!
Por otro lado, para obtener una estimacin del error, cuando se tiene un punto adicional, basta con calcular un trmino mas para obtener e Rn ( x) = f [ xn+1 , xn , xn1 ,K, x0 ]( x x0 )( x x1 ) L ( x xn )
13/03/2010 Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
29
30
Fig 18.8
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
31
Fig 18.9
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
32
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
33
f n ( x) = Li ( x) f ( xi )
i =0 n
Li ( x) =
j =0 j i
x xj xi x j
34
x x0 x x1 f ( x1 ) f ( x0 ) + p1 ( x) = x1 x0 x0 x1
Rn = f [ x, xn , xn 1 , K , x0 ] ( x xi )
i =0
13/03/2010 Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
35
36
La solucin de ese problema puede hallarse fcilmente si el intervalo de interpolacin es [-1,1]. En ese caso, la mejor escogencia son los ceros del polinomio de Chebyshev de grado n + 1:
13/03/2010 Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
37
Polinomios de Chebyshev
Definimos los polinomios usando una relacin de recurrencia: T0(x) = 1 y T1(x) = x Tk(x) = 2x Tk-1(x) - Tk-2(x) k = 2,3,4 T2(x) = 2x2-1, T3(x) = 4x3-3x, T4(x) = 8x4-8x2+1, T5(x) = 16x5-20x3+5x
13/03/2010 Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
38
39
4. Tn(x) tiene n ceros simples en [-1,1] que estn dados por : (2k + 1)
Tn ( x)
(x x ) 1
i i =0
n 1
xk = cos
2n
, k = 0,1,..., n 1
x [1,1]
donde Q(x) es cualquier polinomio mnico de grado n 1 Ms aun, max{T ( x) : x [1,1]} = n 13/03/2010 Chapter 18 40 2
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
41
1 f ( x) = 1 + 12 x 2
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
42
La figura muestra las aproximaciones sucesivas de la funcin escaln por polinomios de grado cinco, siete y nueve. En (d) se muestra se aproxima con una funcin lineal a trozos.
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
43
44
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
45
Figure 18.16
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
46
Figure 18.17
13/03/2010
Chapter 18
Copyright 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
47