Courses
Courses for Kids
Free study material
Offline Centres
More
Store Icon
Store
seo-qna
SearchIcon
banner

How do you differentiate the given function $y=\tan x-\cot x$?

Answer
VerifiedVerified
542.4k+ views
Hint: We start solving the problem by differentiating both sides of the given equation with respect to x on both sides. We then make use of the facts that $\dfrac{d}{dx}\left( a-b \right)=\dfrac{da}{dx}-\dfrac{db}{dx}$, $\dfrac{d}{dx}\left( \tan x \right)={{\sec }^{2}}x$ and $\dfrac{d}{dx}\left( \cot x \right)=-{{\operatorname{cosec}}^{2}}x$ to proceed through the problem. We then make use of the facts that $\sec x=\dfrac{1}{\cos x}$ and $\operatorname{cosec}x=\dfrac{1}{\sin x}$ to proceed through the problem. We then make use of the fact that \[{{\sin }^{2}}x+{{\cos }^{2}}x=1\], $\sec x=\dfrac{1}{\cos x}$ and $\operatorname{cosec}x=\dfrac{1}{\sin x}$ to get the required answer for the given problem.

Complete step by step answer:
According to the problem, we are asked to differentiate the given function $y=\tan x-\cot x$.
We have given the function $y=\tan x-\cot x$ ---(1).
Let us differentiate both sides of equation (1) with respect to x.
$\Rightarrow \dfrac{dy}{dx}=\dfrac{d}{dx}\left( \tan x-\cot x \right)$ ---(2).
We know that $\dfrac{d}{dx}\left( a-b \right)=\dfrac{da}{dx}-\dfrac{db}{dx}$.
Let us use this result in equation (2).
$\Rightarrow \dfrac{dy}{dx}=\dfrac{d}{dx}\left( \tan x \right)-\dfrac{d}{dx}\left( \cot x \right)$ ---(3).
We know that $\dfrac{d}{dx}\left( \tan x \right)={{\sec }^{2}}x$ and $\dfrac{d}{dx}\left( \cot x \right)=-{{\operatorname{cosec}}^{2}}x$. Let us use this result in equation (3).
\[\Rightarrow \dfrac{dy}{dx}={{\sec }^{2}}x-\left( -{{\operatorname{cosec}}^{2}}x \right)\].
\[\Rightarrow \dfrac{dy}{dx}={{\sec }^{2}}x+{{\operatorname{cosec}}^{2}}x\] ---(4).
We know that $\sec x=\dfrac{1}{\cos x}$ and $\operatorname{cosec}x=\dfrac{1}{\sin x}$. Let us use these results in equation (4).
\[\Rightarrow \dfrac{dy}{dx}=\dfrac{1}{{{\cos }^{2}}x}+\dfrac{1}{{{\sin }^{2}}x}\].
\[\Rightarrow \dfrac{dy}{dx}=\dfrac{{{\sin }^{2}}x+{{\cos }^{2}}x}{{{\sin }^{2}}x{{\cos }^{2}}x}\] ---(5).
We know that \[{{\sin }^{2}}x+{{\cos }^{2}}x=1\]. Let us use this result in equation (5).
\[\Rightarrow \dfrac{dy}{dx}=\dfrac{1}{{{\sin }^{2}}x{{\cos }^{2}}x}\] ---(6).
We know that $\sec x=\dfrac{1}{\cos x}$ and $\operatorname{cosec}x=\dfrac{1}{\sin x}$. Let us use these results in equation (6).
\[\Rightarrow \dfrac{dy}{dx}={{\sec }^{2}}x{{\operatorname{cosec}}^{2}}x\].
So, we have found the derivative of the given function $y=\tan x-\cot x$ as \[{{\sec }^{2}}x{{\operatorname{cosec}}^{2}}x\].
$\therefore $ The derivative of the given function $y=\tan x-\cot x$ is \[{{\sec }^{2}}x{{\operatorname{cosec}}^{2}}x\].

Note: We should perform each step carefully in order to avoid confusion and calculation mistakes while solving this problem. We can also solve the given problem by making use of the facts that $\cot x=\dfrac{1}{\tan x}$ and $\dfrac{d}{dx}\left( \dfrac{u}{v} \right)=\dfrac{v\dfrac{du}{dx}-u\dfrac{dv}{dx}}{{{v}^{2}}}$ which will also give similar result. Similarly, we can expect problems to find the derivative of the given function $y=\sec x-\operatorname{cosec}x$.