(I've did a little search on this but couldn't found the solution.)
How to use SR.wild(0) when "abs" is present in an expression ?
Thanks.
Pedro
EXAMPLE 1 (with abs)
t=var('t')
w0 = SR.wild(0)
e1 = abs(cos(t))^2; print e1
print e1.subs( abs(w0)^2 == w0 )
abs(cos(t))^2
abs(cos(t)) #abs shouldn't be here.
EXAMPLE 2 (with tan)
t=var('t')
w0 = SR.wild(0)
e2 = tan(cos(t))^2; print e2
print e2.subs( tan(w0)^2 == w0 )
tan(cos(t))^2
cos(t) #tan and square removed.