An experiment was conducted in which two types of engines A
     An experiment was conducted in which two types of engines, A and B, were compared. Gas mileage, in mpg, was measured. 50 experiments were conducted using engine A and 75 experiments were done for engine B. The gasoline used and other conditions were held constant. Average gas mileage for engine A was 36mpg and the average for B was 42mpg. Find a 96% confidence interval on the difference in mean gas mileage for the two engine types. Assume the population standard deviations are 6 and 8 for machines A and B respectively. 
  
  Solution
CI = x1 - x2 ± Z a/2 * Sqrt ( sd1 ^2 / n1 + sd2 ^2 /n2 )
 Where,
 x1 = Mean of Sample 1, x2 = Mean of sample2
 sd1 = SD of Sample 1, sd2 = SD of sample2
 a = 1 - (Confidence Level/100)
 Za/2 = Z-table value
 CI = Confidence Interval
 Mean(x1)=36
 Standard deviation( sd1 )=6
 Sample Size(n1)=50
 Mean(x2)=42
 Standard deviation( sd2 )=8
 Sample Size(n12=75
 CI = [ ( 36-42) ±Z a/2 * Sqrt( 36/50+64/75)]
 = [ (-6) ± Z a/2 * Sqrt( 1.5733) ]
 = [ (-6) ± 2.054 * Sqrt( 1.5733) ]
 = [-8.5764 , -3.4236]

