MathGroup Archive 1990

[Date Index] [Thread Index] [Author Index]

Search the Archive

Simplify made more intelligent

  • To: mathgroup at
  • Subject: Simplify made more intelligent
  • From: jacobson at
  • Date: Wed, 21 Nov 90 09:17:12 PST

Ken Yip asked for suggestions regarding Integrate[Cosh[x],x].
Basically, Mathematica always turns hyperbolics into exponentials.  So
in theory it already knows how to do this.  But note that, even with
the help of Simplify, it cannot determine that the result is equal to

In[5]:= Integrate[Cosh[x],x]==Sinh[x]

                x      -x    x
         -1    E     -E   + E
Out[5]= ---- + -- == ---------
           x   2         2
        2 E

In[6]:= Simplify[%]

              2 x      -x    x
        -1 + E       -E   + E
Out[6]= --------- == ---------
             x           2
          2 E

On the other hand, if I subtract that two from each other, Simplify can
determine that the result is zero:

In[13]:= Integrate[Cosh[x],x]-Sinh[x]

                 x     -x    x
          -1    E    -E   + E
Out[13]= ---- + -- - ---------
            x   2        2
         2 E

In[14]:= Simplify[%]

Out[14]= 0

Conclusion: If you want to check that two symbolic things are equal,
it is better to test the difference for zero than the two things for
equality.  I managed to teach Simplify to do this:

In[16]:= Unprotect[Simplify]

Out[16]= {Simplify}

In[17]:= Simplify[x_ == y_] := True /; Simplify[x-y]==0

In[18]:= Protect[Simplify]

Out[18]= {Simplify}

In[19]:= Simplify[Integrate[Cosh[x],x] == Sinh[x]]

Out[19]= True

  -- David Jacobson

  • Prev by Date: Re: Integrating hyperbolic functions
  • Next by Date: (1) Symbolic complex algebra in mathematica and (2) Dsolve
  • Previous by thread: Re: DensityGraphics --> Adobe Illustrator
  • Next by thread: (1) Symbolic complex algebra in mathematica and (2) Dsolve