Вы находитесь на странице: 1из 4

TALLER DE MÉTODOS NUMÉRICOS

Hallar aproximaciones a las raíces de x e−x + x=log 2 (x 2+ 1) usando:

1. Método de Newton, P0=0,5, tolerancia 10−3 (error absoluto).


2. Secante P0=2 y P1=5 , tolerancia 10−3 (error absoluto).
3. Método de Newton, P0=1, tolerancia 10−3 (error absoluto).
4. Explique las diferencias en los resultados.

SOLUCIÓN
2 −x
2
d log 2 e 2 2

1. P0=0,5; f ( x ) =log 2 ( x +1 ) −x e −x ; g ( x )= f ( x )= 2 ( 2 x )−e−x + 2 x 2 e−x −1


dx x +1
2

f ( po) log 2 ( ( 0.5 )2+ 1 )−( 0.5 ) e (−(0.5 ) )−0.5


p1= p0 − =0.5− ≈−1.9122673949925256
g ( p0 ) log 2 e 2
(− ( 0.5 ) ) 2
2 (− ( 0.5 ) )
2
( 2 ( 0.5 ) )−e +2 ( 0.5 ) e −1
( 0.5 ) +1

error =| p1− p0|=|−1.9122673949925256−0.5|=2.4122673949925256


2

log 2 ( (−1.9122673949925256 )2 +1 ) −(−1.9122673949925256 ) e(−(−1.9122673949925256 ) ) −(−1.9122673949925256)


p2=−1.9122673949925256−
log 2 e 2 2

2
( 2 (−1.9122673949925256 ) )−e(−(−1.9122673949925256 ) ) +2 (−1.9122673949925256 )2 e (−(−1.9122673949925256 ) )−1
(−1.9122673949925256 ) +1

error =| p2− p1|=|0.1555964658692384−1.9122673949925256|=1.7566709291232872


2

log 2 ( ( 0.1555964658692384 )2 +1 )−( 0.1555964658692384 ) e(−(0.1555964658692384 ) )−0.1555964658692384


p3=0.1555964658692384− ≈−0.027
log 2 e (− ( 0.1555964658692384 ) ) 2 2
2 (− ( 0.1555964658692384 ) )
2
( 2 ( 0.1555964658692384 ) )−e +2 ( 0.1555964658692384 ) e −1
( 0.1555964658692384 ) +1

error =| p3− p2|=|−0.0275393741653522−0.1555964658692384|=0.1831358400345906


2

log 2 ( (−0.0275393741653522 )2 +1 ) −(−0.0275393741653522 ) e(−(−0.0275393741653522) )−(−0.0275393741653522)


p4 =−0.0275393741653522−
log 2 e 2 2

2
( 2 (−0.0275393741653522 ) )−e(−(−0.0275393741653522) ) +2 (−0.0275393741653522 )2 e (−(−0.0275393741653522 ) )−1
(−0.0275393741653522) +1
error =| p4 −p 3|=|−0.0005060737865522−(−0.0275393741653522)|=0.0270333003788
2

log 2 ( (−0.0005060737865522 )2 +1 )−(−0.0005060737865522) e (−(−0.0005060737865522 ) )−(−0.0005060737865522)


p5=−0.0005060737865522−
log 2 e 2 2

2
( 2 (−0.0005060737865522) ) −e (−(−0.0005060737865522 ) )+ 2 (−0.0005060737865522)2 e(−(−0.0005060737865522) ) −1
(−0.0005060737865522 ) + 1

error =| p5− p4|=|−0.0000001844805001−(−0.0005060737865522)|=0.0005058893060521=5,058893060521∗10−4 ≤ 10−3

Observaciones: Las iteraciones entre mas precisas sean al momento de evaluarlas en las funciones, menores errores se cometerán y el
resultado será más próximo al valor deseado.
Se alcanza la tolerancia en la 5ta iteración cuando el primer punto es 0,5 en la función dada.
2

2. p0=2 ; p1=5 ; f ( x )=log 2 ( x 2 +1 )−x ( e−x + 1)

2
2
f ( p 1) ( p1 −p 0 ) ( log (( 5 ) +1 )− (5 ) ( e( ) +1 )) ( 5−2 )
− ( 5)

p =p −
2 1
f ( p )−f ( p )
1
=5−
0 ( 2
2
2
2
−(5 )
( log ( (5 ) +1 )−( 5 ) (e ( )+ 1 ))−( log ( ( 2 ) +1 )−( 2 ) ( e(
2
2 2
−(2 ) )
+1 ) ) )
=3.4634180772314081

error =| p2− p1|=|3.4634180772314081−5|=1.5365819227685919

