Question
Question: How do you differentiate \(\operatorname{f}\left( x \right)={{\cos }^{2}}x\) ?...
How do you differentiate f(x)=cos2x ?
Solution
Problems on differentiating a function like this can be done by simply applying the laws of differentiation accordingly followed by some simplifications. We differentiate the given composite function using the chain rule of differentiation i.e., dxd[f(g(x))]=f′(g(x))g′(x) . We assume the function cosx to be similar to g(x) and apply the chain rule which leads us to the required given.
Complete step by step answer:
The function we are given is f(x)=cos2x
As the above function is a composite one, we must use the chain rule of differentiation to find the derivative of this.
According to the chain rule of differentiation dxd[f(g(x))]=f′(g(x))g′(x)
Similarly, we assume the function cosx to be similar to g(x) i.e., g(x)=cosx .
We know
⇒f(x)=cos2x=(cosx)2
Hence, from the above assumptions we can write
\Rightarrow \operatorname{f}\left( \operatorname{g}\left( x \right) \right)={{\left( \cos x \right)}^{2}}={{\left\\{ \operatorname{g}\left( x \right) \right\\}}^{2}}
Also, we know
\Rightarrow {g}'\left( x \right)=\dfrac{d\left\\{ \operatorname{g}\left( x \right) \right\\}}{dx}
Completing the above derivation, we get
⇒g′(x)=dxd(cosx)=−sinx
Therefore, applying the chain rule of differentiation we can write
⇒dxd[f(g(x))]=dg(x)df(g(x))⋅dxdg(x)
Also,
\Rightarrow \dfrac{d\operatorname{f}\left( \operatorname{g}\left( x \right) \right)}{d\operatorname{g}\left( x \right)}=\dfrac{d{{\left\\{ \operatorname{g}\left( x \right) \right\\}}^{2}}}{d\operatorname{g}\left( x \right)}
Completing the derivation, we get
⇒dg(x)df(g(x))=2cosx
Now, we substitute the above values of differentiation of the functions in the main equation as shown below
⇒dxd[f(g(x))]=dg(x)df(g(x))⋅dxdg(x)
⇒dxd[f(g(x))]=2cosx(−sinx)
Omitting the bracket, we get
⇒dxd[f(g(x))]=−2cosxsinx
We know that from the principles of trigonometric functions the formula for double angle identity of sin is
sin2x=2sinxcosx
Hence, we put the above shown expression in place of 2sinxcosx as shown below
⇒dxd[f(g(x))]=−sin2x
Thus,
⇒f′(x)=−sin2x
Therefore, we conclude that the derivative of the given function is −sin2x
Note: While applying the chain rule of differentiation we must be careful that all the functions are defined properly and the chain rule is used accordingly. Also, in spite of using the chain rule we could have also differentiated the given function by using the first principle of derivative i.e., the conventional method. Though, we prefer using the chain rule as it is simple and easy to understand.