Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #4543 > unrolled thread

Simplifying certain trigonometric expressions

Started bySamTakoy <pavelgrinfeld@gmail.com>
First post2011-08-24 07:17 +0000
Last post2011-08-24 11:54 +0000
Articles 3 — 3 participants

Back to article view | Back to comp.soft-sys.math.mathematica


Contents

  Simplifying certain trigonometric expressions SamTakoy <pavelgrinfeld@gmail.com> - 2011-08-24 07:17 +0000
    Re: Simplifying certain trigonometric expressions "Oleksandr Rasputinov" <oleksandr_rasputinov@hmamail.com> - 2011-08-24 11:50 +0000
    Re: Simplifying certain trigonometric expressions psycho_dad <s.nesseris@gmail.com> - 2011-08-24 11:54 +0000

#4543 — Simplifying certain trigonometric expressions

FromSamTakoy <pavelgrinfeld@gmail.com>
Date2011-08-24 07:17 +0000
SubjectSimplifying certain trigonometric expressions
Message-ID<j328id$b4g$1@smc.vnet.net>
Hi,

My Mathematica has no problem with

Assuming[x > 0 && y > 0, Cos[ArcTan[y/x]] // FullSimplify]

yielding x/Sqrt[x^2 + y^2], but can't do anything with

Assuming[x > 0 && y > 0, Cos[2 ArcTan[y/x]] // FullSimplify].

How does one overcome this?

Thanks,

Pavel

[toc] | [next] | [standalone]


#4546

From"Oleksandr Rasputinov" <oleksandr_rasputinov@hmamail.com>
Date2011-08-24 11:50 +0000
Message-ID<j32ohs$drh$1@smc.vnet.net>
In reply to#4543
On Wed, 24 Aug 2011 08:17:33 +0100, SamTakoy <pavelgrinfeld@gmail.com>  
wrote:

> Hi,
>
> My Mathematica has no problem with
>
> Assuming[x > 0 && y > 0, Cos[ArcTan[y/x]] // FullSimplify]
>
> yielding x/Sqrt[x^2 + y^2], but can't do anything with
>
> Assuming[x > 0 && y > 0, Cos[2 ArcTan[y/x]] // FullSimplify].
>
> How does one overcome this?
>
> Thanks,
>
> Pavel
>

The result you are most likely looking for here has a larger LeafCount  
than the input, so in the view of FullSimplify with the default  
ComplexityFunction, the given expression cannot be made any simpler. But  
you can get a different result by specifying a ComplexityFunction biased  
against trigonometric functions:

Assuming[x > 0 && y > 0,
  FullSimplify[
   Cos[2 ArcTan[y/x]],
   ComplexityFunction -> Function[{expr},
     100 Count[expr, _Cos | _ArcTan, {0, Infinity}] + LeafCount[expr]
     ]
   ]
  ]

gives

-1 + (2 x^2)/(x^2 + y^2)

which I think is probably what you wanted.

Best,

O. R.

[toc] | [prev] | [next] | [standalone]


#4555

Frompsycho_dad <s.nesseris@gmail.com>
Date2011-08-24 11:54 +0000
Message-ID<j32oqi$duk$1@smc.vnet.net>
In reply to#4543
Try this:
Cos[2 ArcTan[y/x]] // TrigExpand // FullSimplify
The result is:
-1 + (2 x^2)/(x^2 + y^2)

Cheers

[toc] | [prev] | [standalone]


Back to top | Article view | comp.soft-sys.math.mathematica


csiph-web