2
2
( log ( ( 3.4634180772314081 ) +1 )−( 3.4634180772314081 ) ( e ( − ( 3.4634180772314081) )
+1 ) ) ( 3.4634180772314081−5 )
p3=3.4634180772314081−
(( 2
2 2

log 2 ( (3.4634180772314081 ) +1 )− (3.4634180772314081 ) ( e (−(3.4634180772314081) )+1 ) )−( log 2 ( ( 5 ) + 1 )−( 5 ) ( e(−(5 ) ) +1 ) )


2 2
)
=4.14128935

error =| p3− p2|=|4.1412893578880684−3.4634180772314081|=0.6778712806566603

2
2
( log ( ( 4.1412893578880684 ) +1 )− ( 4.1412893578880684 ) (e ( − ( 4.1412893578880684 ) )
+1 ) ) ( 4.1412893578880684−3
p4 =4.1412893578880684−
(( 2
2 2

log 2 ( ( 4.1412893578880684 ) +1 ) −( 4.1412893578880684 ) ( e(−( 4.1412893578880684 ) )+ 1 ) )−( log 2 ( ( 3.4634180772314081 ) +1 ) −( 3.4634


2

error =| p4 −p 3|=|4.2819215923524579−4.1412893578880683|=0.1406322344643896

2
2
( log ( ( 4.2819215923524579 ) + 1 )−( 4.2819215923524579 ) ( e( − ( 4.2819215923524579) )
+1 ) ) ( 4.2819215923524579−4.
p5=4.2819215923524579−
(( 2
2 2

log 2 ( ( 4.2819215923524579) +1 ) −( 4.2819215923524579 ) ( e (−(4.2819215923524579 ) ) +1 ) )−( log 2 ( ( 4.1412893578880684 ) +1 ) −( 4.1412


2

error =| p5− p4|=|4.2569088976155681−4.2819215923524579|=0.0250126947368898


2
2
( log ( ( 4.2569088976155681 ) +1 ) −( 4.2569088976155681 ) ( e ( − ( 4.2569088976155681) )
+1 ) ) ( 4.2569088976155681−4.
p6=4.2569088976155681−
(( 2
2 2
2
log 2 ( ( 4.2569088976155681 ) +1 )− ( 4.2569088976155681 ) ( e(−( 4.2569088976155681) ) +1 ) ) −( log 2 ( ( 4.2819215923524579 ) +1 ) −( 4.2819

error =| p6− p5|=|4.2574592205449379−4.2569088976155681|=0.0005503229293698=5.503229293698∗10−4 ≤10−3

Observaciones: El método de la secante tiene más iteraciones con respecto al método de Newton, testo se debe a que tiene más
variables que depende de su efectividad y el método no es 100% confiable. Por tanto, este método es más lento.
Se alcanza la tolerancia en la 6ta iteración cuando el primer punto es 5 y el segundo punto es 2 en la función dada.
2 −x
2
d log 2 e −x 2
2

3. P0=1 ; f ( x )=log 2 ( x +1 )−x (e +1) ; g ( x )= f ( x ) = 2 ( 2 x )−1−e (1−2 x )


dx x +1
2

f ( po) log2 ( (1)2 +1 ) −(1)(e(−(1 ) )+ 1)


p1 = p0 − =1− ≈ 1.4538502621453449
g ( p0 ) log 2 e 2
(− ( 1 ) ) 2
( 2(1) )−1−e ( 1−2(1) )
(1)2 +1

error =| p1− p0|=|1.4538502621453449−1|=0.4538502621453449

log 2 ( (1.4538502621453449 )2 +1 ) −( 1.4538502621453449) ( e(−(1.4538502621453449 ) ) +1 )


p2=1.4538502621453449− ≈ 1.4414280260977002
log 2 e (−( 1.4538502621453449) ) 2
2
2 ( 2 ( 1.4538502621453449 ) )−1−e (1−2 ( 1.4538502621453449 ) )
( 1.4538502621453449) +1

error =| p2− p1|=|1.4414280260977002−1.4538502621453449|=0.0124222360476447

log 2 ( ( 1.4414280260977002 )2+ 1 )−( 1.4414280260977002 ) ( e (−( 1.4414280260977002) ) +1 )


p3=1.4414280260977002− ≈ 1.4415062623786503
log 2 e (− ( 1.4414280260977002 ) ) 2
2
2 ( 2 ( 1.4414280260977002) ) −1−e (1−2 ( 1.4414280260977002) )
(1.4414280260977002 ) +1

error =| p3− p2|=|1.4415062623786502−1.4414280260977002|=0.00007823628095=7,823628095∗10−5 ≤ 10−3

Observaciones: Se alcanza la tolerancia en la 3ra iteración cuando el primer punto es 1 en la función dada. A comparación del primer
punto, esto se debe que de menos iteraciones porque está más próximo a una raíz. Es decir, 1 está más próximo a una raíz que 0,5.