<s>[INST] Find $\tan x $ if $\sin x+\cos x=\frac12$ It is given that $0 < x < 180^\circ$ and $\sin x+\cos x=\frac12$, Find $\tan x $. 
I tried all identities I know but I have no idea how to proceed.  Any help would be appreciated. 
 [/INST] $\sin x+\cos x=\frac12$ $\Rightarrow$
$(\sin x+\cos x)^2=\frac14$ $\Rightarrow$
$\sin^2 x+2\sin x\cos x+\cos^2 x=\frac14$ $\Rightarrow$
$1+2\sin x\cos x=\frac14$ $\Rightarrow$
$2\sin x\cos x = -\frac34$ $\Rightarrow$
$\sin x\cos x=-\frac38$.
If $a=\sin x$, $b=\cos x$, we have the system of equations
$$
\begin{align}
a+b&=\frac12\\
ab&=-\frac38
\end{align}
$$
which leads to 
$$a-\frac3{8a}=\frac12\\
a^2-\frac12a-\frac38=0$$
with the solutions $a=\frac{1\pm\sqrt7}4$.
So we get
$$
\sin x=\frac{1+\sqrt7}4, \qquad \cos x= \frac{1-\sqrt7}4 \qquad \Rightarrow \qquad \tan x = \frac{1+\sqrt7}{1-\sqrt7}\\
\sin x=\frac{1-\sqrt7}4, \qquad \cos x= \frac{1+\sqrt7}4 \qquad \Rightarrow \qquad \tan x = \frac{1-\sqrt7}{1+\sqrt7}
$$
You could also simplify the result:
$$\frac{1+\sqrt7}{\frac1-\sqrt7} = \frac{(1+\sqrt7)^2}{1-7} = -\frac{8+2\sqrt7}6= -\frac{4+\sqrt7}3$$
</s>