SlideShare a Scribd company logo
1 of 7
METODO DE BISECCION


function y=f(x)
y=-12.4+10*(0.5*%pi-asin(x/1)-x*(1-x**2)**0.5);
endfunction


function xw=biseccion(xyi,xzi,aproxi)
i=1;
eabs(1)=100;
if f(xyi)*f(xzi) < 0
     xy(1)=xyi;
     xz(1)=xzi;
     xw (1)=(xy(1)+xz(1))/2;
     printf('It.tt Xytt Xztt xw tt f(xw)t Error   n');
     printf('%2d t %11.7f t %11.7f t %11.7f t %11.7f
n',i,xy(i),xz(i), xw(i),f(xw(i)));
     while abs(eabs(i)) >= aproxi
       if f(xy(i))*f(xw(i))< 0
          xy(i+1)=xy(i);
          xz(i+1)=xw(i);
       end

       if f(xy(i))*f(xw(i))> 0
          xy(i+1)= xw(i);
          xz(i+1)=xz(i);
         end
       xw(i+1)=(xy(i+1)+xz(i+1))/2;
       eabs(i+1)=abs((xw(i+1)-xw(i))/(xw(i+1)));
       printf('%2d t %11.7f t %11.7f t %11.7f t %11.7f t %7.6f
n',i+1,xy(i+1),xz(i+1),xw(i+1),f(xw(i+1)),ea(i+1));
       i=i+1;
   end
else
   printf('No existe una raíz en ese intervalo');
end
endfunction
METODO DE N-R
function y=g(x)
y=300-80.425*x+201.0625*(1-2.718281828**(-(0.1)*x/0.25));
endfunction

function pn=puntofijo(pn0,aproxi)
i=1;
eabs(1)=100;
pn(1)=pn0;
while abs(eabs(i))>=aproxi,
     pn(i+1) = g(pn(i));
     eabs(i+1) = abs((pn(i+1)-pn(i))/pn(i+1));
     i=i+1;
end
printf(' i t       X(i)       Error aprox (i) n');
for j=1:i;
     printf('%2d t %11.7f t %7.3f n',j-1,pn(j),eabs(j));
end
endfunction
PUNTO FIJO

function y=f(x)
y=2*x**3+x-1;
endfunction

function y=df(x)
y=6*x**2+1;
endfunction

function pn=newtonraphson(pn0,aproxi);
i=1;
eabs(1)=100;
pn(1)=pn0;
while abs(eabs(i))>=tol;
     pn(i+1)=pn(i)-f(pn(i))/df(pn(i));
     eabs(i+1)=abs((pn(i+1)- pn(i))/pn(i+1));
     i=i+1;
end
printf(' i t        pn(i)      Error aprox (i) n');
for j=1:i;
     printf('%2d t %11.7f t %7.6f n',j-1,x(j),eabs(j));
end
endfunction

                             METODO DE NEWTON

function y=f(x)
y=4*cos(x)-exp(x);
endfunction

function y=df(x)
y=-4*sin(x)-exp(x);
endfunction

function pn=newtonraphson(pn0,aproxi);
i=1;
error(1)=100;
pn(1)=pn0;
while abs(error(i))>=aproxi;
     pn(i+1)=pn(i)-f(pn(i))/df(pn(i));
     aproxi(i+1)=abs((pn(i+1)-pn(i))/pn(i+1));
     i=i+1;
end
printf(' i t        pn(i)      Error aproxi (i) n');
for j=1:i;
     printf('%2d t %11.7f t %7.6f n',j-1,pn(j),eabs(j));
end
endfunction
METODO DE LA SECANTE

function y=f(x)
y=4*cos(x)-exp(x);
endfunction

function pn = secante(pn0,pn1,aproxi)
j=2;
i=1;
pn(1)=pn0;
pn(2)=pn1;
eabs(i)=100;
while abs(eabs(i))>=aproxi
   pn(j+1)=(pn(j-1)*f(pn(j))-pn(j)*f(pn(j-1)))/(f(pn(j))-f(pn(j-1)));
   eabs(i+1)=abs((pn(j+1)-pn(j))/pn(j+1));
   j=j+1;
   i=i+1;
end

printf(' i tt pn(i) t Error aproxi (i) n');
printf('%2d t %11.7f t n',0,pn(1));

for k=2:j;
    printf('%2d t %11.7f t %7.3f n',k-1,pn(k),eabs(k-1));
end

endfunction
METODO DE LA SECANTE


function y=f(x)
y=x**2-6;
endfunction

function pn = secante(pn0,pn1,aproxi)
j=2;
i=1;
pn(1)=pn0;
pn(2)=pn1;
eabs(i)=100;
while abs(eabs(i))>=aproxi
   pn(j+1)=(pn(j-1)*f(pn(j))-pn(j)*f(pn(j-1)))/(f(pn(j))-f(pn(j-1)));
   eabs(i+1)=abs((pn(j+1)-pn(j))/pn(j+1));
   j=j+1;
   i=i+1;
end

printf(' i tt pn(i) t Error aproxi (i) n');
printf('%2d t %11.7f t n',0,pn(1));

for k=2:j;
    printf('%2d t %11.7f t %7.3f n',k-1,pn(k),eabs(k-1));
end

endfunction
METODO DE LA FALSA POSICION

function y=f(x)
y=x**2-6;
endfunction


function xw=reglafalsa(xyi,xzi, aproxi)
i=1;
eabs(1)=100;
if f(xyi)*f(xzi) < 0
     xy(1)=xyi;
     xz(1)=xzi;
     xw(1)=xy(1)-f(xy(1))*(xz(1)-xy(1))/(f(xz(1))-f(xy(1)));
     printf('It.               Xy          Xz            Xw
f(Xw)             Error aprox %n');
     printf('%2d t %11.7f t %11.7f t %11.7ft %11.7f
n',i,xy(i),xz(i),xw(i),f(xw(i)));
     while abs(ea(i))>=aproxi,
       if f(xy(i))*f(xw(i))< 0
          xy(i+1)=xy(i);
          xz(i+1)=xz(i);
       end
       if f(xy(i))*f(xw(i))> 0
          xy(1)=xw(i);
          xz(1)=xz(i);
         end
       xw(i+1)=xy(i+1)-f(xy(i+1))*(xz(i+1)-xy(i+1))/(f(xz(i+1))-
f(xy(i+1)));
        eabs(i+1)=abs((xw(i+1)-xw(i))/(xw(i+1)));
       printf('%2d t %11.7f t %11.7f t %11.7f t %11.7ft %7.3f n',
i+1,xy(i+1),xz(i+1),xw(i+1),f(xw(i+1)),eabs(i+1));
       i=i+1;
   end
else
   printf('No existe una raíz en ese intervalo');
end
endfunction
c. Como se puede observar, por ambos métodos hay una aproximación a la raíz de 6 ( ), pero por
simple observación notamos claramente que el que más aproximación presenta es el realizado por el
método de la secante.

More Related Content

What's hot (16)

Quinto Punto Parte A
Quinto Punto Parte AQuinto Punto Parte A
Quinto Punto Parte A
 
Tercer Punto
Tercer PuntoTercer Punto
Tercer Punto
 
Primer Punto
Primer PuntoPrimer Punto
Primer Punto
 
Blocks+gcd入門
Blocks+gcd入門Blocks+gcd入門
Blocks+gcd入門
 
Matlab code for secant method
Matlab code for secant methodMatlab code for secant method
Matlab code for secant method
 
BCSL 058 solved assignment
BCSL 058 solved assignmentBCSL 058 solved assignment
BCSL 058 solved assignment
 
JavaScript Gotchas
JavaScript GotchasJavaScript Gotchas
JavaScript Gotchas
 
Es84
Es84Es84
Es84
 
Tabla de _derivadas
Tabla de _derivadasTabla de _derivadas
Tabla de _derivadas
 
Vcs9
Vcs9Vcs9
Vcs9
 
Newton's method for MATLAB Code
Newton's method for MATLAB CodeNewton's method for MATLAB Code
Newton's method for MATLAB Code
 
Tabla derivadas
Tabla derivadasTabla derivadas
Tabla derivadas
 
Langrange method for MATLAB Code
Langrange method for MATLAB CodeLangrange method for MATLAB Code
Langrange method for MATLAB Code
 
Intro to c programming
Intro to c programmingIntro to c programming
Intro to c programming
 
C Language Lecture 18
C Language Lecture 18C Language Lecture 18
C Language Lecture 18
 
Monte-carlo sim pricing EU call
Monte-carlo sim pricing EU callMonte-carlo sim pricing EU call
Monte-carlo sim pricing EU call
 

Similar to Martha

Quinto Punto Parte B
Quinto Punto Parte BQuinto Punto Parte B
Quinto Punto Parte Bgustavo206
 
Numerical Method Assignment
Numerical Method AssignmentNumerical Method Assignment
Numerical Method Assignmentashikul akash
 
Assignment on Numerical Method C Code
Assignment on Numerical Method C CodeAssignment on Numerical Method C Code
Assignment on Numerical Method C CodeSyed Ahmed Zaki
 
Computer Graphics Lab File C Programs
Computer Graphics Lab File C ProgramsComputer Graphics Lab File C Programs
Computer Graphics Lab File C ProgramsKandarp Tiwari
 
「ベータ分布の謎に迫る」第6回 プログラマのための数学勉強会 LT資料
「ベータ分布の謎に迫る」第6回 プログラマのための数学勉強会 LT資料「ベータ分布の謎に迫る」第6回 プログラマのための数学勉強会 LT資料
「ベータ分布の謎に迫る」第6回 プログラマのための数学勉強会 LT資料Ken'ichi Matsui
 
The Moore-Spiegel Oscillator
The Moore-Spiegel OscillatorThe Moore-Spiegel Oscillator
The Moore-Spiegel OscillatorAbhranil Das
 
Macroprocessor
MacroprocessorMacroprocessor
Macroprocessorksanthosh
 
Numerical Methods in C
Numerical Methods in CNumerical Methods in C
Numerical Methods in CAmbili Baby
 
A Course in Fuzzy Systems and Control Matlab Chapter Three
A Course in Fuzzy Systems and Control Matlab Chapter ThreeA Course in Fuzzy Systems and Control Matlab Chapter Three
A Course in Fuzzy Systems and Control Matlab Chapter ThreeChung Hua Universit
 
From Javascript To Haskell
From Javascript To HaskellFrom Javascript To Haskell
From Javascript To Haskellujihisa
 
Backpropagation in Convolutional Neural Network
Backpropagation in Convolutional Neural NetworkBackpropagation in Convolutional Neural Network
Backpropagation in Convolutional Neural NetworkHiroshi Kuwajima
 
Csci101 lect04 advanced_selection
Csci101 lect04 advanced_selectionCsci101 lect04 advanced_selection
Csci101 lect04 advanced_selectionElsayed Hemayed
 

Similar to Martha (20)

Quinto Punto Parte B
Quinto Punto Parte BQuinto Punto Parte B
Quinto Punto Parte B
 
Assignmnt 4
Assignmnt 4Assignmnt 4
Assignmnt 4
 
Numerical Method Assignment
Numerical Method AssignmentNumerical Method Assignment
Numerical Method Assignment
 
matlab codes.pdf
matlab codes.pdfmatlab codes.pdf
matlab codes.pdf
 
Assignment on Numerical Method C Code
Assignment on Numerical Method C CodeAssignment on Numerical Method C Code
Assignment on Numerical Method C Code
 
Computer Graphics Lab File C Programs
Computer Graphics Lab File C ProgramsComputer Graphics Lab File C Programs
Computer Graphics Lab File C Programs
 
「ベータ分布の謎に迫る」第6回 プログラマのための数学勉強会 LT資料
「ベータ分布の謎に迫る」第6回 プログラマのための数学勉強会 LT資料「ベータ分布の謎に迫る」第6回 プログラマのための数学勉強会 LT資料
「ベータ分布の謎に迫る」第6回 プログラマのための数学勉強会 LT資料
 
The Moore-Spiegel Oscillator
The Moore-Spiegel OscillatorThe Moore-Spiegel Oscillator
The Moore-Spiegel Oscillator
 
Macroprocessor
MacroprocessorMacroprocessor
Macroprocessor
 
Numerical Methods in C
Numerical Methods in CNumerical Methods in C
Numerical Methods in C
 
A Course in Fuzzy Systems and Control Matlab Chapter Three
A Course in Fuzzy Systems and Control Matlab Chapter ThreeA Course in Fuzzy Systems and Control Matlab Chapter Three
A Course in Fuzzy Systems and Control Matlab Chapter Three
 
DataStructures notes
DataStructures notesDataStructures notes
DataStructures notes
 
From Javascript To Haskell
From Javascript To HaskellFrom Javascript To Haskell
From Javascript To Haskell
 
Backpropagation in Convolutional Neural Network
Backpropagation in Convolutional Neural NetworkBackpropagation in Convolutional Neural Network
Backpropagation in Convolutional Neural Network
 
C Language Lecture 17
C Language Lecture 17C Language Lecture 17
C Language Lecture 17
 
Csci101 lect04 advanced_selection
Csci101 lect04 advanced_selectionCsci101 lect04 advanced_selection
Csci101 lect04 advanced_selection
 
Graphics point clipping c program
Graphics point clipping c programGraphics point clipping c program
Graphics point clipping c program
 
5th Sem SS lab progs
5th Sem SS lab progs5th Sem SS lab progs
5th Sem SS lab progs
 
Lambda calculus
Lambda calculusLambda calculus
Lambda calculus
 
Session07 recursion
Session07 recursionSession07 recursion
Session07 recursion
 

Recently uploaded

Lucknow 💋 High Class Call Girls Lucknow 10k @ I'm VIP Independent Escorts Gir...
Lucknow 💋 High Class Call Girls Lucknow 10k @ I'm VIP Independent Escorts Gir...Lucknow 💋 High Class Call Girls Lucknow 10k @ I'm VIP Independent Escorts Gir...
Lucknow 💋 High Class Call Girls Lucknow 10k @ I'm VIP Independent Escorts Gir...anilsa9823
 
Cheap Rate ➥8448380779 ▻Call Girls In Mg Road Gurgaon
Cheap Rate ➥8448380779 ▻Call Girls In Mg Road GurgaonCheap Rate ➥8448380779 ▻Call Girls In Mg Road Gurgaon
Cheap Rate ➥8448380779 ▻Call Girls In Mg Road GurgaonDelhi Call girls
 
Understanding Relationship Anarchy: A Guide to Liberating Love | CIO Women Ma...
Understanding Relationship Anarchy: A Guide to Liberating Love | CIO Women Ma...Understanding Relationship Anarchy: A Guide to Liberating Love | CIO Women Ma...
Understanding Relationship Anarchy: A Guide to Liberating Love | CIO Women Ma...CIOWomenMagazine
 
Postal Ballot procedure for employees to utilise
Postal Ballot procedure for employees to utilisePostal Ballot procedure for employees to utilise
Postal Ballot procedure for employees to utiliseccsubcollector
 
Breath, Brain & Beyond_A Holistic Approach to Peak Performance.pdf
Breath, Brain & Beyond_A Holistic Approach to Peak Performance.pdfBreath, Brain & Beyond_A Holistic Approach to Peak Performance.pdf
Breath, Brain & Beyond_A Holistic Approach to Peak Performance.pdfJess Walker
 
Reinventing Corporate Philanthropy_ Strategies for Meaningful Impact by Leko ...
Reinventing Corporate Philanthropy_ Strategies for Meaningful Impact by Leko ...Reinventing Corporate Philanthropy_ Strategies for Meaningful Impact by Leko ...
Reinventing Corporate Philanthropy_ Strategies for Meaningful Impact by Leko ...Leko Durda
 
The Selfspace Journal Preview by Mindbrush
The Selfspace Journal Preview by MindbrushThe Selfspace Journal Preview by Mindbrush
The Selfspace Journal Preview by MindbrushShivain97
 
9892124323, Call Girls in mumbai, Vashi Call Girls , Kurla Call girls
9892124323, Call Girls in mumbai, Vashi Call Girls , Kurla Call girls9892124323, Call Girls in mumbai, Vashi Call Girls , Kurla Call girls
9892124323, Call Girls in mumbai, Vashi Call Girls , Kurla Call girlsPooja Nehwal
 
CALL ON ➥8923113531 🔝Call Girls Rajajipuram Lucknow best sexual service
CALL ON ➥8923113531 🔝Call Girls Rajajipuram Lucknow best sexual serviceCALL ON ➥8923113531 🔝Call Girls Rajajipuram Lucknow best sexual service
CALL ON ➥8923113531 🔝Call Girls Rajajipuram Lucknow best sexual serviceanilsa9823
 
Dhule Call Girls #9907093804 Contact Number Escorts Service Dhule
Dhule Call Girls #9907093804 Contact Number Escorts Service DhuleDhule Call Girls #9907093804 Contact Number Escorts Service Dhule
Dhule Call Girls #9907093804 Contact Number Escorts Service Dhulesrsj9000
 
办理国外毕业证学位证《原版美国montana文凭》蒙大拿州立大学毕业证制作成绩单修改
办理国外毕业证学位证《原版美国montana文凭》蒙大拿州立大学毕业证制作成绩单修改办理国外毕业证学位证《原版美国montana文凭》蒙大拿州立大学毕业证制作成绩单修改
办理国外毕业证学位证《原版美国montana文凭》蒙大拿州立大学毕业证制作成绩单修改atducpo
 
Call Girls in Kalyan Vihar Delhi 💯 Call Us 🔝8264348440🔝
Call Girls in Kalyan Vihar Delhi 💯 Call Us 🔝8264348440🔝Call Girls in Kalyan Vihar Delhi 💯 Call Us 🔝8264348440🔝
Call Girls in Kalyan Vihar Delhi 💯 Call Us 🔝8264348440🔝soniya singh
 
CALL ON ➥8923113531 🔝Call Girls Adil Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Adil Nagar Lucknow best Female serviceCALL ON ➥8923113531 🔝Call Girls Adil Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Adil Nagar Lucknow best Female serviceanilsa9823
 
文凭办理《原版美国USU学位证书》犹他州立大学毕业证制作成绩单修改
文凭办理《原版美国USU学位证书》犹他州立大学毕业证制作成绩单修改文凭办理《原版美国USU学位证书》犹他州立大学毕业证制作成绩单修改
文凭办理《原版美国USU学位证书》犹他州立大学毕业证制作成绩单修改atducpo
 
call girls in candolim beach 9870370636] NORTH GOA ..
call girls in candolim beach 9870370636] NORTH GOA ..call girls in candolim beach 9870370636] NORTH GOA ..
call girls in candolim beach 9870370636] NORTH GOA ..nishakur201
 
