Live data from Hacker News

Why is e^(pi i) = -1?

math.toronto.edu

41–50 of 53 posts

Re: Why is e^(pi i) = -1?

#41
You remember those half-angle formulae

sin 2A = 2 sin A cos A

cos 2A = (cos A)^2 - (sin A)^2

If you are happy using sine of small x is x and cosine of small x is 1 as your base cases, you can write sine and cosine as mutually recursive functions:

         (defun sin (z)
           (if (small z)
               z
               (* 2 
                  (sin (half z))
                  (cos (half z)))))

         (defun cos (z)
           (if (small z)
               1
               (- (square (cos (half z)))
                  (square (sin (half z))))))
(sin pi) => 6.167817939221069d-7 quite close to zero (cos pi) => -1.0012055113842453d0 you can get this much closer to -1 by using 1-x^2/2 as your base case.

It had never occurred to me to do exponential the same way, as

         (defun exp (z)
           (if (small z)
               (+ 1 z)
               (square (exp (half z)))))
So it is a bit of a shock to try it and see it work just fine for complex numbers

(exp (complex 0 pi)) => #C(-1.0012055113842453d0 6.167817939221069d-7)

Re: Why is e^(pi i) = -1?

#42
post #40
post #25

Earlier quoted context omitted.

Pi is defined as the circumference of a circle of unit diameter. This isn't somehow less correct than the alternative of making that circle one of unit radius. It causes some annoying extra factors (as the PDF points out), but the alternative would cause different complications. The area of a circle, for example, would be r^2*pi/2.

The area of a circle, for example, would be r^2 pi/2. This is actually my favorite example of why pi is wrong—it's the "exception" that proves the rule. To see why, set τ = C / r = 2 pi, and then consider the following chart of common quadratic forms: integral of u 1/2 u^2 kinetic energy 1/2 m v^2 distance fallen 1/2 g t^2 spring energy 1/2 k x^2 triangular area 1/2 b h circular area 1/2 τ r^2 We see that, far from c…

Hm, is using tau a standard convention?

I've thought pi is horrible... and adopted using a loopy pi as 2pi. I loop the first vertical line over the horizontal, right, and then make it the horizontal, and so on. If that makes any sense.

I'm thinking of making a LaTeX package containing it... (and also some other personal conventions)

Also, to strengthen your point, 2pi makes the radian system a lot more natural.

Re: Why is e^(pi i) = -1?

#43

Imagine you're a complex number, which is just a type of 2-vector. Exponentiation is to do with growth at a speed which is a multiple of how big you are already. i is the multiplication which turns you through ninety degrees. If you grow in a direction which is at right angles to yourself, you turn rather than increasing in magnitude. Pi is how long it takes you to turn through a half circle. So if you grow at right…

Where does e come into this specifically? That is, why does 5^(i*pi) have an imaginary part?

Re: Why is e^(pi i) = -1?

#44
post #40

Earlier quoted context omitted.

The area of a circle, for example, would be r^2 pi/2. This is actually my favorite example of why pi is wrong—it's the "exception" that proves the rule. To see why, set τ = C / r = 2 pi, and then consider the following chart of common quadratic forms: integral of u 1/2 u^2 kinetic energy 1/2 m v^2 distance fallen 1/2 g t^2 spring energy 1/2 k x^2 triangular area 1/2 b h circular area 1/2 τ r^2 We see that, far from c…

Hm, is using tau a standard convention? I've thought pi is horrible... and adopted using a loopy pi as 2pi. I loop the first vertical line over the horizontal, right, and then make it the horizontal, and so on. If that makes any sense. I'm thinking of making a LaTeX package containing it... (and also some other personal conventions) Also, to strengthen your point, 2pi makes the radian system a lot more natural.

I made up the usage of τ myself, partially because of its typographic similarity to π, partially because it leads naturally to the usage "τ = turn". It's too bad that π has two legs while τ has only one; it would be poetic if π were , but it wasn't to be.

N.B. I have a secret master plan to spread the use of τ, but this comment is too small to contain it. ;-)

Re: Why is e^(pi i) = -1?

#45
post #40
post #25

Earlier quoted context omitted.

Pi is defined as the circumference of a circle of unit diameter. This isn't somehow less correct than the alternative of making that circle one of unit radius. It causes some annoying extra factors (as the PDF points out), but the alternative would cause different complications. The area of a circle, for example, would be r^2*pi/2.

The area of a circle, for example, would be r^2 pi/2. This is actually my favorite example of why pi is wrong—it's the "exception" that proves the rule. To see why, set τ = C / r = 2 pi, and then consider the following chart of common quadratic forms: integral of u 1/2 u^2 kinetic energy 1/2 m v^2 distance fallen 1/2 g t^2 spring energy 1/2 k x^2 triangular area 1/2 b h circular area 1/2 τ r^2 We see that, far from c…

