Prove $\frac{(a+b+c)^2}{(a^2+b^2+c^2)}=\frac{\cot(A/2)+\cot(B/2)+\cot(C/2)}{\cot(A)+\cot(B)+\cot(C)}$ $\frac{(a+b+c)^2}{(a^2+b^2+c^2)}=\frac{\cot(A/2)+\cot(B/2)+\cot(C/2)}{\cot(A)+\cot(B)+\cot(C)}$
I need to solve this trigonometric identity for a trianlge. 
I'm not allowed to use the formula $a+b+c=s$ where 's' is perimeter.
My Try
Using sine rule I was able to simplify,
\begin{align}\text{L. H. S.}& =\frac{(\sin A+\sin B+ \sin C)^2}{\sin^2A+\sin^2B+\sin^2C} \\
&=\frac{4\cos^2\dfrac C2\Bigl(\dfrac{\cos(A-B)}{2}+\sin\frac C2\Bigr)^2}{\sin^2A+\sin^2B+\sin^2C}
\end{align}
I'm unable to simplify further, Please give me hint. Thanks in advance.
 A: For a triangle ABCz, we have denominator of LHS as
$$D=(a^2+b^2+c^2)=[(b^2+c^2-a^2)+(c^2+a^2-b^2)+(a^2+b^2-c^2)]$$ $$=[2bc \cos A+2ca \cos B+ 2ab \cos C]=2abc[\cos A/a+\cos B/b+\cos C/c]=\frac{abc}{R}[\cot A+\cot B+\cot C].~~~~(1)$$ In the last step we have used $ a/\sin A=b/\sin B=c/\sin C=2R.$
Next take the numerator  of  RHS as
$$N=(a+b+c)^2=4R^2[\sin A+ \sin B+\sin C]^2=64R^2[\cos^2(A/2) \cos^2(B/2) \cos^2(C/2)]$$
$$\implies N=\frac{16R^3 (\sin A \sin B \sin C) (64R^2[\cos^2(A/2) \cos^2(B/2)\cos^2(C/2)}{16R^3 (\sin A \sin B \sin C)}$$
$$\implies \frac{4(2abc)}{R}\frac{\cos^2(A/2) \cos^2(B/2)\cos^2(C/2)}{8(\sin(A/2) \cos(A/2)(\sin (B/2) \cos (B/2)(\sin (A/2) \cos (A/2)}$$
$$\implies N=\frac{abc}{R}[\cot(A/2) \cot(B/2) \cot(C/2)]=\frac{abc}{R}[\cot(A/2)+\cot(B/2)+\cot(C/2)]~~~~(2)$$
From (1) and (2) the required result follows.
Lastly we have used $$\cot(A/2)\cot(B/2)\cot(C/2)=\cot(A/2)+\cot(B/2)+\cot(C/2)]$$
in the triangle ABC.
A: Start from the RHS and use the following formulas:
Step 1:
$\cot \frac{A}{2} = \frac{\Delta}{(s-b)(s-c)}$ etc. in the numerator
$\cot A = \frac{R}{abc} (b^2 + c^2 - a^2)$ etc. in the denominator
Step 2:
$R = \frac{abc}{4 \Delta}$
Step 3:
$\Delta^2 = s(s-a)(s-b)(s-c)$
You are done!
A: Replace all $\cot x = \frac{\cos x}{\sin x}$ and expand straightforwardly as follows,
$$RHS = \frac{\frac{\cos \frac A2}{\sin \frac A2}+\frac{\cos \frac B2}{\sin \frac B2}+\frac{\cos \frac c2}{\sin \frac C2}}
{\frac{\cos A}{\sin A}+\frac{\cos B}{\sin B}+\frac{\cos C}{\sin C}}$$
$$= \frac{\cos \frac A2\sin \frac B2\sin \frac C2+\cos \frac B2\sin \frac C2\sin \frac A2+\cos \frac C2\sin \frac A2\sin \frac B2}
{\cos A\sin B\sin C+\cos B\sin C\sin A+\cos C\sin A\sin B}
\cdot 8 \cos \frac A2\cos\frac B2\cos \frac C2$$
$$= \frac{(1+\cos A)\sin B\sin C+(1+\cos B)\sin C\sin A+(1+\cos C)\sin A\sin B}
{\cos A\sin B\sin C+\cos B\sin C\sin A+\cos C\sin A\sin B}
$$
$$= 1+ \frac{\sin B\sin C+\sin C\sin A+\sin A\sin B}
{\cos A\sin B\sin C+\cos B\sin C\sin A+\cos C\sin A\sin B}
$$
$$= 1+ \frac{2\sin B\sin C+2\sin C\sin A+2\sin A\sin B}
{\sin A\sin (B+C)+\sin B\sin (C+A)+\sin C\sin (A+B)}
$$
$$= 1+ \frac{2\sin B\sin C+2\sin C\sin A+2\sin A\sin B}
{\sin^2 A+\sin^2 B+\sin^2 C}
$$
$$= 1+ \frac{2bc+2ca+2ab}
{a^2 +b^2 +c^2 } = \frac{(a+b+c)^2}{a^2+b^2+c^2}=LHS$$
