
Chain rule
Hey,
I am currently having difficulties applying the chain rule to problems from what i can gather the chain rule is the derivative of the inside multiplied by the derivative of the outside
I tried working through a problem but screwed up somewhere,
The problem
find the derivative
$\displaystyle
k(x)=x^{2}sec(\frac{1}{x})
$
what I did
$\displaystyle k(x)=x^{2}sec(\frac{1}{x})$
=$\displaystyle 2x(secxtanx)\( \frac{x(0)1(x)}{x}) $
=$\displaystyle 2x(secxtanx)(\frac{1x}{x^{2}})$
=$\displaystyle 2x(secxtanx)(\frac{1}{x})$
=$\displaystyle \frac{2x(secx^{3})}{x}$
Am i on the right path

$\displaystyle f(x)=x^2sec(\frac{1}{x})$
$\displaystyle f'(x)=2xsec(\frac{1}{x})+x^2(sec(\frac{1}{x}))'$
$\displaystyle (sec(\frac{1}{x})'={\frac{tan(frac{1}{x})sec(\frac{1}{x})}{x^2}}$
$\displaystyle f'(x)=2xsec(\frac{1}{x})+x^2{\frac{tan(\frac{1}{x} )sec(\frac{1}{x})}{x^2}}=2xsec(\frac{1}{x}){{tan(\frac{1}{x})sec(\frac{1}{x})}$