I'm looking at another way. Suppose I have the big expression expr
with many integrals. What if I do something like this:
Select[expr, MemberQ[#, S[x, y, z].S[x, y, z]] &]
My problem is the above does not work unless the integrand is exactly S[x, y, z].S[x, y, z]
. How do I write the pattern such that the condition for True would be that just part of the integrand contains S[x, y, z].S[x, y, z]
?
Thanks!