办理西悉尼大学毕业证成绩单、制作假文凭
办理西悉尼大学毕业证成绩单、制作假文凭办理西悉尼大学毕业证成绩单、制作假文凭
办理西悉尼大学毕业证成绩单、制作假文凭o8wvnojp
 
《塔夫斯大学毕业证成绩单购买》做Tufts文凭毕业证成绩单/伪造美国假文凭假毕业证书图片Q微信741003700《塔夫斯大学毕业证购买》《Tufts毕业文...
《塔夫斯大学毕业证成绩单购买》做Tufts文凭毕业证成绩单/伪造美国假文凭假毕业证书图片Q微信741003700《塔夫斯大学毕业证购买》《Tufts毕业文...《塔夫斯大学毕业证成绩单购买》做Tufts文凭毕业证成绩单/伪造美国假文凭假毕业证书图片Q微信741003700《塔夫斯大学毕业证购买》《Tufts毕业文...
《塔夫斯大学毕业证成绩单购买》做Tufts文凭毕业证成绩单/伪造美国假文凭假毕业证书图片Q微信741003700《塔夫斯大学毕业证购买》《Tufts毕业文...ur8mqw8e
 
CALL ON ➥8923113531 🔝Call Girls Mahanagar Lucknow best sexual service
CALL ON ➥8923113531 🔝Call Girls Mahanagar Lucknow best sexual serviceCALL ON ➥8923113531 🔝Call Girls Mahanagar Lucknow best sexual service
CALL ON ➥8923113531 🔝Call Girls Mahanagar Lucknow best sexual serviceanilsa9823
 

