7594: power rules correction so (x**y)**z != x**(y*z)
Impose domain restrictions in trig sub integrals