9. Given that $a, b$ are non-zero constants, and the variable $\theta$ satisfies the inequality system $\left\{\begin{array}{l}a \sin \theta+b \cos \theta \geqslant 0 \\ a \cos \theta-b \sin \theta \geqslant 0\end{array}\right.$, find the maximum value of $\sin \theta$.
9. Solution: Let $x=\cos \theta, y=\sin \theta$, then the constraint conditions become $\left\{\begin{array}{l}b x+a y \geqslant 0 \\ a x-b y \geqslant 0 \\ x^{2}+y^{2}=1\end{array}\right.$

Thus, the problem is to find the maximum value of the y-coordinate of points in the region determined by (1) and (2) on the unit circle (3).
(1) When $a>0, b>0$, the feasible region is the shaded part in Figure 1. The y-coordinate of the intersection point of the line $a x-b y=0$ with the unit circle in the first quadrant is the maximum, solving gives $y_{\max }=\frac{a}{\sqrt{a^{2}+b^{2}}}$.
(2) When $a>0, b<0$, the feasible region is the shaded part in Figure 4,

Solving gives $y_{A}=-\frac{b}{\sqrt{a^{2}+b^{2}}}, y_{B}=\frac{a}{\sqrt{a^{2}+b^{2}}}$.
When $a \leqslant-b$, $y_{\text {max }}=-\frac{b}{\sqrt{a^{2}+b^{2}}}$, when $a>-b$, $y_{\text {max }}=\frac{a}{\sqrt{a^{2}+b^{2}}}$.