Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Use the divide and average method to find the square root of a number. Example:

ID: 668340 • Letter: U

Question

Use the divide and average method to find the square root of a number. Example: Find the square root of 50. The actual answer is 7.07. Here is how you estimate. Take 50 and divide by a number, say 5 (this would be your initial guess). You get 10. Average 10 and 5, and you get 7.5 (this is your next guess). Now take 50 and divide by 7.5, you get 6.67. Average 7.5 and 6.67, and you get 7.08. As you repeat your answer will converge toward the precise answer, but you can stop at any point for an estimate. The estimated relative error s given by the following formula: Use a relative error of 10^-4 and a test your function with the following input: 0, 2, 10, and -4. The -4 should return a -2i.

Explanation / Answer

>> x=50
n=2
a=x/n

m=a+n/2
disp(x,m)
n=10
a=x/n


m=a+n/2
disp(x,m)
n=-4
a=x/n

m=a+n/2
disp(x,m)

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote