I am curious why would you want to do this. Q= (X-Y)2=(Y-X)2=(|X-Y|)2
It would be an easy problem to simulate in R. That would not give you the answer, but you would have a graph at whatever level of detail you fancy. I would suggest 1,000,000.
I cannot offer a proof, but my hunch is that the result will be Gaussian.
Timothy A Ebert I can easily simulate this problem in MATLAB, R (and any other programming language, obviously). But I need the closed form (analytical solution) for E[S] and VAR[S].
By the way, P and Q have Gamma distribution not Gaussian.
Thank you for your suggestion, I am agree with your solution except the first line. The attachment is what I've done so far. Please take a look at it and correct me if I'm wrong
1. My line one is ok, since I was considering M=max, which simplified the derivation by obtaining possibility of applying product rule for the conditionally independent events.
2. Your 4th line does not follow generally from line three since the events of the alternative (OR) are usually not disjoint
3. Your derivation would be better to perform for R=1-F. VBut I cannot imagine missing the step via conditional independence which in my derivation is exploited when inferring the line of absolute no. 7 from the line of absolute no. 6. i.e.
My idea was to mention that max and min are equally difficult to manage. Note, please that if X and Y are independent then for max and min them the product rule is applicable differently as follows
F_{max(X,Y)}(x):=P{max(X,Y)x} =R_X(x) R_Y(x)
For positive random variables X denoting random AGE of a technical object, R is called reliability function.