A physician who has a group of thirty-eight female patients aged 18 to 24 on a special diet wishes to estimate the effect of the diet on total serum cholesterol. For this group, their average serum cholesterol is 188.4 (measured in mg/100mL). Because of a large-scale government study, the physician is willing to assume that the total serum cholesterol measurements are normally distributed with standard deviation of σ = 40.7. Find a 95% confidence interval of the mean serum cholesterol of patients on the special diet. Does the diet seem to have any effect on their serum cholesterol, given that the national average for women aged 18 to 24 is 192.0?
I am aware of the following formula. $$\bar{X} - z_{a/2}\cdot \left(\frac{\sigma}{\sqrt{n}}\right) < \mu < \bar{X} + z_{a/2}\cdot\left(\frac{\sigma}{\sqrt{n}}\right)$$
Is it correct to say that $\bar{X} = 188.4$ and $z_{a/2} = 1.96$ because of the z-value associated with 95% and $\sigma = 40.7$ and $n = 38$? Then I just plug it all it and it would give me the correct answer?
From doing that I got (175.459, 201.340). Then for the second part of the question, is it no since 192.0 is in the confidence interval and thus indicates that the diet has no effect on their serum cholesterol?
Your sample size is $n=38$, let $X$ be the serum cholesterol level of your target population. You are assuming that $X\sim \mathcal{N}(\mu, 40.7)$. So, you hypotheses are $ H_0: \mu \ge 192$ vs. $H_1:\mu < 192 $. Note that $\bar{X}_n \sim \mathcal{N}(\mu, \sigma^2/n)$. So the construction of the CI (in confidence level of $1-a$ ) is given by
$$ P\left(\mu \in \left[\bar{x}_n \pm Z_{1-a/2}\frac{\sigma}{\sqrt{n}}\right]\right) = 1-a, $$ namely, you should check whether you confidence interval $$ \left[188.4 - 1.96\times\frac{40.7}{\sqrt{38}}, 188.4 + 1.96\times\frac{40.7}{\sqrt{38}}\right] $$ contains the $\mu$ under $H_0$.