The random variables X and Y are independent and identically distributed with normal mixture
distributions. The components of the mixture have N(0; 1) and N(3; 2) distributions with mixing
probabilities p1 and p2 = 1−p1 respectively.
1. Generate a bivariate random sample from the joint distribution of (X; Y ) and construct a contour
plot. Adjust the levels of the contours so that the the contours of the second mode are visible.
2. Construct a filled contour plot of the bivariate mixture distribution.
3. Construct a surface plot of the bivariate mixture distribution.
4. Repeat Exercise (1) for various different choices of the parameters of the mixture model, and
compare the distributions through contour plots.