f(x)=∫cotx−tanxcos4x+1dx =∫cosxsinx−sinxcosx2cos22x−1+1dx (∵2cos22x−1=cos4x)
=∫cos2x−sin2xsinx.cosx2cos22xdx (∵cos2x=cos2x−sin2x)
=∫cos2x2sinx.cosx.cos22xdx
=∫1sin2x.cos2xdx
On multiplying and dividing the above expression by 2, we have
f(x)=∫2sin4xdx (∵2sin2xcos2x=sin4x)
=2∫cosec 4x dx
=24ln|cosec 4x−cot4x|+C
=12ln∣∣∣1sin4x−cos4xsin4x∣∣∣+C
=12ln∣∣∣1−cos4xsin4x∣∣∣+C
=12ln∣∣∣2sin22x2sin2x⋅cos2x∣∣∣+C
=12ln|tan2x|+C (proved)