Recently uploaded (20)

Lucknow 💋 High Class Call Girls Lucknow 10k @ I'm VIP Independent Escorts Gir...
Lucknow 💋 High Class Call Girls Lucknow 10k @ I'm VIP Independent Escorts Gir...Lucknow 💋 High Class Call Girls Lucknow 10k @ I'm VIP Independent Escorts Gir...
Lucknow 💋 High Class Call Girls Lucknow 10k @ I'm VIP Independent Escorts Gir...
 
Cheap Rate ➥8448380779 ▻Call Girls In Mg Road Gurgaon
Cheap Rate ➥8448380779 ▻Call Girls In Mg Road GurgaonCheap Rate ➥8448380779 ▻Call Girls In Mg Road Gurgaon
Cheap Rate ➥8448380779 ▻Call Girls In Mg Road Gurgaon
 
Understanding Relationship Anarchy: A Guide to Liberating Love | CIO Women Ma...
Understanding Relationship Anarchy: A Guide to Liberating Love | CIO Women Ma...Understanding Relationship Anarchy: A Guide to Liberating Love | CIO Women Ma...
Understanding Relationship Anarchy: A Guide to Liberating Love | CIO Women Ma...
 
Postal Ballot procedure for employees to utilise
Postal Ballot procedure for employees to utilisePostal Ballot procedure for employees to utilise
Postal Ballot procedure for employees to utilise
 
