Lời giải:
ĐK: $x\geq 0; x\neq 1$
$P=\frac{\sqrt{x}+1}{(\sqrt{x}-1)(\sqrt{x}+1)}-\frac{x+2}{(\sqrt{x}-1)(x+\sqrt{x}+1)}-\frac{(\sqrt{x}+1)(\sqrt{x}-1)}{(\sqrt{x}-1)(x+\sqrt{x}+1)}$
$=\frac{1}{\sqrt{x}-1}=-\frac{x+2}{(\sqrt{x}-1)(x+\sqrt{x}+1)}-\frac{x-1}{(\sqrt{x}-1)(x+\sqrt{x}+1)}$
$=\frac{x+\sqrt{x}+1-(x+2)-(x-1)}{(\sqrt{x}-1)(x+\sqrt{x}+1)}$
$=\frac{-\sqrt{x}(\sqrt{x}-1)}{(\sqrt{x}-1)(x+\sqrt{x}+1)}=\frac{-\sqrt{x}}{x+\sqrt{x}+1}$
$\Rightarrow Q=\frac{2(x+\sqrt{x}+1)}{-\sqrt{x}}+\sqrt{x}$
$=-\left(\sqrt{x}+\frac{2}{\sqrt{x}}+2\right)$
Dễ thấy $\sqrt{x}+\frac{2}{\sqrt{x}}+2\geq 2\sqrt{2}+2$ theo BĐT Cô-si
$\Rightarrow Q\leq -(2\sqrt{2}+2)$ hay $Q_{\max}=-(2\sqrt{2}+2)$