All of those (except the circle) have the 1/2 because they're integrals of something linear. While it's true that area and integral are closely related (the latter being a special case of the former), a circle is clearly not linear.

Re: Why is e^(pi i) = -1?

#46
post #43

Imagine you're a complex number, which is just a type of 2-vector. Exponentiation is to do with growth at a speed which is a multiple of how big you are already. i is the multiplication which turns you through ninety degrees. If you grow in a direction which is at right angles to yourself, you turn rather than increasing in magnitude. Pi is how long it takes you to turn through a half circle. So if you grow at right…

Where does e come into this specifically? That is, why does 5^(i*pi) have an imaginary part?

I'll give it a shot. For me, I think about e in terms of compound interest.

I.e. you have a bank account and put in a dollar. Its a great bank, they give you 100% interest. So, after a year, you have (1 + 1) = 2 dollars.

But wait, instead, they compound twice. That is, every 6 months, you get 50% interest. So now you have (1 + 1/2)^2 = 2.25 dollars.

Instead of compounding twice, they compound 4 times. So now you have (1 + 1/4)^4 = 2.44 dollars. Each time you get interest, its given in proportion to what you have in the account at the time. So, if they are compounding 4 times:

1 --> (1.25 * 1) = 1.25 --> (1.25 * 1.25) = 1.56 --> (1.25 * 1.56) = 1.95 --> (1.25 * 1.95) = 2.44.

(Please note: Rounding error. I just typed in to two places after the decimal point).

Why 2 or 4? Lets just call it compounding n times. As n gets larger, you get more money, but it doesn't go on forever...

For n times, the formula for how much money you have is (1 + 1/n)^n. What if you want to continuously compound? I.e. at every instant, growth is proportional to the current value? Well, then you would want something like (1 + 1/infinity)^infinity. But, we can't really do that, so instead we say:

lim (n --> inf) of (1 + 1/n)^n

And thats what we call e. Start putting in larger and larger values of n and you'll see that it converges to 2.718... The point is that e is pretty much defined as the number you get when you take a number starting at 1 and have it grow in proportion to itself continuously. Instead, if you use 5 instead of e, your growing too fast. In terms of johnaspden's explanation, you'd move too far around the circle, past (-1, 0).

Also, johnaspden, your explanations are truly great, really helped me understand Euler's formula.

Edit: Small change.

Re: Why is e^(pi i) = -1?

#47
post #45
post #40

Earlier quoted context omitted.

The area of a circle, for example, would be r^2 pi/2. This is actually my favorite example of why pi is wrong—it's the "exception" that proves the rule. To see why, set τ = C / r = 2 pi, and then consider the following chart of common quadratic forms: integral of u 1/2 u^2 kinetic energy 1/2 m v^2 distance fallen 1/2 g t^2 spring energy 1/2 k x^2 triangular area 1/2 b h circular area 1/2 τ r^2 We see that, far from c…

All of those (except the circle) have the 1/2 because they're integrals of something linear. While it's true that area and integral are closely related (the latter being a special case of the former), a circle is clearly not linear.

As a circle expands, its area grows proportional to its circumference. The circumference is proportional to the radius.

So you're getting the area by integrating a linear thing.

Re: Why is e^(pi i) = -1?

#49
post #44

Earlier quoted context omitted.

Hm, is using tau a standard convention? I've thought pi is horrible... and adopted using a loopy pi as 2pi. I loop the first vertical line over the horizontal, right, and then make it the horizontal, and so on. If that makes any sense. I'm thinking of making a LaTeX package containing it... (and also some other personal conventions) Also, to strengthen your point, 2pi makes the radian system a lot more natural.

I made up the usage of τ myself, partially because of its typographic similarity to π , partially because it leads naturally to the usage " τ = turn". It's too bad that π has two legs while τ has only one; it would be poetic if π were 2τ , but it wasn't to be. N.B. I have a secret master plan to spread the use of τ , but this comment is too small to contain it. ;-)

I'd love to hear it. christopherolah.coATgmail.com

Re: Why is e^(pi i) = -1?

#50
post #45

Earlier quoted context omitted.

All of those (except the circle) have the 1/2 because they're integrals of something linear. While it's true that area and integral are closely related (the latter being a special case of the former), a circle is clearly not linear.

As a circle expands, its area grows proportional to its circumference. The circumference is proportional to the radius. So you're getting the area by integrating a linear thing.

[deleted]
Post reply on HN