CHAPTER 03.04: NEWTON-RAPHSON METHOD: Finding Square Root of a Number - A Newton-Raphson Method Approach   In this segment, we're going to find the square root of a number, and we're going to show you the application of the Newton-Raphson method to do so. So, the question arises that what does Newton-Raphson method have to do with finding the square root of a number? So let me give you some background.    So let's suppose somebody tells you to find the square root of a number like 62.41.  You can always go into your calculator and it'll give you the value of the square root to be 7.9, so what you are basically using is either the square root key in your calculator, or you're using the y raised power x key in your calculator, where y raised power x is simply you'd say 62.41 and then you'd say raised to the power one half, and you will be able to get 7.9 as the answer.  Now there are some . . . there's some algorithm which allows you to do that on your calculator or on your computer. ' 'The most common algorithm is as follows, that if you are trying to find the square root of a number, let's suppose you're trying to find the square root of a number R, y is equal to . . . let's suppose y is equal to square root of R, so that means that what you are trying to do is you are trying to find out . . . if you are able to find the value of y, you have basically found out what the square root of R is. So, what you can do is you can take log of both sides, say log of y is equal to log of square root of R, which is same as log of R raised power half. Now, what you're going to get is log of y is equal to log of R raised power half, so you're going to use the log formula of log of a raised to the power b is b log a, so that's one half log of R, and then what you're going to do is you're going to say e to the power log of y, now we're going to take e to the power of both sides, e to the power of log of y is equal to e to the power one half log of R here. And what is e to the power log of y?  It is y itself, so y is equal to e to the power one half log of R.  So that's how you'll be able to find out what the value of a square root of a positive number is, by taking the log of both sides, and then taking e to the power of both sides. And now we can see that in order to be able to find out the square root of a number, that you have to take the log of the number, so that involves some kind of a look-up table and interpolation, or use of a Taylor series. Same thing again, here, when you're trying to find e to the power of a number, again, that will involve some kind of a look-up table and interpolation, or use of a Taylor series to be able to find out what that number is, and those are computationally quite intensive, if look at it . . . if you compare it with simple multiplication, addition, division, and subtraction type of operations.    So let's go ahead and take this example of 62.41 and see what happens.  So if you have y is equal to 62.41, and you raise to the power half, you get log of y is equal to one half log of 62.41, and this one turns out to be 2.0668, and then if I take e to the power log of y is equal to e to the power 2.0668, I get this, and that gives me y is equal to 7.9.  It is the same number which I got by using my square root button on the . . . on the calculator, or by using the y raised power x button.  But that's the kind of algorithm which is used, generally, to find out the square root of a number.    So what does the Newton-Raphson method have to do with this all? What Newton-Raphson method has to do with it is that we're going to use the solution of an equation to find out the square root of a number.  So let's suppose somebody says, hey, I want to find the square root of a number R, a positive number R.  So I can write it as an equation x is equal to square root of R, but that can be also written as x squared equal to R, by squaring both sides, so that's how I'm writing down the equation x squared is equal to R, and in order to be able to solve by Newton-Raphson method, I'm going to say, hey, I'm going to write in the form f of x equal to 0, then I have x squared minus R equal to 0 right there. Now, in order to apply Newton-Raphson method, Newton-Raphson method is simply saying that, hey, this is the recursive formula which you'll have to use if you want to find out the solution of an equation which is of the form f of x equal to 0, this recursive formula is going to give you the square root of R.  So, in this case, f of x is x squared minus R, which we just established, and then f prime of x is nothing but 2 times x.  So if I substitute in there, I get x-sub-i-plus-1 is equal to xi minus xi squared minus R, divided by 2 xi, and I can simplify it a little bit by saying that, hey, this is 2 xi here, 2 xi squared minus xi squared minus R here, by doing that.  And further simplification will give me 2 xi squared minus xi squared plus R, divided by 2 xi, and that will give me xi squared plus R, divided by 2 xi.  So I'll show you the simplifications, 1 divided by 2, now I've got xi here plus R divided by xi here, so that is a simplified version of showing the Newton-Raphson method formula here for finding the square root of R. So this is what's going to help you to find out the square root of R, this recursive formula.  You're going to choose something as initial guess, then find out the new guess, and then you're going to keep on doing this process here.  In the next segment, I'm going to show you an example of applying this formula.  And that's the end of this segment.