Breath, Brain & Beyond_A Holistic Approach to Peak Performance.pdf
Breath, Brain & Beyond_A Holistic Approach to Peak Performance.pdfBreath, Brain & Beyond_A Holistic Approach to Peak Performance.pdf
Breath, Brain & Beyond_A Holistic Approach to Peak Performance.pdf
 
Reinventing Corporate Philanthropy_ Strategies for Meaningful Impact by Leko ...
Reinventing Corporate Philanthropy_ Strategies for Meaningful Impact by Leko ...Reinventing Corporate Philanthropy_ Strategies for Meaningful Impact by Leko ...
Reinventing Corporate Philanthropy_ Strategies for Meaningful Impact by Leko ...
 
The Selfspace Journal Preview by Mindbrush
The Selfspace Journal Preview by MindbrushThe Selfspace Journal Preview by Mindbrush
The Selfspace Journal Preview by Mindbrush
 
9892124323, Call Girls in mumbai, Vashi Call Girls , Kurla Call girls
9892124323, Call Girls in mumbai, Vashi Call Girls , Kurla Call girls9892124323, Call Girls in mumbai, Vashi Call Girls , Kurla Call girls
9892124323, Call Girls in mumbai, Vashi Call Girls , Kurla Call girls
 
Model Call Girl in Lado Sarai Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Lado Sarai Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Lado Sarai Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Lado Sarai Delhi reach out to us at 🔝9953056974🔝
 
