Everything2
Near Matches
Ignore Exact
Full Text
Everything2

approximating square roots using first-order Taylor series

created by jt

(idea) by jt (1.5 y) (print)   ?   (I like it!) 1 C! Fri May 25 2001 at 4:48:08

To estimate the square root of a number using only simple arithmetic, the first-order Taylor series of the square root function provides a convenient method. As any calculus student knows, the first-order Taylor expansion around x2 is given by
sqrt(x2 + a)  ~  x + a / 2x
In practice, this can provide a good, quick estimate of a number's square root, which we illustrate by calculating the square root of 40. Obviously the nearest integer square is 36, so in the equation above we can put x = 6 and a = 40-36 =4. This gives sqrt(40) as approximately 6+4/12 = 6.3333..., whereas the true value is around 6.324 (note that this method always yields a slight over-estimate, since we're approximating a concave-down curve by its tangent at x2).

Of course, if the number in question is slightly below the nearest integer square, we simply use a negative value of a in the formula above; for example, to find the square root of 250 we note that 162 is 256, so a good approximation is 16 - 6/32 = 15.8125, as compared to the true value of 15.81138...


printable version
chaos

Babylonian square root algorithm Taylor Series Iterative methods for finding the roots of a function Frost protection thanks to water
mathematics Simpson's Rule approximation square root
The four levels of visibility in Java vector stroke function
tangent estimate Square root
formula Calculus arithmetic The Neverhood
Antigravity device Trapezoidal Rule formal logic Presburger Arithmetic
Y'know, if you log in, you can write something here, or contact authors directly on the site. Create a New User if you don't already have an account.
  Epicenter
Login
Password

password reminder
register

Everything2 Help

Cool Staff Picks
Nodes your grandpa would have liked:
Bud and Travis
Send me the pillow, the one that you dream on
Knowing how to sleep with someone
Gauss' Law
Bourbon
Virginity Pledge
snowflakes and nylon
When the Sun Rises
Prester John
Breeders: your children do not make you superior
nu-metal
clicker training
Vamp
New Writeups
Aerobe
Watch out for falling meat(poetry)
C-Dawg
Beelzebub has a devil put aside for me(fiction)
Pavlovna
My Better Half(fiction)
kanoodle
Molson muscle(essay)
aneurin
You pays your money and you takes your choice(idea)
shaogo
July 20, 2008(log)
Glowing Fish
Tualatin River(place)
The Jacket
Words of Advice(idea)
John_Fox
Good Intentions Gone Wrong(person)
Heitah
Posthumous Oscar(thing)
ignis_glaciesque
University of South Florida(place)
ignis_glaciesque
Flogstaskriket(idea)
liveforever
Caesar's last breath(idea)
dagnyswaggart
she wants to believe(personal)
antigravpussy
he doesn't know, but her eyes widen too far(thing)
Everything 2 is brought to you by the letter C and The Everything Development Company