Derivative of ln|x|§
The function ln ∣ x ∣ \ln |x| ln ∣ x ∣ is defined for all x ∈ R ∖ { 0 } x \in \mathbb{R} \setminus \{0\} x ∈ R ∖ { 0 } and can be expressed as:
ln ∣ x ∣ = { ln x , x > 0 ln ( − x ) , x < 0 \ln |x| =
\begin{cases}
\ln x, & x > 0 \\
\ln(-x), & x < 0
\end{cases} ln ∣ x ∣ = { ln x , ln ( − x ) , x > 0 x < 0
Differentiating each case separately:
For x > 0 x > 0 x > 0 , we have
d d x ( ln x ) = 1 x \frac{d}{dx} (\ln x) = \frac{1}{x} d x d ( ln x ) = x 1
For x < 0 x < 0 x < 0 , we have
d d x ( ln ( − x ) ) = 1 − x ⋅ ( − 1 ) = 1 x \frac{d}{dx} (\ln (-x)) = \frac{1}{-x} \cdot (-1) = \frac{1}{x} d x d ( ln ( − x )) = − x 1 ⋅ ( − 1 ) = x 1
Thus, for all x ≠ 0 x \neq 0 x = 0 :
d d x ( ln ∣ x ∣ ) = 1 x , x ∈ R ∖ { 0 } \frac{d}{dx} (\ln |x|) = \frac{1}{x}, \quad x \in \mathbb{R} \setminus \{0\} d x d ( ln ∣ x ∣ ) = x 1 , x ∈ R ∖ { 0 }
Differentiating Determinants§
Let us consider the determinant of a 2 × 2 2 \times 2 2 × 2 matrix whose entries are functions of x x x :
D ( x ) = ∣ a ( x ) b ( x ) c ( x ) d ( x ) ∣ = a ( x ) d ( x ) − b ( x ) c ( x ) . D(x) =
\begin{vmatrix}
a(x) & b(x) \\
c(x) & d(x)
\end{vmatrix}
= a(x)d(x) - b(x)c(x). D ( x ) = a ( x ) c ( x ) b ( x ) d ( x ) = a ( x ) d ( x ) − b ( x ) c ( x ) .
Differentiating both sides with respect to x x x ,
D ′ ( x ) = a ′ ( x ) d ( x ) + a ( x ) d ′ ( x ) − b ′ ( x ) c ( x ) − b ( x ) c ′ ( x ) . D'(x) = a'(x) d(x) + a(x) d'(x) - b'(x) c(x) - b(x) c'(x). D ′ ( x ) = a ′ ( x ) d ( x ) + a ( x ) d ′ ( x ) − b ′ ( x ) c ( x ) − b ( x ) c ′ ( x ) .
Now, grouping the first and fourth terms together and the second and third terms together :
D ′ ( x ) = ( a ′ ( x ) d ( x ) − b ( x ) c ′ ( x ) ) + ( a ( x ) d ′ ( x ) − b ′ ( x ) c ( x ) ) . D'(x) = \left( a'(x) d(x) - b(x) c'(x) \right) + \left( a(x) d'(x) - b'(x) c(x) \right). D ′ ( x ) = ( a ′ ( x ) d ( x ) − b ( x ) c ′ ( x ) ) + ( a ( x ) d ′ ( x ) − b ′ ( x ) c ( x ) ) .
Observing each group separately, we recognize them as determinants:
D ′ ( x ) = ∣ a ′ ( x ) b ( x ) c ′ ( x ) d ( x ) ∣ + ∣ a ( x ) b ′ ( x ) c ( x ) d ′ ( x ) ∣ . D'(x) =
\begin{vmatrix}
a'(x) & b(x) \\
c'(x) & d(x)
\end{vmatrix}
+
\begin{vmatrix}
a(x) & b'(x) \\
c(x) & d'(x)
\end{vmatrix}. D ′ ( x ) = a ′ ( x ) c ′ ( x ) b ( x ) d ( x ) + a ( x ) c ( x ) b ′ ( x ) d ′ ( x ) .
This shows that the derivative of the determinant can be computed by differentiating column-wise and summing the resulting determinants.
Alternatively, we can group the first and third terms together and the second and fourth terms together :
D ′ ( x ) = ( a ′ ( x ) d ( x ) − b ′ ( x ) c ( x ) ) − ( a ( x ) d ′ ( x ) − b ( x ) c ′ ( x ) ) . D'(x) = \left( a'(x) d(x) - b'(x) c(x) \right) - \left( a(x) d'(x) - b(x) c'(x) \right). D ′ ( x ) = ( a ′ ( x ) d ( x ) − b ′ ( x ) c ( x ) ) − ( a ( x ) d ′ ( x ) − b ( x ) c ′ ( x ) ) .
Rewriting these as determinants,
D ′ ( x ) = ∣ a ′ ( x ) b ′ ( x ) c ( x ) d ( x ) ∣ + ∣ a ( x ) b ( x ) c ′ ( x ) d ′ ( x ) ∣ . D'(x) =
\begin{vmatrix}
a'(x) & b'(x) \\
c(x) & d(x)
\end{vmatrix}
+
\begin{vmatrix}
a(x) & b(x) \\
c'(x) & d'(x)
\end{vmatrix}. D ′ ( x ) = a ′ ( x ) c ( x ) b ′ ( x ) d ( x ) + a ( x ) c ′ ( x ) b ( x ) d ′ ( x ) .
This expresses the derivative as the sum of two determinants obtained by differentiating row-wise .
Thus, we observe the foloowing rule:
The derivative of a determinant can be computed by summing determinants obtained by differentiating column-wise .
Equivalently, it can be computed by summing determinants obtained by differentiating row-wise .
Extending this to an n × n n \times n n × n determinant , we obtain the general formula:
d d x det A ( x ) = ∑ j = 1 n det A j ( x ) , \frac{d}{dx} \det A(x) = \sum_{j=1}^{n} \det A_j(x), d x d det A ( x ) = j = 1 ∑ n det A j ( x ) ,
where A j ( x ) A_j(x) A j ( x ) is the matrix obtained by differentiating the j j j th row while keeping the others unchanged. The same formula holds when differentiating column-wise instead of row-wise.
For example:
Consider the 2 × 2 2 \times 2 2 × 2 matrix:
A ( x ) = [ x 2 e x sin x ln x ] . A(x) =
\begin{bmatrix}
x^2 & e^x \\
\sin x & \ln x
\end{bmatrix}. A ( x ) = [ x 2 sin x e x ln x ] .
The determinant of A ( x ) A(x) A ( x ) is:
D ( x ) = ∣ x 2 e x sin x ln x ∣ . D(x) = \begin{vmatrix} x^2 & e^x \\ \sin x & \ln x \end{vmatrix}. D ( x ) = x 2 sin x e x ln x .
To differentiate D ( x ) D(x) D ( x ) , we first differentiate column-wise :
D ′ ( x ) = ∣ 2 x e x cos x ln x ∣ + ∣ x 2 e x sin x 1 x ∣ . D'(x) =
\begin{vmatrix}
2x & e^x \\
\cos x & \ln x
\end{vmatrix}
+
\begin{vmatrix}
x^2 & e^x \\
\sin x & \frac{1}{x}
\end{vmatrix}. D ′ ( x ) = 2 x cos x e x ln x + x 2 sin x e x x 1 .
Now, differentiating row-wise :
D ′ ( x ) = ∣ 2 x e x sin x 1 x ∣ + ∣ x 2 e x cos x ln x ∣ . D'(x) =
\begin{vmatrix}
2x & e^x \\
\sin x & \frac{1}{x}
\end{vmatrix}
+
\begin{vmatrix}
x^2 & e^x \\
\cos x & \ln x
\end{vmatrix}. D ′ ( x ) = 2 x sin x e x x 1 + x 2 cos x e x ln x .
Both formulations give the same result, verifying the determinant differentiation rule.
Summation of the Series Using Differentiation §
Consider the infinite series
1 + 2 x + 3 x 2 + 4 x 3 + … , for ∣ x ∣ < 1. 1 + 2x + 3x^2 + 4x^3 + \dots, \quad \text{for } |x| < 1. 1 + 2 x + 3 x 2 + 4 x 3 + … , for ∣ x ∣ < 1.
To evaluate its sum, we first examine the related geometric series:
x + x 2 + x 3 + x 4 + … . x + x^2 + x^3 + x^4 + \dots. x + x 2 + x 3 + x 4 + … .
Since this is an infinite geometric progression with first term a = x a = x a = x and common ratio r = x r = x r = x , its sum, valid for ∣ x ∣ < 1 |x| < 1 ∣ x ∣ < 1 , is given by the standard formula for the sum of an infinite geometric series:
∑ n = 0 ∞ a r n = a 1 − r , for ∣ r ∣ < 1. \sum_{n=0}^{\infty} a r^n = \frac{a}{1 - r}, \quad \text{for } |r| < 1. n = 0 ∑ ∞ a r n = 1 − r a , for ∣ r ∣ < 1.
Applying this to our series with a = x a = x a = x and r = x r = x r = x :
x + x 2 + x 3 + x 4 + ⋯ = x 1 − x , for ∣ x ∣ < 1. x + x^2 + x^3 + x^4 + \dots = \frac{x}{1 - x}, \quad \text{for } |x| < 1. x + x 2 + x 3 + x 4 + ⋯ = 1 − x x , for ∣ x ∣ < 1.
Differentiating both sides with respect to x x x :
d d x ( x + x 2 + x 3 + x 4 + … ) = d d x ( x 1 − x ) . \frac{d}{dx} \left( x + x^2 + x^3 + x^4 + \dots \right) = \frac{d}{dx} \left( \frac{x}{1-x} \right). d x d ( x + x 2 + x 3 + x 4 + … ) = d x d ( 1 − x x ) .
Applying term-by-term differentiation on the left:
1 + 2 x + 3 x 2 + 4 x 3 + … . 1 + 2x + 3x^2 + 4x^3 + \dots. 1 + 2 x + 3 x 2 + 4 x 3 + … .
Using the quotient rule on the right:
d d x ( x 1 − x ) = ( 1 − x ) ( 1 ) − x ( − 1 ) ( 1 − x ) 2 = 1 ( 1 − x ) 2 . \frac{d}{dx} \left( \frac{x}{1-x} \right) = \frac{(1-x)(1) - x(-1)}{(1-x)^2} = \frac{1}{(1-x)^2}. d x d ( 1 − x x ) = ( 1 − x ) 2 ( 1 − x ) ( 1 ) − x ( − 1 ) = ( 1 − x ) 2 1 .
Thus, the sum of the given series is:
1 + 2 x + 3 x 2 + 4 x 3 + ⋯ = 1 ( 1 − x ) 2 , for ∣ x ∣ < 1. 1 + 2x + 3x^2 + 4x^3 + \dots = \frac{1}{(1-x)^2}, \quad \text{for } |x| < 1. 1 + 2 x + 3 x 2 + 4 x 3 + ⋯ = ( 1 − x ) 2 1 , for ∣ x ∣ < 1.
Consider another infinite series as example:
1 2 + 2 2 x + 3 2 x 2 + 4 2 x 3 + … , for ∣ x ∣ < 1. 1^2 + 2^2 x + 3^2 x^2 + 4^2 x^3 + \dots, \quad \text{for } |x| < 1. 1 2 + 2 2 x + 3 2 x 2 + 4 2 x 3 + … , for ∣ x ∣ < 1.
To evaluate its sum, we begin with the geometric series:
1 + x + x 2 + x 3 + x 4 + ⋯ = 1 1 − x , for ∣ x ∣ < 1. 1 + x + x^2 + x^3 + x^4 + \dots = \frac{1}{1-x}, \quad \text{for } |x| < 1. 1 + x + x 2 + x 3 + x 4 + ⋯ = 1 − x 1 , for ∣ x ∣ < 1.
Differentiating both sides with respect to x x x ,
d d x ( 1 + x + x 2 + x 3 + x 4 + … ) = d d x ( 1 1 − x ) . \frac{d}{dx} \left( 1 + x + x^2 + x^3 + x^4 + \dots \right) = \frac{d}{dx} \left( \frac{1}{1-x} \right). d x d ( 1 + x + x 2 + x 3 + x 4 + … ) = d x d ( 1 − x 1 ) .
Using term-by-term differentiation on the left,
0 + 1 + 2 x + 3 x 2 + 4 x 3 + … . 0 + 1 + 2x + 3x^2 + 4x^3 + \dots. 0 + 1 + 2 x + 3 x 2 + 4 x 3 + … .
Applying the derivative to the right-hand side,
1 ( 1 − x ) 2 . \frac{1}{(1-x)^2}. ( 1 − x ) 2 1 .
Thus,
1 + 2 x + 3 x 2 + 4 x 3 + ⋯ = 1 ( 1 − x ) 2 , for ∣ x ∣ < 1. 1 + 2x + 3x^2 + 4x^3 + \dots = \frac{1}{(1-x)^2}, \quad \text{for } |x| < 1. 1 + 2 x + 3 x 2 + 4 x 3 + ⋯ = ( 1 − x ) 2 1 , for ∣ x ∣ < 1.
Multiplying both sides by x x x ,
x + 2 x 2 + 3 x 3 + 4 x 4 + ⋯ = x ( 1 − x ) 2 . x + 2x^2 + 3x^3 + 4x^4 + \dots = \frac{x}{(1-x)^2}. x + 2 x 2 + 3 x 3 + 4 x 4 + ⋯ = ( 1 − x ) 2 x .
Differentiating again,
d d x ( x + 2 x 2 + 3 x 3 + 4 x 4 + … ) = d d x ( x ( 1 − x ) 2 ) . \frac{d}{dx} \left( x + 2x^2 + 3x^3 + 4x^4 + \dots \right) = \frac{d}{dx} \left( \frac{x}{(1-x)^2} \right). d x d ( x + 2 x 2 + 3 x 3 + 4 x 4 + … ) = d x d ( ( 1 − x ) 2 x ) .
Applying term-by-term differentiation on the left,
1 + 2 ⋅ 2 x + 3 ⋅ 3 x 2 + 4 ⋅ 4 x 3 + … . 1 + 2 \cdot 2x + 3 \cdot 3x^2 + 4 \cdot 4x^3 + \dots. 1 + 2 ⋅ 2 x + 3 ⋅ 3 x 2 + 4 ⋅ 4 x 3 + … .
Using the quotient rule on the right,
( 1 − x ) 2 ( 1 ) − x ( 2 ( 1 − x ) ( − 1 ) ) ( 1 − x ) 4 . \frac{(1-x)^2 (1) - x (2(1-x)(-1))}{(1-x)^4}. ( 1 − x ) 4 ( 1 − x ) 2 ( 1 ) − x ( 2 ( 1 − x ) ( − 1 )) .
Simplifying,
( 1 − x ) 2 + 2 x ( 1 − x ) ( 1 − x ) 4 = ( 1 − x + 2 x ) ( 1 − x ) ( 1 − x ) 4 = ( 1 + x ) ( 1 − x ) ( 1 − x ) 4 . \frac{(1-x)^2 + 2x(1-x)}{(1-x)^4} = \frac{(1-x+2x)(1-x)}{(1-x)^4} = \frac{(1+x)(1-x)}{(1-x)^4}. ( 1 − x ) 4 ( 1 − x ) 2 + 2 x ( 1 − x ) = ( 1 − x ) 4 ( 1 − x + 2 x ) ( 1 − x ) = ( 1 − x ) 4 ( 1 + x ) ( 1 − x ) .
Canceling 1 − x 1-x 1 − x in the numerator,
1 + x ( 1 − x ) 3 . \frac{1+x}{(1-x)^3}. ( 1 − x ) 3 1 + x .
Thus, the sum of the given series is:
1 2 + 2 2 x + 3 2 x 2 + 4 2 x 3 + ⋯ = 1 + x ( 1 − x ) 3 , for ∣ x ∣ < 1. 1^2 + 2^2 x + 3^2 x^2 + 4^2 x^3 + \dots = \frac{1+x}{(1-x)^3}, \quad \text{for } |x| < 1. 1 2 + 2 2 x + 3 2 x 2 + 4 2 x 3 + ⋯ = ( 1 − x ) 3 1 + x , for ∣ x ∣ < 1.
Consider the following series as another example :
cos x + 2 cos 2 x + 3 cos 3 x + ⋯ + n cos n x . \cos x + 2\cos 2x + 3\cos 3x + \dots + n\cos nx. cos x + 2 cos 2 x + 3 cos 3 x + ⋯ + n cos n x .
To find its closed-form sum, we start with the known result for the sum of sine terms in an arithmetic sequence:
∑ k = 1 n sin k x = sin n x 2 sin x 2 sin ( n + 1 ) x 2 . \sum_{k=1}^{n} \sin kx = \frac{\sin \frac{nx}{2}}{\sin \frac{x}{2}} \sin \frac{(n+1)x}{2}. k = 1 ∑ n sin k x = sin 2 x sin 2 n x sin 2 ( n + 1 ) x .
This follows from the standard summation formula:
∑ k = 0 n − 1 sin ( a + k d ) = sin n d 2 sin d 2 sin ( a + ( n − 1 ) d 2 ) . \sum_{k=0}^{n-1} \sin (a + kd) = \frac{\sin \frac{nd}{2}}{\sin \frac{d}{2}} \sin \left( a + \frac{(n-1)d}{2} \right). k = 0 ∑ n − 1 sin ( a + k d ) = sin 2 d sin 2 n d sin ( a + 2 ( n − 1 ) d ) .
Setting a = x a = x a = x and d = x d = x d = x , we obtain:
∑ k = 1 n sin k x = sin n x 2 sin x 2 sin ( n + 1 ) x 2 . \sum_{k=1}^{n} \sin kx = \frac{\sin \frac{nx}{2}}{\sin \frac{x}{2}} \sin \frac{(n+1)x}{2}. k = 1 ∑ n sin k x = sin 2 x sin 2 n x sin 2 ( n + 1 ) x .
Differentiating both sides with respect to x x x ,
∑ k = 1 n k cos k x = d d x [ sin n x 2 sin x 2 sin ( n + 1 ) x 2 ] . \sum_{k=1}^{n} k \cos kx = \frac{d}{dx} \left[ \frac{\sin \frac{nx}{2}}{\sin \frac{x}{2}} \sin \frac{(n+1)x}{2} \right]. k = 1 ∑ n k cos k x = d x d [ sin 2 x sin 2 n x sin 2 ( n + 1 ) x ] .
This derivative can be computed explicitly. I leave it as exercise. The final result provides a closed-form expression for the given summation.