Continued fractions are a fascinating way to represent never ending, never-repeating decimal expansions like pi or e.
As a fun exercise on this Friday evening, take out your smart phone and open the calculator app and try this :
What do you get? Do you recognize this number? If you did, then try answering why it mysteriously popped out of nowhere to represent this continued fraction.
When one is dealing with complex numbers, it is many a times useful to
think of them as transformations. The problem at hand is to find the n
roots of unity. i.e
As is common knowledge z = 1 is always a solution.
Multiplication as a transformation
Multiplication in the complex plane is mere rotation and scaling. i.e
Now what does finding the n roots of unity mean?
If
you start at 1 and perform n equal rotations( because multiplication is nothing but rotation + scaling ), you should again end up
at 1.
We just need to find the complex numbers that do this.i.e
This implies that :
And therefore :
Take a circle, slice it into n equal parts and voila you have your n roots of unity.
Okay, but what does this imply ?
Multiplication by 1 is a 360o / 0o rotation.
When
you say that you are multiplying a positive real number(say 1) with 1 ,
we get a number(1) that is on the same positive real axis.
Multiplication by (-1) is a 180o rotation.
When you multiply a positive real number (say 1) with -1, then we get a number (-1) that is on the negative real axis
The act of multiplying 1 by (-1) has resulted in a 180o transformation. And doing it again gets us back to 1.
Multiplication by i is a 90o rotation.
Similarly multiplying by i takes 1 from real axis to the imaginary axis, which is a 90o rotation.
One is commonly asked to prove in college as part of a linear
algebra problem set that matrix multiplication is not commutative. i.e
If A and B are two matrices then :
But without getting into the Algebra part of it, why should this even
be true ? Let’s use linear transformations to get a feel for it.
If A and B are two Linear Transformations namely Rotation and Shear. Then it means that.
Is that true? Well, lets perform these linear operations on a unit square and find out:
(Rotation)(Shearing)
(Shearing)(Rotation)
You can clearly see that the resultant shape is not the same upon the
two transformations.
This means that the order of matrix multiplication
matters a lot ! ( or matrix multiplication is not commutative.)
And it has been known since as early as 1350 that this series diverges. Oresme’s proof to it is just so beautiful.
Now replace ever term in the bracket with the lowest term that is present in it. This will give a lower bound on S1.
Clearly the lower bound of S1 diverges and therefore S1 also diverges.
But it interesting to note that of divergence is incredibly small: 10 billion terms in the series only adds up to around 23.6 !
If you are thinking – ‘Dude, its a bunch of numbers, can’t i just make my own credit card number?’. Well, then this post is for you.
You see in order to ensure that people don’t game the system, credit card companies have a simple set of rules. ( a checksum )
“Mod-10″ Algorithm
The Luhn algorithm or the mod-10 algorithm is what you need to beat. Its used to validate a lot of things from credit cards to social security numbers.
Say you have a credit card whose number is 4012-8888-8888-1881. In order to
check whether the credit card is a valid one, then we have to do a
really simple mathematical operation.
Double every other number and add them. Call this sum – x
Add the rest of the numbers. Call this sum -y
If (x+y) is a multiple of 10, then its a valid card, otherwise its not.
Valid credit card numbers
The last number in a credit card is known as a ‘checksum’ and it plays a vital role.
According to this, only 4012-8888-8888-1881 is a valid card number. not 4012-8888-8888-1882, 4012-8888-8888-1883,4012-8888-8888-1884, 4012-8888-8888-1885 …… 4012-8888-8888-1889.
( because they their sum is not a multiple of 10 )
Of course, although this was good enough algorithm in the 20th century, with high processing power you can do much more than a simple mod 10 test.
Therefore, the present day check sum although is based on this, is packed with much more fascinating mathematics.
If you are thinking – ‘Dude, its a bunch of numbers, can’t i just make my own credit card number?’. Well, then this post is for you.
You see in order to ensure that people don’t game the system, credit card companies have a simple set of rules. ( a checksum )
“Mod-10″ Algorithm
The Luhn algorithm or the mod-10 algorithm is what you need to beat. Its used to validate a lot of things from credit cards to social security numbers.
Say you have a credit card whose number is 4012-8888-8888-1881. In order to
check whether the credit card is a valid one, then we have to do a
really simple mathematical operation.
Double every other number and add them. Call this sum – x
Add the rest of the numbers. Call this sum -y
If (x+y) is a multiple of 10, then its a valid card, otherwise its not.
Valid credit card numbers
The last number in a credit card is known as a ‘checksum’ and it plays a vital role.
According to this, only 4012-8888-8888-1881 is a valid card number. not 4012-8888-8888-1882, 4012-8888-8888-1883,4012-8888-8888-1884, 4012-8888-8888-1885 …… 4012-8888-8888-1889.
( because they their sum is not a multiple of 10 )
Of course, although this was good enough algorithm in the 20th century, with high processing power you can do much more than a simple mod 10 test.
Therefore, the present day check sum although is based on this, is packed with much more fascinating mathematics.
On Monday, the Onion reported that the “Nation’s math teachers introduce 27 new trig functions”. It’s a funny read. The gamsin, negtan, and cosvnx from the Onion article are fictional, but the piece has a kernel of truth: there are 10 secret trig functions you’ve never heard of, and they have delightful names like ‘haversine’ and ‘exsecant’.
Trigonometry and its weird names have baffled me for ages. I decided to put an end to this madness by trying to understand them ;P
Here is my interpretation on what thy mean. You can find a detailed etymology here.
Sine
Sine ( meaning ~ bowstring in sanskrit )is ratio of the length of the bowstring with the diameter of the circle that the bow makes.
Sin(theta) because this ratio is solely dependent on the angle ‘theta’. Even the slightest change in theta messes up this ratio.
So, when theta = 90 (or 2*theta = 180) , we can see that x = d. This is why sin(90)= 1.
Cosine
‘Compliment sine’ ( ratio in the perpendicular direction of sine )
Cosine is the ratio of the distance between the bowstring and the center of the bow circle to the diameter of the circle.
So, when theta = 0 , we can see that y = d. This is why cos(0)= 1.
Sine2 + cosine 2 = 1 ?
Well.. thats because of our old friend Pythagoras
Have a great day!
Tangent (’touching’)
Imagine you are the center of the circle and shoot an arrow through
the point (x,y). Your friend is on the circumference of the circle and
starts running perpendicular to the circle.
Tangent is the distance that your friend needs to cover in order to catch that arrow.
Heres why the tangent is sin/cos
Why so many functions ?
It is important to realize that the reason why we have so many trigonometry functions: Trigonometric functions are merely ratios of distances.
Before the days of calculators, these ratios were manually calculated, and as a result, many functions were introduced and made into tables to ease the computation.
By virtue of everyday usage, the fact that (-1) x (-1) = 1 has been engraved onto our heads. But, only recently did I actually sit down to explore why, in general negative times negative yields a positive number !
Intuition.
Let’s play a game called “continue the pattern”. You would be surprised, how intuitive the results are:
2 x 3 = 6
2 x 2 = 4
2 x 1 = 2
2 x 0 = 0
2 x (-1) = ?? (Answer : -2 )
2 x (-2 ) = ?? (Answer : -4 )
2 x ( -3) = ?? (Answer : -6 )
The number on the right-hand side keeps decreasing by 2 !
Therefore positive x negative = negative.
2 x -3 = -6
1 x -3 = -3
0 x -3 = 0
-1 x -3 = ?? (Answer : 3)
-2 x -3 = ?? (Answer : 6)
The number on the right-hand side keeps increasing by 3.
Therefore negative x negative = positive.
Pretty Awesome, right? But, let’s up the ante and compliment our intuition.
The Number Line Approach.
Imagine a number line on which you walk. Multiplying x*y is taking x steps, each of size y.
Negative steps require you to face the negative end of the line before you start walking and negative step sizes are backward (i.e., heel first) steps.
So, -x*-y means to stand on zero, face in the negative direction, and then take x backward steps, each of size y.
Ergo, -1 x -1 means to stand on 0, face in the negative direction, and then take 1 backward step. This lands us smack right on +1 !
The Complex Numbers Approach.
The “i” in a complex number is an Instruction! An instruction to turn 90 degrees in the counterclockwise direction. Then i * i would be an instruction to turn 180 degrees. ( i x i = -1 ). where i = √-1
Similarly ( -1 ) x i x i = (- 1 ) x ( -1 )= 1. A complete revolution renders you back to +1.
We can snug in conveniently with the knowledge of complex numbers. But, complex numbers were established only in the 16th century and the fact that negative time negative yields a positive number was well established before that.
Concluding remarks.
Hope you enjoyed the post and Pardon me if you found this to be rudimentary for your taste. This post was inspired by Joseph H. Silverman’s Book – A friendly Introduction to Number Theory. If you are passionate about numbers or math, in general it is a must read.
There are several other arithmetic methods that prove the same, if you are interested feel free to explore.