先要在表中补全X的边缘分布律,Y的边缘分布律,
则 E(X)=-1×0.3+0×0.4+1×0.3=0;E(Y)=1×0.4+2×0.2+3×0.4=2;
E(XY)=E(X)E(Y)=0;
D(X)=E(X²)-[E(X)]²=[(-1-0)²×0.3+(0-0)²×0.4+(1-0)²×0.3]-0=0.6;
D(Y)=E(Y²)-[E(Y)]²=[(1-2)²×0.4+(2-2)²×0.2+(3-2)²×0.4]-2=-1.2;
E[(X+1)(Y-1)]=E(X+1)×E(Y-1)=[(-1+1)×0.3+(0+1)×0.4+(1+1)×0.3]×[(1-1)×0.4+(2-1)×0.2+(3-1)×0.4]=1;
cov(X,Y)=E(XY)- E(X)E(Y)=0; ρxy=cov(X,Y)/[(√D(X))(√D(Y))]=0.