Given: #f(x)=sqrt((1+tanx)/(1-tanx))#
To make this easier visually, we'll let #(1+tanx)/(1-tanx)=u#
So we have #f(x)=sqrtu#
By the chain rule we're solving this:
#color(red)(d/(du)[sqrtu])*color(blue)(d/dx[(1+tanx)/(1-tanx)]#
Each derivative is a different technique so that's why a color-coded it.
#color(red)(d/dx[sqrtu]=>d/dx[u^(1/2)]#
#color(red)"By the Power Rule"#
#color(red)(=1/2u^(1/2-1)=1/2u^(-1/2)=1/(2u^(1/2))=1/(2sqrtu)#
#color(blue)(d/dx[(1+tanx)/(1-tanx)]larr "This requires the quotient rule"#
#color(blue)(=(d/dx[1+tanx]*(1-tanx)-d/dx[1-tanx]*(1+tanx))/(1-tanx)^2#
#color(blue)(=(sec^2x*(1-tanx)--sec^2x*(1+tanx))/(1-tanx)^2#
#color(blue)("We can simplify this if we rewrite everything in terms of sines and cosines"#
#color(blue)(=(1/cos^2x*(1-sinx/cosx)+1/cos^2x*(1+sinx/cosx))/(1-sinx/cosx)^2#
#color(blue)("Combine " (1-sinx/cosx) & (1+sinx/cosx)" And Simplify"#
#color(blue)(=(1/cos^2x*((cosx-sinx)/cosx)+1/cos^2x*((cosx+sinx)/cosx))/((cosx-sinx)/cosx)^2#
#=color(blue)(((cosx-sinx)/cos^3x)+((cosx+sinx)/cos^3x))/(color(blue)((cosx-sinx)^2/cos^2x)#
#color(blue)("Combine the numerator and simplify"#
#color(blue)(=((cosx-sinx+cosx+sinx)/cos^3x)/((cosx-sinx)^2/cos^2x)#
#color(blue)(=((2cosx)/cos^3x)/((cosx-sinx)^2/cos^2x)#
#color(blue)(=(2/cos^2x)/((cosx-sinx)^2/cos^2x)#
#color(blue)("Divide Fractions " (a/b)/(c/d)=(a*d)/(b*c) #
#color(blue)(=2/cos^2x*cos^2x/(cosx-sinx)^2=(2cos^2x)/(cos^2x(cosx-sinx)^2)#
#color(blue)(=(2)/((cosx-sinx)^2)#
#color(blue)("Expand " (cosx-sinx)^2 " and rewrite"#
#color(blue)(=2/(cos^2x-2cosxsinx+sin^2x)#
#color(blue)(=2/(cos^2x+sin^2x-2cosxsinx)#
#color(blue)("Use the identities and rewrite":#
#color(blue)(cos^2x+sin^2x=1#
#color(blue)(2cosxsinx=sin(2x)#
#color(blue)("So we get.."#
#color(blue)(=2/(1-sin(2x))#
So now that we have our two derivatives we can put it all together to get:
#f'(x)=color(red)(1/(2sqrtu))*color(blue)(2/(1-sin(2x))#
Recall that we have to reverse the substitution and substitute back #(1+tanx)/(1-tanx)# for #u#
#f'(x)=1/(2sqrt((1+tanx)/(1-tanx)))*2/(1-sin(2x))#
We can simplify this if need be but I'm pretty tired from all the work done previously but you will get:
#f'(x)=sqrt(1-tanx)/((1-sin(2x))sqrt(1+tanx))#
I think a very important lesson here (seeing how this is a lot of work) is that don't be discouraged by the size of the problem. If you think about it, this was more algebra/trigonometry than calculus. In addition, you must be on top of trigonometry skills because they will show up everywhere in calculus as seen here.
So work hard and stay sharp! :)