Let f(x) = (x + sec x) (x – tan x) By product rule,

\( f(x)=(x+secx)\dfrac{d}{dx}(x-tanx)\)

\( +(x-tanx)\dfrac{d}{dx}(x+secx)\)

\( f(x+secx)[1-\dfrac{d}{dx}tanx)]\)

\( +(x-tanx)[1+\dfrac{d}{dx}secx]\) ........(1)

Let f_{1}(x) = tan x, f_{2} (x) = sec x Accordingly, f_{1}(x + h)-tan (x + h) and f_{2} (x + h) = sec (x + h)

\( f'(x)=\lim\limits_{h \to 0}\dfrac{f(x+h)-f(x)}{h} \)

\(\lim\limits_{h \to 0}[\dfrac{tan(x+h)-tan(x)}{h}] \)

\(\lim\limits_{h \to 0}\dfrac{1}{h} [\dfrac{sin(x+h)}{cos(x+h)}-\dfrac{sinx}{cosx}]\)

\(( \lim\limits_{h \to 0} \dfrac{sinh}{h}).(\lim\limits_{h \to 0} \dfrac{1}{cos(x+h)cosx}) \)

\( 1\times \dfrac{1}{cos^2}=sec^2x\)

\( f_2'(x)=\lim\limits_{h \to 0}[\dfrac{f_2+(x+h)-f_2(x)}{h}]\)

\(\lim\limits_{h \to 0}[\dfrac{sec(x+h)-sec(x)}{h}]\)

\( \lim\limits_{h \to 0}\dfrac{1}{h}[\dfrac{1}{cos(x+h)}-\dfrac{1}{cosx}]\)

\( \lim\limits_{h \to 0}\dfrac{1}{h}[\dfrac{cosx-cos(x+h)}{cos(x+h)cosx}]\)

\( secx.\dfrac{sinx.1}{cosx}\)

\( \dfrac{d}{dx}secx=sectanx\)

From (i), (ii), and (iii), we obtain

f'(x) = (x +sec x) (1-sec^{2} x) +(x - tan x) (1+sec x tan x)