CALL ON ➥8923113531 🔝Call Girls Rajajipuram Lucknow best sexual service
CALL ON ➥8923113531 🔝Call Girls Rajajipuram Lucknow best sexual serviceCALL ON ➥8923113531 🔝Call Girls Rajajipuram Lucknow best sexual service
CALL ON ➥8923113531 🔝Call Girls Rajajipuram Lucknow best sexual service
 
escort service sasti (*~Call Girls in Paschim Vihar Metro❤️9953056974
escort service  sasti (*~Call Girls in Paschim Vihar Metro❤️9953056974escort service  sasti (*~Call Girls in Paschim Vihar Metro❤️9953056974
escort service sasti (*~Call Girls in Paschim Vihar Metro❤️9953056974
 
Dhule Call Girls #9907093804 Contact Number Escorts Service Dhule
Dhule Call Girls #9907093804 Contact Number Escorts Service DhuleDhule Call Girls #9907093804 Contact Number Escorts Service Dhule
Dhule Call Girls #9907093804 Contact Number Escorts Service Dhule
 
办理国外毕业证学位证《原版美国montana文凭》蒙大拿州立大学毕业证制作成绩单修改
办理国外毕业证学位证《原版美国montana文凭》蒙大拿州立大学毕业证制作成绩单修改办理国外毕业证学位证《原版美国montana文凭》蒙大拿州立大学毕业证制作成绩单修改
办理国外毕业证学位证《原版美国montana文凭》蒙大拿州立大学毕业证制作成绩单修改
 
Call Girls in Kalyan Vihar Delhi 💯 Call Us 🔝8264348440🔝
Call Girls in Kalyan Vihar Delhi 💯 Call Us 🔝8264348440🔝Call Girls in Kalyan Vihar Delhi 💯 Call Us 🔝8264348440🔝
Call Girls in Kalyan Vihar Delhi 💯 Call Us 🔝8264348440🔝
 
CALL ON ➥8923113531 🔝Call Girls Adil Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Adil Nagar Lucknow best Female serviceCALL ON ➥8923113531 🔝Call Girls Adil Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Adil Nagar Lucknow best Female service
 
文凭办理《原版美国USU学位证书》犹他州立大学毕业证制作成绩单修改
文凭办理《原版美国USU学位证书》犹他州立大学毕业证制作成绩单修改文凭办理《原版美国USU学位证书》犹他州立大学毕业证制作成绩单修改
文凭办理《原版美国USU学位证书》犹他州立大学毕业证制作成绩单修改
 
call girls in candolim beach 9870370636] NORTH GOA ..
call girls in candolim beach 9870370636] NORTH GOA ..call girls in candolim beach 9870370636] NORTH GOA ..
call girls in candolim beach 9870370636] NORTH GOA ..
 
