Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

The Bakhshali manuscript is a mathematical manuscript written on birch bark which was found near the village of Bakhshali in, what is now, Pakistan in

image text in transcribed

The Bakhshali manuscript is a mathematical manuscript written on birch bark which was found near the village of Bakhshali in, what is now, Pakistan in 1881. The scripts are dated around 400 AD. The manuscript gives various algorithms and techniques for variety of mathematical problems, such as computing the square roots. According to Bakhshali manuscript, the square root of a number s can be approximated as where A=x + P and D=s- 2 A where x1 is an approximate root. Write a MTLAB function function M file to calculate the square root of a positive real number using the Bakshali method. The first line of your code must read function sqrts = my sqrtB(s, sigfig) where sqrtS is the square root of s, and sigfig is the accuracy in terms of significant digits. Display the iteration number, the iterative error (%), and the actual true error (not % error) at each iteration using an fprintf statement with a reasonable format. Use MATLAB's built-in function sqrt () to calculate the true value which needs to be calculated prior to the while Using your function determine the square root of 19781.9876 with an accuracy of 14 significant digits >mysqrtB (565127.81273, 14); Relative Iterative Error % Iteration Actual Error number 299.9858444914370352 299.7736672496993720 296.4179950691633962 251.1677827254335966 67.4093329061293218 0.8641532087222429 0.0000000685146374 0.0000000000000000 2 3 69891.7267432197404560 16919.1180507205281174 3705.8853149821111401 517.6249117986966439 6.4962708304982471 0.0000005150586730 0.0000000000000000 0.0000000000000000 The square root of 565127.81273 is 751.7498338742749 Hints: Since A depends on P, and P depends on D, update D first, then P, and then A

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

AWS Certified Database Study Guide Specialty DBS-C01 Exam

Authors: Matheus Arrais, Rene Martinez Bravet, Leonardo Ciccone, Angie Nobre Cocharero, Erika Kurauchi, Hugo Rozestraten

1st Edition

1119778956, 978-1119778950

Students also viewed these Databases questions

Question

1. How does Kiwi Experience maintain a continual customer focus?

Answered: 1 week ago