Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Matlab One numerical method for calculating the cubic root of a number, 3 Squareroot Halley's method. The solution process starts by choosing a value x_1

image text in transcribed
Matlab
One numerical method for calculating the cubic root of a number, 3 Squareroot Halley's method. The solution process starts by choosing a value x_1 as a first estimate of the solution. Using this value, a second, more accurate value x_2 is calculated with, x_2 = x_1(x_1^3 + 2P)/(2x_1^3 + P) which is then used for calculating a third, still more accurate value x_3 and so on. The general equation for calculating the value of x_i + 1 from the value of x_i is x_i + 1 = x_i(x_i^3 + 2P)/(2x_i^3 + P). Write a MATLAB program that calculates the cubic root of a number. In the program use x_1 = P for the first estimate of the solution. Then, by using the general equation in a loop, calculate new, more accurate values. Stop the looping when the estimated relative error E defined by E = |x_i + 1 - x_i/x_i) is smaller than 0.00001. Use the program to calculate: (a) 3 Squareroot 800 (b) 3 Squareroot 59071 (c) 3 Squareroot -31.55

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

1 2 3 Data Base Techniques

Authors: Dick Andersen

1st Edition

0880223464, 978-0880223461

More Books

Students also viewed these Databases questions

Question

3. Develop a case study.

Answered: 1 week ago