1. Write a Newton-Raphson root solver 2. Write a bi-section root solver 3. Write a secant...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
1. Write a Newton-Raphson root solver 2. Write a bi-section root solver 3. Write a secant method root-solver 4. Demonstrate their effectiveness on the following functions. Your solution should output, in a table, each iteration showing, at the minimum, itera- tion number and current error. (a) Find all roots of f(x) = x³ - 7.01x² + 16.05x - 12.06 cos(x) 1-x² (c) h(x) = sin(x) cos(exp(-x)) (b) g(x) = = 5. Extend your Newton-Raphson root solver written in Part 1 to the multi- dimensional case, and compute the abscissas and weights for Gauss-Legendre quadrature rules up to 6th order with a Newton convergence tolerance of € = 10-8. This is definitely a case of 'Work smarter, not harder'. 6. Using your Gauss data from Part 5, integrate the following integrations of the functions defined in Part 4: (a) (b) f(x) dx. Compare to exact answer. g(x) dx. i. Is the answer accurate? ii. If not, how can it be improved with the integration rules you have? iii. Use your improvement strategy to get at least 6 digits of accuracy in your answer. 1. Write a Newton-Raphson root solver 2. Write a bi-section root solver 3. Write a secant method root-solver 4. Demonstrate their effectiveness on the following functions. Your solution should output, in a table, each iteration showing, at the minimum, itera- tion number and current error. (a) Find all roots of f(x) = x³ - 7.01x² + 16.05x - 12.06 cos(x) 1-x² (c) h(x) = sin(x) cos(exp(-x)) (b) g(x) = = 5. Extend your Newton-Raphson root solver written in Part 1 to the multi- dimensional case, and compute the abscissas and weights for Gauss-Legendre quadrature rules up to 6th order with a Newton convergence tolerance of € = 10-8. This is definitely a case of 'Work smarter, not harder'. 6. Using your Gauss data from Part 5, integrate the following integrations of the functions defined in Part 4: (a) (b) f(x) dx. Compare to exact answer. g(x) dx. i. Is the answer accurate? ii. If not, how can it be improved with the integration rules you have? iii. Use your improvement strategy to get at least 6 digits of accuracy in your answer.
Expert Answer:
Answer rating: 100% (QA)
Part 1 NewtonRaphson Root Solver python def newtonraphsonf fprime x0 tolerance maxiterations x x0 iteration 0 error absfx while error tolerance and it... View the full answer
Related Book For
An Introduction to Statistical Methods and Data Analysis
ISBN: 978-1305269477
7th edition
Authors: R. Lyman Ott, Micheal T. Longnecker
Posted Date:
Students also viewed these accounting questions
-
Find all roots of the equation sin z = cosh 4 by equating the real parts and then the imaginary parts of sin z and cosh 4.
-
(a) Find all roots of f(x) = x2 + 4x if f(x) Z12[x]. (b) Find four distinct linear polynomials g(x), h(x), s(x), t(x) Z12[x] so that f(x) = g(x) h(x) = s(x)t(x). (c) Do the results in part (b)...
-
Functions f and g are defined on R by f (x) := x + 1 and g (x) := 2 if x 1 and g(1) := 0. lim g (f(x) g (lim f(x))
-
Explain why b x = e x ln b .
-
Compare and contrast mandated and participatory budgeting.
-
Divide into groups of three or four students and have each group collect an original data set of values at the interval or ratio level of measurement. Test for normality and provide reasons why the...
-
Over the years there has been a dramatic increase in the flight speed \((U)\), altitude \((h)\), weight \((\mathcal{W})\), and wing loading ( \(W / A=\) weight divided by wing area) of aircraft. Use...
-
Alpha Pro Company is a marketing firm. The company's trial balance on July 31, 2011, appears below. During the month of August, the company completed the following transactions: Aug. 2 Paid rent for...
-
What is the most significant fact that people learned about abnormal psychology? What did the field of abnormal psychology that changed an existing perceptions (e.g., what "myth" did people believe...
-
The shareholders equity section of the balance sheet of TNL Systems Inc. included the following accounts at December 31, 2020: Shareholders Equity ...............................................($ in...
-
Which question would you ask in the Applying level of Bloom's Taxonomy? How can I use a spreadsheet to track my income and expenses? Who invented double-entry accounting?
-
What damages can a plaintiff recover in a defamation case? a. Can punitive damages be awarded? b. Can presumed damages be awarded?
-
True Or False Manufacturers have a duty to warn even if they neither knew nor should have known of the dangers of the sale of the product at the time it was sold.
-
True Or False Appropriation occurs when a defendant uses the plaintiffs name or picture for their own financial gain.
-
True Or False An industry as a whole may be determined to be negligent.
-
True Or False A plaintiff under assumption of risk in a strict liability case is barred from recovery.
-
A city has three hospitals. The probabilities that a patient visits Hospitals 1, 2, and 3 are 0.3, 0.4, and 0.3 respectively. A person that visits a hospital may leave without being seen by a...
-
A copper sphere of 10-mm diameter, initially at a prescribed elevated temperature T;, is quenched in a saturated (1 atm) water bath. Using the lumped capacitance method, estimate the time for the...
-
In order to assess the U. S. public's opinion about national energy policy random samples were taken of 150 residents of major coal-producing states, 200 residents of major natural gas/ oil-producing...
-
The breaking strengths for 1-foot-square samples of a particular synthetic fabric are approximately normally distributed with a mean of 2,250 pounds per square inch (psi) and a standard deviation of...
-
A food processor was receiving complaints from its customers about the firmness of its canned sweet potatoes. The firm's research scientist decided to conduct an experiment to determine if adding...
-
A and B contribute $20,000 each to form the AB partnership and agree to share profits and losses 80% to A and 20% to B. ABs partnership items for the year are as follows: (a) What is As portion of...
-
A and B form the AB equal general partnership. A contributes \($10,000\) cash and a depreciable asset with an adjusted basis of \($40,000\) and a fair market value of \($90,000.\) B contributes...
-
Which of the following taxpayers is engaged in a specified service trade or business? (a) A lawyer (b) An architect (c) A professional soccer player (d) A freelance writer who publishes articles and...
Study smarter with the SolutionInn App