办理西悉尼大学毕业证成绩单、制作假文凭
办理西悉尼大学毕业证成绩单、制作假文凭办理西悉尼大学毕业证成绩单、制作假文凭
办理西悉尼大学毕业证成绩单、制作假文凭
 
《塔夫斯大学毕业证成绩单购买》做Tufts文凭毕业证成绩单/伪造美国假文凭假毕业证书图片Q微信741003700《塔夫斯大学毕业证购买》《Tufts毕业文...
《塔夫斯大学毕业证成绩单购买》做Tufts文凭毕业证成绩单/伪造美国假文凭假毕业证书图片Q微信741003700《塔夫斯大学毕业证购买》《Tufts毕业文...《塔夫斯大学毕业证成绩单购买》做Tufts文凭毕业证成绩单/伪造美国假文凭假毕业证书图片Q微信741003700《塔夫斯大学毕业证购买》《Tufts毕业文...
《塔夫斯大学毕业证成绩单购买》做Tufts文凭毕业证成绩单/伪造美国假文凭假毕业证书图片Q微信741003700《塔夫斯大学毕业证购买》《Tufts毕业文...
 
CALL ON ➥8923113531 🔝Call Girls Mahanagar Lucknow best sexual service
CALL ON ➥8923113531 🔝Call Girls Mahanagar Lucknow best sexual serviceCALL ON ➥8923113531 🔝Call Girls Mahanagar Lucknow best sexual service
CALL ON ➥8923113531 🔝Call Girls Mahanagar Lucknow best sexual service
 

