Mister Exam

Other calculators


y=(ctgx+x)/((1-x)(ctgx))

Derivative of y=(ctgx+x)/((1-x)(ctgx))

Function f() - derivative -N order at the point
v

The graph:

from to

Piecewise:

The solution

You have entered [src]
  cot(x) + x  
--------------
(1 - x)*cot(x)
x+cot(x)(1x)cot(x)\frac{x + \cot{\left(x \right)}}{\left(1 - x\right) \cot{\left(x \right)}}
(cot(x) + x)/(((1 - x)*cot(x)))
Detail solution
  1. Apply the quotient rule, which is:

    ddxf(x)g(x)=f(x)ddxg(x)+g(x)ddxf(x)g2(x)\frac{d}{d x} \frac{f{\left(x \right)}}{g{\left(x \right)}} = \frac{- f{\left(x \right)} \frac{d}{d x} g{\left(x \right)} + g{\left(x \right)} \frac{d}{d x} f{\left(x \right)}}{g^{2}{\left(x \right)}}

    f(x)=x+cot(x)f{\left(x \right)} = x + \cot{\left(x \right)} and g(x)=(1x)cot(x)g{\left(x \right)} = \left(1 - x\right) \cot{\left(x \right)}.

    To find ddxf(x)\frac{d}{d x} f{\left(x \right)}:

    1. Differentiate x+cot(x)x + \cot{\left(x \right)} term by term:

      1. Apply the power rule: xx goes to 11

      2. There are multiple ways to do this derivative.

        Method #1

        1. Rewrite the function to be differentiated:

          cot(x)=1tan(x)\cot{\left(x \right)} = \frac{1}{\tan{\left(x \right)}}

        2. Let u=tan(x)u = \tan{\left(x \right)}.

        3. Apply the power rule: 1u\frac{1}{u} goes to 1u2- \frac{1}{u^{2}}

        4. Then, apply the chain rule. Multiply by ddxtan(x)\frac{d}{d x} \tan{\left(x \right)}:

          1. Rewrite the function to be differentiated:

            tan(x)=sin(x)cos(x)\tan{\left(x \right)} = \frac{\sin{\left(x \right)}}{\cos{\left(x \right)}}

          2. Apply the quotient rule, which is:

            ddxf(x)g(x)=f(x)ddxg(x)+g(x)ddxf(x)g2(x)\frac{d}{d x} \frac{f{\left(x \right)}}{g{\left(x \right)}} = \frac{- f{\left(x \right)} \frac{d}{d x} g{\left(x \right)} + g{\left(x \right)} \frac{d}{d x} f{\left(x \right)}}{g^{2}{\left(x \right)}}

            f(x)=sin(x)f{\left(x \right)} = \sin{\left(x \right)} and g(x)=cos(x)g{\left(x \right)} = \cos{\left(x \right)}.

            To find ddxf(x)\frac{d}{d x} f{\left(x \right)}:

            1. The derivative of sine is cosine:

              ddxsin(x)=cos(x)\frac{d}{d x} \sin{\left(x \right)} = \cos{\left(x \right)}

            To find ddxg(x)\frac{d}{d x} g{\left(x \right)}:

            1. The derivative of cosine is negative sine:

              ddxcos(x)=sin(x)\frac{d}{d x} \cos{\left(x \right)} = - \sin{\left(x \right)}

            Now plug in to the quotient rule:

            sin2(x)+cos2(x)cos2(x)\frac{\sin^{2}{\left(x \right)} + \cos^{2}{\left(x \right)}}{\cos^{2}{\left(x \right)}}

          The result of the chain rule is:

          sin2(x)+cos2(x)cos2(x)tan2(x)- \frac{\sin^{2}{\left(x \right)} + \cos^{2}{\left(x \right)}}{\cos^{2}{\left(x \right)} \tan^{2}{\left(x \right)}}

        Method #2

        1. Rewrite the function to be differentiated:

          cot(x)=cos(x)sin(x)\cot{\left(x \right)} = \frac{\cos{\left(x \right)}}{\sin{\left(x \right)}}

        2. Apply the quotient rule, which is:

          ddxf(x)g(x)=f(x)ddxg(x)+g(x)ddxf(x)g2(x)\frac{d}{d x} \frac{f{\left(x \right)}}{g{\left(x \right)}} = \frac{- f{\left(x \right)} \frac{d}{d x} g{\left(x \right)} + g{\left(x \right)} \frac{d}{d x} f{\left(x \right)}}{g^{2}{\left(x \right)}}

          f(x)=cos(x)f{\left(x \right)} = \cos{\left(x \right)} and g(x)=sin(x)g{\left(x \right)} = \sin{\left(x \right)}.

          To find ddxf(x)\frac{d}{d x} f{\left(x \right)}:

          1. The derivative of cosine is negative sine:

            ddxcos(x)=sin(x)\frac{d}{d x} \cos{\left(x \right)} = - \sin{\left(x \right)}

          To find ddxg(x)\frac{d}{d x} g{\left(x \right)}:

          1. The derivative of sine is cosine:

            ddxsin(x)=cos(x)\frac{d}{d x} \sin{\left(x \right)} = \cos{\left(x \right)}

          Now plug in to the quotient rule:

          sin2(x)cos2(x)sin2(x)\frac{- \sin^{2}{\left(x \right)} - \cos^{2}{\left(x \right)}}{\sin^{2}{\left(x \right)}}

      The result is: sin2(x)+cos2(x)cos2(x)tan2(x)+1- \frac{\sin^{2}{\left(x \right)} + \cos^{2}{\left(x \right)}}{\cos^{2}{\left(x \right)} \tan^{2}{\left(x \right)}} + 1

    To find ddxg(x)\frac{d}{d x} g{\left(x \right)}:

    1. Apply the product rule:

      ddxf(x)g(x)=f(x)ddxg(x)+g(x)ddxf(x)\frac{d}{d x} f{\left(x \right)} g{\left(x \right)} = f{\left(x \right)} \frac{d}{d x} g{\left(x \right)} + g{\left(x \right)} \frac{d}{d x} f{\left(x \right)}

      f(x)=1xf{\left(x \right)} = 1 - x; to find ddxf(x)\frac{d}{d x} f{\left(x \right)}:

      1. Differentiate 1x1 - x term by term:

        1. The derivative of the constant 11 is zero.

        2. The derivative of a constant times a function is the constant times the derivative of the function.

          1. Apply the power rule: xx goes to 11

          So, the result is: 1-1

        The result is: 1-1

      g(x)=cot(x)g{\left(x \right)} = \cot{\left(x \right)}; to find ddxg(x)\frac{d}{d x} g{\left(x \right)}:

      1. ddxcot(x)=1sin2(x)\frac{d}{d x} \cot{\left(x \right)} = - \frac{1}{\sin^{2}{\left(x \right)}}

      The result is: (1x)(sin2(x)+cos2(x))cos2(x)tan2(x)cot(x)- \frac{\left(1 - x\right) \left(\sin^{2}{\left(x \right)} + \cos^{2}{\left(x \right)}\right)}{\cos^{2}{\left(x \right)} \tan^{2}{\left(x \right)}} - \cot{\left(x \right)}

    Now plug in to the quotient rule:

    (1x)(sin2(x)+cos2(x)cos2(x)tan2(x)+1)cot(x)(x+cot(x))((1x)(sin2(x)+cos2(x))cos2(x)tan2(x)cot(x))(1x)2cot2(x)\frac{\left(1 - x\right) \left(- \frac{\sin^{2}{\left(x \right)} + \cos^{2}{\left(x \right)}}{\cos^{2}{\left(x \right)} \tan^{2}{\left(x \right)}} + 1\right) \cot{\left(x \right)} - \left(x + \cot{\left(x \right)}\right) \left(- \frac{\left(1 - x\right) \left(\sin^{2}{\left(x \right)} + \cos^{2}{\left(x \right)}\right)}{\cos^{2}{\left(x \right)} \tan^{2}{\left(x \right)}} - \cot{\left(x \right)}\right)}{\left(1 - x\right)^{2} \cot^{2}{\left(x \right)}}

  2. Now simplify:

    (x1)cos2(x)cot(x)+(x+cot(x))(x+sin(2x)2+1)(x1)2cos2(x)\frac{\left(x - 1\right) \cos^{2}{\left(x \right)} \cot{\left(x \right)} + \left(x + \cot{\left(x \right)}\right) \left(- x + \frac{\sin{\left(2 x \right)}}{2} + 1\right)}{\left(x - 1\right)^{2} \cos^{2}{\left(x \right)}}


