Test of difference between means

Let X1, · · · , Xn1 be a random sample from a N (μ1, σ2 1 ) distribution and Y1, · · · , Yn2 be a random sample from a N (μ2, σ2 2 ) distribution.
We want to test:

H0:μ1−μ2=δvsHa:μ1−μ2≠δ

MLEs of μ1 and μ2 are x¯ and y¯
MLEs of δ=μ1−μ2 is δ^=x¯−y¯

Known Variances

120

Unknown Variances

Case 1:
Sample sizes of n1,n2≥30

σ^12=S12,σ^22=S22Z=x¯−y¯−δ0S12n1+S22n2∼N(0,1)…

Case 2:
Either or both sample sizes are small (≤30)

Assume σ12=σ22=σ2

σ^2=Spooled2=(n1−1)S12+(n2−1)S22n1+n2−2t=x¯−y¯−δ0σ^2n1+σ^2n2=x¯−y¯−δ^0σ1n1+1n2∼tn1+n2−2