Left Hand Side:
#color(red)(1 + tan^2theta/(sec theta+1)=color(blue)(1+(sin^2theta/cos^2theta)/(1/costheta+1)#
#color(blue)(=1+(sin^2theta/cos^2theta)/((1+costheta)/cos theta)#
#color(blue)(=1+sin^2theta/cos^2theta*(cos theta)/(1+costheta)#
#color(blue)(=1+sin^2theta/cos^cancel2theta*cancel(cos theta)/(1+costheta)#
#color(blue)(=1+sin^2theta/(costheta(1+costheta)#
#color(blue)(=(cos theta+cos^2 theta+sin^2theta)/(costheta(1+cos theta))#
#color(blue)(=(cos theta+1)/(cos theta(1+cos theta)#
#color(blue)(=(1+cos theta)/(cos theta(1+cos theta)#
#color(blue)(=cancel(1+cos theta)/(cos theta cancel((1+cos theta)#
#color(blue)(=1/cos theta#
#color(blue)( :. = sec theta#