Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: Handling branch cuts in trig functions
Replies: 9   Last Post: Mar 26, 2013 4:54 PM

 Messages: [ Previous | Next ] Topics: [ Previous | Next ]
 clicliclic@freenet.de Posts: 1,245 Registered: 4/26/08
Re: Handling branch cuts in trig functions
Posted: Mar 24, 2013 5:02 PM

"Nasser M. Abbasi" schrieb:
>
> I tried to simplify sqrt( sec(x)^2 ) but Mathematica will
> only do this by assuming x is inside one branch, say
> x>-Pi/2 && x<Pi/2 but Maple and maxima simplified it
> but they gave the answer is terms of |sec(x)| to take
> care of the sign which depends on the branch.
>
> Here is plot of sec(x)
>
> http://mathworld.wolfram.com/Secant.html
>
> -----------------------------
> In[37]:= Assuming[x>-Pi/2&&x<Pi/2,Simplify[Sqrt[Sec[x]^2]]]
> Out[37]= Sec[x]
>
> In[39]:= Assuming[x > Pi/2 && x < Pi, Simplify[Sqrt[Sec[x]^2]]]
> Out[39]= -Sec[x]
> ------------------------------
>
> If I just tell M that x>0, it will not simplify it.
>
> ------------------------------
> In[38]:= Assuming[x>0,Simplify[Sqrt[Sec[x]^2]]]
> Out[38]= Sqrt[Sec[x]^2]
> -------------------------------
>
> but Maple did it only with the x>0 assumption:
>
> ----------------------
> restart;
> simplify(sqrt(sec(x)^2)) assuming x::positive;
>
> 1
> --------
> |cos(x)|
> restart;
> simplify(sqrt(sec(x)^2));
> / 1 \
> csgn|------|
> \cos(x)/
> ------------
> cos(x)
> ---------------------------------
>
> On maxima 12.04.0
>
> sqrt(sec(x)^2);
> |sec(x)|
>
> I think now that answer to sqrt(sec(x)^2) should be
> |sec(x)| without need to give the branch. Since the only
> different is the sign. Or is there something else here?
>

Mathematica and Maple by default work in the complex plane, and must
therefore define ABS(z) = SQRT(RE(z)^2 + IM(z)^2), which agrees with
your SQRT(z^2) = SQRT(RE(z)^2 + 2*#i*RE(z)*IM(z) - IM(z)^2) only if
IM(z) = 0. So SQRT(SEC(z)^2) can be 'simplified' to ABS(SEC(z)) only
where SEC(z) = 1/COS(z) is real, that is for all real z only. Both
systems should be able to simplify SQRT(SEC(z)^2) - ABS(SEC(z)) to zero
if z is restricted to real.

Martin.

Date Subject Author
3/24/13 Nasser Abbasi
3/24/13 G. A. Edgar
3/24/13 Nasser Abbasi
3/24/13 Richard Fateman
3/24/13 Axel Vogt
3/25/13 G. A. Edgar
3/26/13 Richard Fateman
3/26/13 Axel Vogt
3/24/13 clicliclic@freenet.de
3/24/13 Axel Vogt