Consider the following code:
Simplify[Conjugate[Inactive[cn][n, nAvg]],
Assumptions -> Inactive[cn][__] > 0]
If you run it, it will not simplify, i.e recognize that because Inactive[cn][n,nAvg] is supposed to be positive there is no need to put the conjugate. However, running this script returns:
Conjugate[Inactive[cn][n, nAvg]]
- Why isn't it working ?
- How can I make it work ?
Inactive
, but the use of a pattern. If you usedf
instead ofInactive[cn]
, the same thing would happen. It is a common misconception that patterns may be used inAssumptions
, but this is not the case.Assumptions -> f[_] > 0
does not in fact tell Mathematica thatf
is positive for any argument. However, patterns can be used inElement
. The following works:Simplify[Conjugate[f[x]], Assumptions -> Element[f[_], Reals]]
. Note that this is a feature ofElement
, not ofAssumptions
. $\endgroup$