# Unable to simplify the real part of a complex expression

Simplifying this expression shouldn't be hard. I tried adding assumptions asserting that all involved variables are real, but still the Re expression remains

Simplify[
Re[
(I (E^(I (t ω + Subscript[ϕ, 0])) + 3 I ϵ) ϵ) /
((E^(2 I (t ω + Subscript[ϕ, 0])) + 2 ϵ^2) σx^2) +
(E^(I (t ω + Subscript[ϕ, 0]))y^2 ϵ (-I E^(2 I (t ω + Subscript[ϕ, 0])) +
6 E^(I (t ω + Subscript[ϕ, 0])) ϵ + 2 I ϵ^2)) /
((E^(2 I (t ω + Subscript[ϕ, 0])) + 2 ϵ^2)^2 σx^2 σy^2)]
/.
{Exp[I (t ω + Subscript[ϕ, 0])] ->
Cos[(t ω + Subscript[ϕ, 0])] + I Sin[(t ω + Subscript[ϕ, 0])],
Exp[I 2 (t ω + Subscript[ϕ, 0])] ->
Cos[2 (t ω + Subscript[ϕ, 0])] + I Sin[2 (t ω + Subscript[ϕ, 0])]},
t ∈ Reals && ω ∈ Reals && Subscript[ϕ, 0] ∈ Reals &&
(t ω + Subscript[ϕ, 0]) ∈ Reals && σx ∈ Reals && σy ∈ Reals && ϵ ∈ Reals]


As you will see if you remove the substitutions, the Exp does not get simplified to Sin + I Cos expressions unless it is done manually.

I tried running FullSimplify, but it just stalls indefinitely. I had to abort the evaluation after 10 minutes

FullSimplify[ComplexExpand[Re[(I (E^(I (t Ω + Subscript[Φ, 0])) + 3 I ε) ε)/
((E^(2 I (t Ω + Subscript[Φ, 0])) + 2 ε^2) σx^2) + (E^(I (t Ω + Subscript[Φ, 0])) y^2
ε (-I E^(2 I (t Ω + Subscript[Φ, 0])) +  6 E^(I (t Ω + Subscript[Φ, 0])) ε + 2 I ε^2))/
((E^(2 I (t Ω + Subscript[Φ, 0])) + 2 ε^2)^2 σx^2 σy^2)] /.
{Exp[I (t Ω + Subscript[Φ, 0])] ->
Cos[(t Ω + Subscript[Φ, 0])] + I Sin[(t Ω + Subscript[Φ, 0])],
Exp[I 2 (t Ω + Subscript[Φ, 0])] ->
Cos[2 (t Ω + Subscript[Φ, 0])] + I Sin[2 (t Ω + Subscript[Φ, 0])]}]]


yields

(ε (-12 ε^3 (-2 y^2 + σy^2 + 2 ε^4 σy^2) +3 ε (y^2 (2 + 8 ε^4) - (1 + 12 ε^4)
σy^2) Cos[2 (t Ω + Subscript[Φ, 0])] - 6 ε^3 σy^2 Cos[4 (t Ω + Subscript[Φ, 0])] +
(y^2 (-1 + 4 ε^2 + 8 ε^4 - 8 ε^6) + (1 - 4 ε^2 + 8 ε^4 - 8 ε^6) σy^2) Sin[t Ω +
Subscript[Φ, 0]] + 2 ε^2 (y^2 + 2 y^2 ε^2 + σy^2 -2 ε^2 σy^2) Sin[3 (t Ω +
Subscript[Φ, 0])]))/(σx^2 σy^2 (1 + 4 ε^4 + 4 ε^2 Cos[2 (t Ω + Subscript[Φ, 0])])^2)

• ComplexExpand did the trick, it works even with Simplify – lurscher Dec 30 '15 at 21:35