3. How Does a Calculator Work?

By M. Bourne

In the Introduction to this chapter, we wondered how a calculator (or computer) finds the square root of millions of numbers, and how it finds the cosine of millions of angles (in degrees and radians).

Calculators and computers do not hold all those answers in their memory chips. In fact, when we ask a computer to find something like sin (1) (that's in radians), it uses the polynomial expansions that we have been talking about earlier in this chapter, in Taylor Series and Maclaurin Series.

Note 1: We are not going to talk about the electronics of a calculator here. We are going to see how calculators and computers calculate most function values.

Note 2: The Maclaurin Series is used by computers (which have hardware multipliers) as described below. On the other hand, calculators do not have hardware multipliers and are more likely to use the CORDIC algorithm.

Example

To find the value of sin 1 (in radians), a calculator will use the Maclaurin Series expansion for sin x, that we found earlier.

maclaurin

The calculator substitutes into as many terms of the polynomial that it needs to in order to get the required number of decimal places. Let's say our calculator has 6 decimal place accuracy.

We simulate what the calculator will do by substituting x = 1 into each of the terms and stopping when the accuracy is achieved.

One term (the first term of the series):

sin 1 ≈ 1

Two terms:

calc

Three terms:

calc

Four terms:

calc

Five terms:

calc

Six terms:

calc

We see that there is no point going any further, since 6 decimal place accuracy has been reached.

Fourier Series

Now that you have seen Taylor Series and Maclaurin Series, and have seen how a computer uses infinite series to find the value of functions, go and check out Fourier Series, which follows this chapter.




Didn't find what you are looking for on this page? Try search:

The IntMath Newsletter

Sign up for the free IntMath Newsletter. Get math study tips, information, news and updates each fortnight. Join thousands of satisfied students, teachers and parents!

Given name: * required

Family name:

email: * required

See the Interactive Mathematics spam guarantee.

Calculus Lessons on DVD

get MathTutorDVDs

Easy to understand calculus lessons on DVD. See samples before you commit.

More info: Calculus videos

 

Book mark this page

Add this page to Del.icio.us, Furl, Digg, StumbleUpon, Google, whatever...

 


Need a break? Play a math game. Well, they all involve math... No, really!

dumbolf memoTST bola shadow factory mindfields trick-hoops-challenge crystal clear