[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference rusure::math

Title:Mathematics at DEC
Moderator:RUSURE::EDP
Created:Mon Feb 03 1986
Last Modified:Fri Jun 06 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:2083
Total number of notes:14613

56.0. "Everyday Approximations" by RANI::LEICHTERJ () Sat Apr 21 1984 15:23

The earlier note about "easy" approximations to Pi bring to mind two other
approximations that are handy on days your calculator isn't handy.

The first is trivial:  The accurate conversion formulas between degrees
Celsius and degrees Farenheit are C = 5/9(F-32) and F = 32+9C/5.  These
are a bit of a pain to do in your head.  However, C = .5(F-30) and
F = 30+2C are easy to compute, and are excellent approximations for
"room-like" temperatures.

The second is harder to justify:  Suppose I earn interest at n% a year.
About how long does it take to double my money?  Answer:  70/n years
is a good approximation.  (72/n is better but harder to do in your head.)

Anyone know any other useful tricks for rapid, if approximate, math?
						-- Jerry
T.RTitleUserPersonal
Name
DateLines
56.1RANI::LEICHTERJSat Apr 21 1984 15:3942
Here is another useful trick, not really an approximation though.  (I'm
often surprised at how many people DON'T know it...)  The traditional
name is "casting out nines".

It is easy to show that any numer is congruent, mod 9, to the sum of its
(decimal) digits.  Hence, you can check an addition by adding up all the
digits of the summands, and comparing mod 9 to the sum of the digits of
the putative result.  Obviously, this extends to a sum of an arbitrary
number of summands.  It is usually easier to deal with differences by
"rewriting" them as sums - i.e. chekc A-B=C as A=C+B.

Also, since you are only checking mod 9 anyway, there is no point in
calculating the actual full sum of the digits; you just retain the
sum mod 9.  With a little practice, this becomes a very quick operation:
you ignore 9 and 0, recognize 8 and 7 as -1 and -2, imediately reduce
10 and 11 to 1 and 2, and then never have to do anything with sums larger
than 8.

For "random" addition errors, you obviously have a 1/9 chance of missing
the error.  As it happens, most errors - at least the ones I tend to
make - are "off by 1" kinds of things, and are always caught.  Unfortu-
nately, digit transpositions - also somewhat common - are not caught.

If you are better at mental arithmetic, you can use adjacent pairs of
digits and do sums mod 99 (i.e. think of your numbers as base 100).
This will catch transpositions, but you can then no longer add up
digits in any order (I immediately "cancel" a 2 and a 7 if I see them,
for example.)  I've never really tried this...

Another method, less well known:  the alternating sum and difference of
the digits (base 10) is congruent to the original number mod 11.  (I
forget offhand which way the parity goes in determining which digits
get added and which subtracted).  This is, again, a better test - most
transpositions are caught, for example - but is much more complex to
do "on the fly" because you have to deal with the digits in order or
keep track of the sign in some other way.  (There may be some trick
for determining very quickly what the sign ought to be, but I doubt it -
I think you'll just have to determine whether you are an even or an odd
number of digits from the beginning (end?) of the number, which is
slow.)

							-- Jerry
56.2HARE::STANSun Apr 22 1984 06:4725
		The Frame Formula

One of the most amazing approximations I have ever seen is
the Frame Formula for solving right triangles (named after
its discoverer, J. S. Frame).

		 A
		/|
	       / |
	   c  /  | b
	     /   |
	    /    |
	    -----+
	  B   a    C

In right triangle ABC, C is the right angle, and A is the
number of degrees in the smaller acute angle.  The sides have
lengths a, b, and c as shown.  The Frame formula says that

				     172a
	A is approximately equal to  ---- degrees.
				     b+2c
	
The approximation is good to several decimal places.
This lets you solve most trig problems without using any trigonometry!
56.3HARE::STANMon Apr 23 1984 17:122
There is a real neat approximation for the distance to the horizon
given the height of your eyes above the earth. Anyone remember it?
56.4HARE::STANTue Apr 24 1984 18:054
The reference for the Frame formula is:

J. S. Frame, Solving a right triangle without tables, American
	Mathematical Monthly, 50(1943)622.
56.5METOO::YARBROUGHWed Apr 25 1984 14:1111
Logarithms base 2 can be easily approximated using either a pocket calculator
or log tables by the formula

	log (n) ~ log (n) + log  (n)
           2         e         10

The actual error is by the constant 1.00586..., so the approximation is good
to less than 1%. To calculate log/2/(n) just look up the other two logs in
your tables, add them, and if you want exactness multiply by 1.00586.

- Lynn Yarbrough -
56.6HARE::STANFri Apr 27 1984 05:2023
About the approximation for doubling your money:

I think that 70/i is actually a better approximation than 72/i,
but many people consider 72/i better because 72 is exactly divisible
by most of the small numbers for which you might want an approximation
(e.g. 2,3,4,6,8,9 and 12).

If H(q) is the number of years that it takes to multiply your money by q,
under an annual interest rate of i (so that H(2) is approximately 72/i),
then good approximations for H are as follows:

	item		approximation

	H(2)		72/i
	H(2.5)		100/i
	H(3)		120/i
	H(4)		150/i
	H(5)		180/i

		Reference
		---------

Edward L. Cohen, A Problem of Interest. Crux Mathematicorum 9(1983)166-169.
56.7HARE::STANThu Sep 20 1984 02:4916
Here's a neat approximation I just ran across:

  n
-----\			  k+1
 \       k       (n + 1/2)
  >     r    ~   ------------    .
 /		    k + 1
-----/
 r=1


			Reference
			---------

B. L. Burrows and R. F. Talbot, Sums of powers of integers. American
	Mathematical Monthly. 91(1984)394-403.
56.8LATOUR::AMARTINMon Dec 10 1984 11:0635
Re .3:

Yes, I remember the neat formula for distance to the horizon given
your height above the earth's surface:

Distance to horizon (statute miles) = SQRT(1.5*height (in feet))

What's more, I was able to rederive it this morning, and given a
reasonable figure for the Earth's radius, the number 1.5 is *exact*.
The only approximation in it is that your height above the earth is
negligible compared to the earth's diameter!

 2     2                   2
X  +  R   =   SQRT( (H + R) )


X  =  SQRT( H (H + 2R) )

Assume H<<2R:

X  =  SQRT( 2RH )

The earth's radius is 3960 statute miles (I'm unsure about the last
digit), and there are 5280 feet in a mile:

X  =  SQRT( 2*3960*R/5280 )

But, 2*3960/5280 = 3/2, so we get the above answer.

Reference:

	A small book on the mathematics of rocketry which is NOT
	G. Harry Stine's [?Handbook of Model Rocketry?], but has
	almost the same Dewey Decimal Number.
				/AHM
56.9RANI::LEICHTERJSun Dec 16 1984 18:2260
From Usenet:

Newsgroups: net.sources,net.math,net.wanted
Path: decwrl!decvax!harpo!whuxlm!whuxl!houxm!ahuta!ecl
Subject: Re: Day of Week Alg
Posted: Wed Dec 12 12:52:06 1984


REFERENCES:  <538@uwmacc.UUCP>

Re: Perpetual Calendar formula wanted

For people asking about perpetual calendar formulae, this one was in
the Webster's dictionary when I was growing up.  I memorized it and can
do it in my head.  Except for the fact that I do mod 7 reductions as 
I go along, the algorithm I use in my head is the same as the
following.

Break up the date as follows:

MONTH DD, CCYY

For Pearl Harbor day
MONTH = Dec.
DD = 7
CC = 19
YY = 41

Let [[x]] be the integer part of x.
Let y%z be y mod z.

To get the day of the week compute the following:

day = (cent(CC) + [[1.25 * YY]] + mon(MONTH) + DD - fudge)%7

cent(19) = 0
cent(18) = 2
cent(17) = 4
cent(16) = 6

month(Apr. or Jul.) = 0
month(Jan. or Oct.) = 1
month(May) = 2
month(Aug.) = 3
month(Feb. or Mar. or Oct.) = 4
month(June) = 5
month(Sept. or Dec.) = 6

fudge = 1 the first two months of a leap year, otherwise 0.

if day = 0, then the day is a Saturday,
if day = 1, then the day is a Sunday,
if day = 2, then the day is a Monday, ...

So for Pearl Harbor Day you get
day = (0 + 51 + 6 + 7 - 0)%7 = 1

					(Evelyn C. Leeper for)
					Mark R. Leeper
					...ihnp4!lznv!mrl
56.10re: The Frame FormulaELIS::GARSONV+F = E+2Tue Dec 18 1990 14:2925
re .2                                     

>		The Frame Formula
>
>		 A
>		/|
>	       / |
>	   c  /  | b
>	     /   |
>	    /    |
>	    -----+
>	  B   a    C
>
>In right triangle ABC, C is the right angle, and A is the
>number of degrees in the smaller acute angle.  The sides have
>lengths a, b, and c as shown.  The Frame formula says that
>
>				     172a
>	A is approximately equal to  ---- degrees.
>				     b+2c
	
    Can someone show why this works? With most of these approximations it
    is possible to find the exact answer and then show how the
    approximation arises by, for example, dropping higher order terms or
    whatever but this one has defeated me.
56.11Frame formula explainedALLVAX::JROTHSaturday alley up to Sunday streetWed Dec 19 1990 02:4626
    Re .10

>				     172a
>	A is approximately equal to  ---- degrees.
>				     b+2c
	
>    Can someone show why this works?

    Normalize c = 1 so that

	   a/c      sin(A)
	-------- = --------
	 b/c + 2   cos(A)+2

   Now, using the first few terms of the Taylor expansions around 0 for
   sin and cos

	    A - A^3/6 + ...        1 - A^2/6
        --------------------- ~= A --------- = A/3
	(1 - A^2/2 + ...) + 2      3 - A^2/2

   So the righthand side of the Frame formula is very nearly linear, and
   fudging the constant of proportionality for minimum error on the range
   0-45 degrees apparently gives the "magic" number 172.

   - Jim
56.12clarification ALLVAX::JROTHSaturday alley up to Sunday streetWed Dec 19 1990 03:166
   Note that 180*3/pi ~= 171.887...

   The approx is so accurate that apparently no formal minimax
   hackery is needed - just take the nearest integer.

   - Jim
56.13'Handy approximations'/optALFAI::HENNESSYJohn Hennessy, DTN 385-2476, ALFTue Aug 27 1991 23:5522