Re: ( e^(io) + e^ (-io) ) /2 = cos o



In article <2c984d26-87bd-480f-bde9-d15f7e802d10@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>,
Nando <nando.portugal@xxxxxxxxx> wrote:
On 6 Ago, 02:41, "Rob Pratt" <Rob.Pr...@xxxxxxx> wrote:
"Nando" <nando.portu...@xxxxxxxxx> wrote in message
news:0e89be75-5365-4810-9b6e-b93bb4ef294d@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

I'm supposed to do a demonstration.
It's stated that e^(io) = cos o + i sin o

And this is the exercise:
( e^(io) + e^ (-io) ) /2 = cos o

And this is what I came up with:

( e^(io) + e^ (-io) ) /2 =
= ( e ^ (io) ) /2 + 1/ ( 2 e ^ (io) ) =
= (cos o + i sin o) /2 + 1/ ( 2 ( cos o + i sin o) =
= ( (cos o + i sen o) ^2 +1) / ( 2 (cos o + i sen o) =
= ( (cos o ^2 + 2 cos o + i.sen 0 - i.sen 0 ^2) +1) / ( 2 ( cos o
+ 2i.sen 0 ) = ...

And now... I don't know where to get from here, and I get this feeling
this is getting much too complicate for the level of math I would
expect in this kind of exercise...

Any thought?

Thanks in advance!

Substitute the definition of e^() and then use two facts:
1. cosine is an even function
2. sine is an odd function

Thanks Marco, Oppt, mike3 and Rob Pratt!!

It took me some time to really understand your help... (although it
was really all very well explained).

Anyway, there was another similar exercise I still can't finish:

(e ^(io) - e ^(-io))/2 = sin o

are you sure this is what the book says? The definition of sin(o)
would be

e^(io) - e^(-io)
sin(o) = ----------------
2i

ok, so with your help:

e ^(-io) = e ^(i. -o) = sin (-o) + i.cos(-o)

If e^(io) = cos(o) + i sin(o), then e^(-io) = cos(-o) + i sin(-o)
= cos(o) - i sin(o). Luckily, you seem to have used the correct
definition below.

and, the complete equation:

( (cos o + i.sin o) - ( cos(-o) + i.sin(-o) ) ) /2 =
=( (cos o + i.sin o) - (cos o - i.sin o) )/2=
=( cos o + i.sin o - cos o + i.sin o )/2 =
=( 2i.sin o ) / 2 =
= i.sin o

Which is not, as the book states, "sin o" .
So, where did I go wrong this time?...

You have gotten the correct answer for (e ^(io) - e ^(-io))/2, but as
I mentioned above, this is not the definition of sin(o); the correct
definition divides by 2i not 2.

Rob Johnson <rob@xxxxxxxxxxxxxx>
take out the trash before replying
to view any ASCII art, display article in a monospaced font
.



Relevant Pages

  • Re: ( e^(io) + e^ (-io) ) /2 = cos o
    ... It's stated that  e^= cos o + i sin o ... this is getting much too complicate for the level of math I would ... sine is an odd function ...
    (sci.math)
  • Re: Simple and safe evaluator
    ... a few more funcs like int() and sin(). ... # expose selected math constants and functions ... I'm assuming that the _ast definitions are buried in the C part of python, but that is just a silly guess. ...
    (comp.lang.python)
  • Re: globals?
    ... It is completely relevant if you use an alternative math library. ... Nobody I know qualifies Sin() with Math they ... various programming languages. ... You can also say that other programming ...
    (microsoft.public.dotnet.languages.vb)
  • Re: ( e^(io) + e^ (-io) ) /2 = cos o
    ... there was another similar exercise I still can't finish: ... Which is not, as the book states, "sin o". ... sine is an odd function ...
    (sci.math)
  • Re: for x in list that maximizes f(x)] <--newbie help
    ... from math import sin as f ... Prev by Date: ...
    (comp.lang.python)