We know, first principal is,
f′(x)=limh→0f(x+h)−f(x)h
So with f(x)=tan2x we have
f′(x)=limh→0tan(2x+2h)−tan2xh
=limh→0sin(2x+2h)cos(2x+2h)−sin2xcos2xh [ tanA=sinAcosA]
=limh→01h[sin(2x+2h)cos(2x+2h)−sin2xcos2x]
=limh→01h[sin(2x+2h)cos2x−cos(2x+2h)sin2xcos(2x+2h)cos2x]
=limh→01h[sin(2x+2h−2x)cos(2x+2h)cos2x] [ sin(A−B)=sinA.cosB−cosB.sinA]
=limh→01h[sin(2h)cos(2x+2h)cos2x]
=limh→01cos(2x+2h)cos2x.sin2hh
=limh→02cos(2x+2h)cos2x.sin2h2h
=limh→02cos(2x+2h)cos2x.limh→0sin2h2h
We know, limh→0sinhh=1⇒limh→0sin2h2h=1
f′(x)=2cos2x.cos2x.1
=2cos22x
=2sec22x