Ask Your Question
1

exponential equation real solution

asked 2010-10-02 23:24:29 -0600

amalea gravatar image

updated 2011-04-28 12:00:07 -0600

Kelvin Li gravatar image

How can I solve the equation exp(2x)+exp(-2x)==2

to get only the real solution x==0 ?

Thanks for help.

edit retag flag offensive close merge delete

Comments

amalea: I notice there is some italic formatting in your question. Does it display as you intend? The askbot software will be updated soon by Evgeny to fix "escaping" issues that result in formatting problems.

ccanonc gravatar imageccanonc ( 2010-10-07 08:16:02 -0600 )edit

For the record, this question is closely related to http://ask.sagemath.org/question/155/exponential-equation

Kelvin Li gravatar imageKelvin Li ( 2011-04-28 12:01:03 -0600 )edit

2 answers

Sort by ยป oldest newest most voted
0

answered 2010-10-04 05:01:08 -0600

niles gravatar image

I don't see a built-in method for this, but you could solve the equation which makes the imaginary part of the general solution zero:

sage: solutions = (exp(-2*x)+exp(2*x) == 2).solve(x,to_poly_solve=True)

sage: eq1 = solutions[0]
sage: eq1
x == I*pi*z29

sage: rhs = eq1.right()
sage: rhs
I*pi*z29

sage: rhs.imag()
pi*real_part(z29)

sage: rhs.variables()
(z29,)

sage: (rhs.imag() == 0).solve(var)
[z29 == 0]

This gives the value of z29 which makes the imaginary part zero; so now substitute this value into the original equation, eq1:

sage: solutions_2 = (rhs.imag() == 0).solve(var)
sage: eq2 = solutions_2[0]

sage: eq1
x == I*pi*z29
sage: eq2
z29 == 0

sage: eq1.substitute(eq2)
x == 0

This should work for any equation you start with; you could wrap this in a function if you need to call it repeatedly (if you do that, make sure to check that there is only one solution in solutions and solutions_2, otherwise you'll want to use those equations too).

edit flag offensive delete link more
0

answered 2010-10-06 21:38:27 -0600

Well, my answer doesn't use Sage, but: your equation is equivalent to cosh(2x) == 1. The hyperbolic cosine function (cosh) has a global minimum at 0, so there's only one real solution: zero.

Other things that can help you figure this out: plot exp(2x) + exp(-2x) and see what it looks like. Show that the derivative is positive for all positive x, and negative for all negative x, and use that to prove that the function has a global minimum at 0, so that the original equation can only have one solution.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2010-10-02 23:24:29 -0600

Seen: 1,375 times

Last updated: Oct 06 '10