I wish using the Symbolic toolbox to guide me in rather simple but tedious work. Part of the formulae I deal with includes the square of a generic integral (or the product of two integrals):
syms t xi h(t) a = int(h(xi), xi, 0, t) pretty(a*a)
QUESTION: Is there any command that I can use to have MATLAB deriving the following expansion (where eta is a symbolic variable of course)
int(int(h(xi), xi, 0, t) * h(eta), eta, 0, t)
i.e., automatically recognising that the product of the above integrals is the double/iterated integral of the product??
That would simplify greatly my life! Without it I am frustrated and resorted to paper and pen: I must in fact anyway evaluate the expected value of the generic quantities h(xi) as random variables and having MATLAB just simplifying the expression a tiny bit would have helped.