The answer is:

(x1)cos2(x)cot(x)+(x+cot(x))(x+sin(2x)2+1)(x1)2cos2(x)\frac{\left(x - 1\right) \cos^{2}{\left(x \right)} \cot{\left(x \right)} + \left(x + \cot{\left(x \right)}\right) \left(- x + \frac{\sin{\left(2 x \right)}}{2} + 1\right)}{\left(x - 1\right)^{2} \cos^{2}{\left(x \right)}}

The graph
02468-8-6-4-2-1010-20001000
The first derivative [src]
                           /          /        2   \         \             
     2          1          \- (1 - x)*\-1 - cot (x)/ + cot(x)/*(cot(x) + x)
- cot (x)*-------------- + ------------------------------------------------
          (1 - x)*cot(x)                          2    2                   
                                           (1 - x) *cot (x)                
(x+cot(x))((1x)(cot2(x)1)+cot(x))(1x)2cot2(x)1(1x)cot(x)cot2(x)\frac{\left(x + \cot{\left(x \right)}\right) \left(- \left(1 - x\right) \left(- \cot^{2}{\left(x \right)} - 1\right) + \cot{\left(x \right)}\right)}{\left(1 - x\right)^{2} \cot^{2}{\left(x \right)}} - \frac{1}{\left(1 - x\right) \cot{\left(x \right)}} \cot^{2}{\left(x \right)}
The second derivative [src]
                                                                     /                /                  2   \                                                /       2   \            /       2   \ /          /       2   \         \                                  \
                                                                     |         2      |    1      1 + cot (x)| /          /       2   \         \   -cot(x) + \1 + cot (x)/*(-1 + x)   \1 + cot (x)/*\-cot(x) + \1 + cot (x)/*(-1 + x)/     /       2   \                |
                   /          /       2   \         \   (x + cot(x))*|2 + 2*cot (x) + |- ------ + -----------|*\-cot(x) + \1 + cot (x)/*(-1 + x)/ - -------------------------------- + ------------------------------------------------ - 2*\1 + cot (x)/*(-1 + x)*cot(x)|
          2      2*\-cot(x) + \1 + cot (x)/*(-1 + x)/                \                \  -1 + x      cot(x)  /                                                   -1 + x                                     cot(x)                                                       /
-2 - 2*cot (x) + ------------------------------------ - ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
                                -1 + x                                                                                                                               2                                                                                                    
                                                                                                                                                         (-1 + x)*cot (x)                                                                                                 
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
                                                                                                                                  -1 + x                                                                                                                                  
2cot2(x)2(x+cot(x))(2(x1)(cot2(x)+1)cot(x)+((x1)(cot2(x)+1)cot(x))(cot2(x)+1cot(x)1x1)+((x1)(cot2(x)+1)cot(x))(cot2(x)+1)cot(x)+2cot2(x)+2(x1)(cot2(x)+1)cot(x)x1)(x1)cot2(x)+2((x1)(cot2(x)+1)cot(x))x1x1\frac{- 2 \cot^{2}{\left(x \right)} - 2 - \frac{\left(x + \cot{\left(x \right)}\right) \left(- 2 \left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) \cot{\left(x \right)} + \left(\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}\right) \left(\frac{\cot^{2}{\left(x \right)} + 1}{\cot{\left(x \right)}} - \frac{1}{x - 1}\right) + \frac{\left(\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}\right) \left(\cot^{2}{\left(x \right)} + 1\right)}{\cot{\left(x \right)}} + 2 \cot^{2}{\left(x \right)} + 2 - \frac{\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}}{x - 1}\right)}{\left(x - 1\right) \cot^{2}{\left(x \right)}} + \frac{2 \left(\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}\right)}{x - 1}}{x - 1}
The third derivative [src]
                                                                                                                                                                                                                                                         /                                                                                                                                                                                                                                                                                                                                                                                                           /                  2   \                                                                                                                                                                          /                  2   \                                                                                        \                                                     
                                                                                                                                                                                                                                                         |                                                                                                                                              /                                       2                  \                                                                                                                                                                                                 |    1      1 + cot (x)| /          /       2   \         \                  2                                                                                                      /       2   \ |    1      1 + cot (x)| /          /       2   \         \                                                     |                                                     
                                                                                                                                                                                                                                                         |    /       2      /       2   \                \                                                                                             |                          /       2   \             2     |                                                                                 /                  2   \                                                   /          /       2   \         \   |- ------ + -----------|*\-cot(x) + \1 + cot (x)/*(-1 + x)/     /       2   \  /          /       2   \         \     /       2   \ /       2      /       2   \                \   \1 + cot (x)/*|- ------ + -----------|*\-cot(x) + \1 + cot (x)/*(-1 + x)/     /       2   \ /          /       2   \         \|                                                     
  /                /                  2   \                                                /       2   \            /       2   \ /          /       2   \         \                                  \                                                  |  6*\1 + cot (x) - \1 + cot (x)/*(-1 + x)*cot(x)/     /       2   \ /          /       2   \         \     /          /       2   \         \ |       2          1       \1 + cot (x)/      1 + cot (x)  |     /       2   \ /            /       2   \                 2            \     |    1      1 + cot (x)| /       2      /       2   \                \   3*\-cot(x) + \1 + cot (x)/*(-1 + x)/   \  -1 + x      cot(x)  /                                      3*\1 + cot (x)/ *\-cot(x) + \1 + cot (x)/*(-1 + x)/   6*\1 + cot (x)/*\1 + cot (x) - \1 + cot (x)/*(-1 + x)*cot(x)/                 \  -1 + x      cot(x)  /                                      4*\1 + cot (x)/*\-cot(x) + \1 + cot (x)/*(-1 + x)/|                                                     
  |         2      |    1      1 + cot (x)| /          /       2   \         \   -cot(x) + \1 + cot (x)/*(-1 + x)   \1 + cot (x)/*\-cot(x) + \1 + cot (x)/*(-1 + x)/     /       2   \                |                                     (x + cot(x))*|- ----------------------------------------------- - 2*\1 + cot (x)/*\-cot(x) + \1 + cot (x)/*(-1 + x)/ - 2*\-cot(x) + \1 + cot (x)/*(-1 + x)/*|1 + cot (x) - --------- - -------------- + ---------------| + 2*\1 + cot (x)/*\-3*cot(x) + \1 + cot (x)/*(-1 + x) + 2*cot (x)*(-1 + x)/ + 2*|- ------ + -----------|*\1 + cot (x) - \1 + cot (x)/*(-1 + x)*cot(x)/ + ------------------------------------ - ----------------------------------------------------------- + --------------------------------------------------- + ------------------------------------------------------------- + ------------------------------------------------------------------------- - --------------------------------------------------|                                                     
3*|2 + 2*cot (x) + |- ------ + -----------|*\-cot(x) + \1 + cot (x)/*(-1 + x)/ - -------------------------------- + ------------------------------------------------ - 2*\1 + cot (x)/*(-1 + x)*cot(x)|     /       2   \ /         2   \                |                       -1 + x                                                                                                                 |                      2         2          (-1 + x)*cot(x)|                                                                                 \  -1 + x      cot(x)  /                                                                      2                                            -1 + x                                                      2                                                        cot(x)                                                                cot(x)                                                     (-1 + x)*cot(x)                  |     /       2   \ /          /       2   \         \
  \                \  -1 + x      cot(x)  /                                                   -1 + x                                     cot(x)                                                       /   2*\1 + cot (x)/*\1 + 3*cot (x)/                \                                                                                                                                              \              (-1 + x)       cot (x)                      /                                                                                                                                                                       (-1 + x)                                                                                                      cot (x)                                                                                                                                                                                                                       /   6*\1 + cot (x)/*\-cot(x) + \1 + cot (x)/*(-1 + x)/
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- + ------------------------------- - -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- - --------------------------------------------------
                                                                                                 -1 + x                                                                                                                cot(x)                                                                                                                                                                                                                                                                                                                                                                                         2                                                                                                                                                                                                                                                                                                                                                                                     (-1 + x)*cot(x)                  
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          (-1 + x)*cot (x)                                                                                                                                                                                                                                                                                                                                                                                                                   
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    -1 + x                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   
2(cot2(x)+1)(3cot2(x)+1)cot(x)(x+cot(x))(((x1)(cot2(x)+1)cot(x))(cot2(x)+1cot(x)1x1)(cot2(x)+1)cot(x)+3((x1)(cot2(x)+1)cot(x))(cot2(x)+1)2cot2(x)2((x1)(cot2(x)+1)cot(x))(cot2(x)+1)2((x1)(cot2(x)+1)cot(x))((cot2(x)+1)2cot2(x)+cot2(x)+1+cot2(x)+1(x1)cot(x)1(x1)2)+2(cot2(x)+1cot(x)1x1)((x1)(cot2(x)+1)cot(x)+cot2(x)+1)+2(cot2(x)+1)((x1)(cot2(x)+1)+2(x1)cot2(x)3cot(x))+6(cot2(x)+1)((x1)(cot2(x)+1)cot(x)+cot2(x)+1)cot(x)((x1)(cot2(x)+1)cot(x))(cot2(x)+1cot(x)1x1)x14((x1)(cot2(x)+1)cot(x))(cot2(x)+1)(x1)cot(x)6((x1)(cot2(x)+1)cot(x)+cot2(x)+1)x1+3((x1)(cot2(x)+1)cot(x))(x1)2)(x1)cot2(x)6((x1)(cot2(x)+1)cot(x))(cot2(x)+1)(x1)cot(x)+3(2(x1)(cot2(x)+1)cot(x)+((x1)(cot2(x)+1)cot(x))(cot2(x)+1cot(x)1x1)+((x1)(cot2(x)+1)cot(x))(cot2(x)+1)cot(x)+2cot2(x)+2(x1)(cot2(x)+1)cot(x)x1)x1x1\frac{\frac{2 \left(\cot^{2}{\left(x \right)} + 1\right) \left(3 \cot^{2}{\left(x \right)} + 1\right)}{\cot{\left(x \right)}} - \frac{\left(x + \cot{\left(x \right)}\right) \left(\frac{\left(\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}\right) \left(\frac{\cot^{2}{\left(x \right)} + 1}{\cot{\left(x \right)}} - \frac{1}{x - 1}\right) \left(\cot^{2}{\left(x \right)} + 1\right)}{\cot{\left(x \right)}} + \frac{3 \left(\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}\right) \left(\cot^{2}{\left(x \right)} + 1\right)^{2}}{\cot^{2}{\left(x \right)}} - 2 \left(\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}\right) \left(\cot^{2}{\left(x \right)} + 1\right) - 2 \left(\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}\right) \left(- \frac{\left(\cot^{2}{\left(x \right)} + 1\right)^{2}}{\cot^{2}{\left(x \right)}} + \cot^{2}{\left(x \right)} + 1 + \frac{\cot^{2}{\left(x \right)} + 1}{\left(x - 1\right) \cot{\left(x \right)}} - \frac{1}{\left(x - 1\right)^{2}}\right) + 2 \left(\frac{\cot^{2}{\left(x \right)} + 1}{\cot{\left(x \right)}} - \frac{1}{x - 1}\right) \left(- \left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) \cot{\left(x \right)} + \cot^{2}{\left(x \right)} + 1\right) + 2 \left(\cot^{2}{\left(x \right)} + 1\right) \left(\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) + 2 \left(x - 1\right) \cot^{2}{\left(x \right)} - 3 \cot{\left(x \right)}\right) + \frac{6 \left(\cot^{2}{\left(x \right)} + 1\right) \left(- \left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) \cot{\left(x \right)} + \cot^{2}{\left(x \right)} + 1\right)}{\cot{\left(x \right)}} - \frac{\left(\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}\right) \left(\frac{\cot^{2}{\left(x \right)} + 1}{\cot{\left(x \right)}} - \frac{1}{x - 1}\right)}{x - 1} - \frac{4 \left(\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}\right) \left(\cot^{2}{\left(x \right)} + 1\right)}{\left(x - 1\right) \cot{\left(x \right)}} - \frac{6 \left(- \left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) \cot{\left(x \right)} + \cot^{2}{\left(x \right)} + 1\right)}{x - 1} + \frac{3 \left(\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}\right)}{\left(x - 1\right)^{2}}\right)}{\left(x - 1\right) \cot^{2}{\left(x \right)}} - \frac{6 \left(\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}\right) \left(\cot^{2}{\left(x \right)} + 1\right)}{\left(x - 1\right) \cot{\left(x \right)}} + \frac{3 \left(- 2 \left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) \cot{\left(x \right)} + \left(\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}\right) \left(\frac{\cot^{2}{\left(x \right)} + 1}{\cot{\left(x \right)}} - \frac{1}{x - 1}\right) + \frac{\left(\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}\right) \left(\cot^{2}{\left(x \right)} + 1\right)}{\cot{\left(x \right)}} + 2 \cot^{2}{\left(x \right)} + 2 - \frac{\left(x - 1\right) \left(\cot^{2}{\left(x \right)} + 1\right) - \cot{\left(x \right)}}{x - 1}\right)}{x - 1}}{x - 1}
The graph
Derivative of y=(ctgx+x)/((1-x)(ctgx))