$$ \int\frac{1}{1+\tan x} \,dx $$
One method to solve is to use $ \tan{2 \theta} = \frac{2\tan{\theta}}{1-\tan^2{\theta}} $
Second is by reducing integrand in terms of $ \sin x $ and $\cos x$
Third is to put $\tan x = t $, But it is same as the first method.
Is there any other way to solve this ?
One way is to note that $\dfrac{1}{1+\tan x}=\dfrac{\cos x}{\cos x+\sin x}$, so let $$ I_1:=\int\dfrac{\cos x}{\cos x+\sin x}\,\mathrm{d}x,\quad I_2:=\int\dfrac{\sin x}{\cos x+\sin x}\,\mathrm{d}x. $$ It is obvious that $I_1+I_2=x+C_+$ and $I_1-I_2=\log(\cos x+\sin x)+C_-$. Adding and divide by $2$ gives $I_1=\frac{1}{2}\left[x+\log(\cos x+\sin x)\right]+C$.