Martha

  • 1. METODO DE BISECCION function y=f(x) y=-12.4+10*(0.5*%pi-asin(x/1)-x*(1-x**2)**0.5); endfunction function xw=biseccion(xyi,xzi,aproxi) i=1; eabs(1)=100; if f(xyi)*f(xzi) < 0 xy(1)=xyi; xz(1)=xzi; xw (1)=(xy(1)+xz(1))/2; printf('It.tt Xytt Xztt xw tt f(xw)t Error n'); printf('%2d t %11.7f t %11.7f t %11.7f t %11.7f n',i,xy(i),xz(i), xw(i),f(xw(i))); while abs(eabs(i)) >= aproxi if f(xy(i))*f(xw(i))< 0 xy(i+1)=xy(i); xz(i+1)=xw(i); end if f(xy(i))*f(xw(i))> 0 xy(i+1)= xw(i); xz(i+1)=xz(i); end xw(i+1)=(xy(i+1)+xz(i+1))/2; eabs(i+1)=abs((xw(i+1)-xw(i))/(xw(i+1))); printf('%2d t %11.7f t %11.7f t %11.7f t %11.7f t %7.6f n',i+1,xy(i+1),xz(i+1),xw(i+1),f(xw(i+1)),ea(i+1)); i=i+1; end else printf('No existe una raíz en ese intervalo'); end endfunction
  • 2. METODO DE N-R function y=g(x) y=300-80.425*x+201.0625*(1-2.718281828**(-(0.1)*x/0.25)); endfunction function pn=puntofijo(pn0,aproxi) i=1; eabs(1)=100; pn(1)=pn0; while abs(eabs(i))>=aproxi, pn(i+1) = g(pn(i)); eabs(i+1) = abs((pn(i+1)-pn(i))/pn(i+1)); i=i+1; end printf(' i t X(i) Error aprox (i) n'); for j=1:i; printf('%2d t %11.7f t %7.3f n',j-1,pn(j),eabs(j)); end endfunction
  • 3. PUNTO FIJO function y=f(x) y=2*x**3+x-1; endfunction function y=df(x) y=6*x**2+1; endfunction function pn=newtonraphson(pn0,aproxi); i=1; eabs(1)=100; pn(1)=pn0; while abs(eabs(i))>=tol; pn(i+1)=pn(i)-f(pn(i))/df(pn(i)); eabs(i+1)=abs((pn(i+1)- pn(i))/pn(i+1)); i=i+1; end printf(' i t pn(i) Error aprox (i) n'); for j=1:i; printf('%2d t %11.7f t %7.6f n',j-1,x(j),eabs(j)); end endfunction METODO DE NEWTON function y=f(x) y=4*cos(x)-exp(x); endfunction function y=df(x) y=-4*sin(x)-exp(x); endfunction function pn=newtonraphson(pn0,aproxi); i=1; error(1)=100; pn(1)=pn0; while abs(error(i))>=aproxi; pn(i+1)=pn(i)-f(pn(i))/df(pn(i)); aproxi(i+1)=abs((pn(i+1)-pn(i))/pn(i+1)); i=i+1; end printf(' i t pn(i) Error aproxi (i) n'); for j=1:i; printf('%2d t %11.7f t %7.6f n',j-1,pn(j),eabs(j)); end endfunction
  • 4. METODO DE LA SECANTE function y=f(x) y=4*cos(x)-exp(x); endfunction function pn = secante(pn0,pn1,aproxi) j=2; i=1; pn(1)=pn0; pn(2)=pn1; eabs(i)=100; while abs(eabs(i))>=aproxi pn(j+1)=(pn(j-1)*f(pn(j))-pn(j)*f(pn(j-1)))/(f(pn(j))-f(pn(j-1))); eabs(i+1)=abs((pn(j+1)-pn(j))/pn(j+1)); j=j+1; i=i+1; end printf(' i tt pn(i) t Error aproxi (i) n'); printf('%2d t %11.7f t n',0,pn(1)); for k=2:j; printf('%2d t %11.7f t %7.3f n',k-1,pn(k),eabs(k-1)); end endfunction
  • 5. METODO DE LA SECANTE function y=f(x) y=x**2-6; endfunction function pn = secante(pn0,pn1,aproxi) j=2; i=1; pn(1)=pn0; pn(2)=pn1; eabs(i)=100; while abs(eabs(i))>=aproxi pn(j+1)=(pn(j-1)*f(pn(j))-pn(j)*f(pn(j-1)))/(f(pn(j))-f(pn(j-1))); eabs(i+1)=abs((pn(j+1)-pn(j))/pn(j+1)); j=j+1; i=i+1; end printf(' i tt pn(i) t Error aproxi (i) n'); printf('%2d t %11.7f t n',0,pn(1)); for k=2:j; printf('%2d t %11.7f t %7.3f n',k-1,pn(k),eabs(k-1)); end endfunction
  • 6. METODO DE LA FALSA POSICION function y=f(x) y=x**2-6; endfunction function xw=reglafalsa(xyi,xzi, aproxi) i=1; eabs(1)=100; if f(xyi)*f(xzi) < 0 xy(1)=xyi; xz(1)=xzi; xw(1)=xy(1)-f(xy(1))*(xz(1)-xy(1))/(f(xz(1))-f(xy(1))); printf('It. Xy Xz Xw f(Xw) Error aprox %n'); printf('%2d t %11.7f t %11.7f t %11.7ft %11.7f n',i,xy(i),xz(i),xw(i),f(xw(i))); while abs(ea(i))>=aproxi, if f(xy(i))*f(xw(i))< 0 xy(i+1)=xy(i); xz(i+1)=xz(i); end if f(xy(i))*f(xw(i))> 0 xy(1)=xw(i); xz(1)=xz(i); end xw(i+1)=xy(i+1)-f(xy(i+1))*(xz(i+1)-xy(i+1))/(f(xz(i+1))- f(xy(i+1))); eabs(i+1)=abs((xw(i+1)-xw(i))/(xw(i+1))); printf('%2d t %11.7f t %11.7f t %11.7f t %11.7ft %7.3f n', i+1,xy(i+1),xz(i+1),xw(i+1),f(xw(i+1)),eabs(i+1)); i=i+1; end else printf('No existe una raíz en ese intervalo'); end endfunction
  • 7. c. Como se puede observar, por ambos métodos hay una aproximación a la raíz de 6 ( ), pero por simple observación notamos claramente que el que más aproximación presenta es el realizado por el método de la secante.