subject

Consider the function f(x) = x 2 + cos(πx) − 5. (a) matlab has a built-in function for root-finding problems called fzero. to use fzero, you first need to create a function handle which can be done with an anonymous function. if your function handle is named fun, then you can calculate the root x using the following line of code x = fzero(fun, x0); where x0 is an initial guess. use fzero and an initial guess of x0 = 5 to find the root of f(x). we will consider this to be the "exact solution" for the rest of the problem. save the exact solution in a9.dat. (b) now find the root using newton’s method. use a maximum of 50 steps, a tolerance of 10−9 , and an initial guess of x0 = 5. calculate the error by subtracting the newton’s method solution from the exact solution obtained in part (a) and then taking the absolute value. make a 1 × 2 row vector that contains the error and the number of steps of newton’s method that were performed: error number of steps . save this vector in a10.dat

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 18:00
Which is a possible benefit of having a good credit history? having a checking account low interest rate on a car loan high interest rate on a credit card offer bankruptcy
Answers: 1
question
Computers and Technology, 23.06.2019 22:30
The output voltage of a power supply is assumed to be normally distributed. sixteen observations are taken at random on voltage are as follows: 10.35, 9.30, 10.00, 9.96, 11.65, 12.00, 11.25, 9.58, 11.54, 9.95, 10.28, 8.37, 10.44, 9.25, 9.38, and 10.85
Answers: 1
question
Computers and Technology, 24.06.2019 10:00
When writing a business letter, how many times can you use the same merge field in a document? once once, unless using the address block feature unlimited it will depend on the type of document you choose
Answers: 1
question
Computers and Technology, 24.06.2019 15:30
If you want to delete an entire word at a time, which key should you press along with the backspace or delete key?
Answers: 1
You know the right answer?
Consider the function f(x) = x 2 + cos(πx) − 5. (a) matlab has a built-in function for root-finding...
Questions
question
Mathematics, 18.03.2021 23:40
question
Social Studies, 18.03.2021 23:40
question
Mathematics, 18.03.2021 23:40
question
Mathematics, 18.03.2021 23:40
Questions on the website: 13722367