Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

I'm curious as to whether it's possible to get Mathematica to simplify/manipulate/expand basic expectations, conditional expectations, sums of random variables, etc. A simple example might be:

$$Var(X+Y)=E[(X+Y)^2]-(E[X]+E[Y])^2$$

It's trivial to show this can be expanded to:

$$Var(X+Y)=E[X^2]+2E[XY]+E[Y^2] - E[X]^2-2E[X]E[Y]-E[Y]^2$$

and then simplified to

$$Var(X+Y)=Var(X)+Var(Y)+2Cov(X,Y)$$

These sorts of manipulations are easy enough by hand, but when I'm exploring lots of different possibilities, it's easy to get bogged down, make mistakes, etc. It would be nice to get mathematica to do the manipulations for me. However, I haven't been able to figure out how to get Mathematica to perform these sorts of operations without defining an actual distribution. Thoughts?

share|improve this question

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.