Can we write square roots in a fraction separately? eg, $\sqrt{\frac{9-x^2}{x-2}}$ vs $\frac{\sqrt{9-x^2}}{\sqrt{x-2}}$ I was doing some questions related to functions when I came across this question where they gave us two functions as
$$\sqrt{\frac{9-x^2}{x-2}}\quad\text{and}\quad\frac{\sqrt{9-x^2}}{\sqrt{x-2}}$$
I can see that those two are a little different, but I have learned that we write $$\sqrt\frac{a}{b}=\frac{\sqrt a}{\sqrt b}$$
I am a little confused: is there a specific condition in which we can apply this?

Hint: $\sqrt{\frac{-3}{-2}}$ is defined, while $\frac{\sqrt{-3}}{\sqrt{-2}}$ is not (in case we work only with real numbers).
In your case, for $\sqrt{\frac{9-x^2}{x-2}}$ to be defined, you need $\frac{9-x^2}{x-2} \geq 0 \Leftrightarrow x \in (-\infty, -3] \cup [2, 3]$ and for $\frac{\sqrt{9-x^2}}{\sqrt{x-2}}$ you need both $9 - x^2 \geq 0$ and $x-2\geq 0$, which means $x \in [2, 3]$.
So, for $x = -4$ you have $\sqrt{\frac{9-x^2}{x-2}} = \sqrt{\frac{-7}{-6}} = \sqrt{\frac{7}{6}}$ and $\frac{\sqrt{9-x^2}}{\sqrt{x-2}} = \frac{\sqrt{-7}}{\sqrt{-6}}$ which is undefined.
