Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

There's an option for FullSimplify, which is Trig, and with it I could prevent a trigonometric identities from being used.

I'm looking for a similar option that would prevent FullSimplify from using the Euler formula

Sin[x] -> 1/2/I (Exp[x] - Exp[-x])
Cos[x] -> 1/2   (Exp[x] + Exp[-x])

So I want FullSimplify to retain Sin and Cos functions and to use trig identities, but no conversions to Exp.

Edit

Example as requested from a comment:

Cos[2 B g t] Sin[u]^2 - I Sin[2 B g t] Sin[u]^2

In this formula, I want FullSimplify not to convert Cos[2 B g t] - I Sin[2 B g t] to Exp[-2IBgT].

share|improve this question
1  
A small example that shows the problem you have? –  Nasser Feb 22 at 11:40
    
@Nasser example given. –  The Quantum Physicist Feb 22 at 12:19
    
Simplify[TrigReduce[s]] gives (Cos[2 B g t] - I Sin[2 B g t]) Sin[u]^2 but this might not generalize without more testing... –  Nasser Feb 22 at 12:25
    
@Nasser This occurred to me actually, but is this as powerful as FullSimplify[] in everything? I mean I could probably need more functions that are not available in Simplify[]. –  The Quantum Physicist Feb 22 at 12:27

1 Answer 1

Given:

 expr = Cos[2 B g t] Sin[u]^2 - I Sin[2 B g t] Sin[u]^2

... one approach is:

 FullSimplify[expr, ExcludedForms -> {Cos[_], Sin[_]}]

(Cos[2 B g t] - I Sin[2 B g t]) Sin[u]^2


Another approach worth exploring is to use a custom ComplexityFunction, as per:

FF[ee_] := 1000 Count[ee, _Exp, {0, Infinity}] + LeafCount[ee] 

FullSimplify[expr, ComplexityFunction -> FF]

Alas, the latter is not working as I might have expected, which is perhaps of interest in its own right.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.