Definite Integrals Require Attention to the Interval
A definite integral of cotangent and cosecant powers is not determined by an antiderivative alone. The interval matters: both \(\cot x\) and \(\csc x\) are undefined where \(\sin x=0\), at \(x=k\pi\) for integers \(k\). Before evaluating, check whether any such point is an endpoint or lies inside the interval.
Throughout this tutorial, \(m\) and \(n\) are nonnegative integers, and the integrand is \(\cot^m x\,\csc^n x\). When the interval contains no point \(k\pi\), the integrand is continuous there and the Fundamental Theorem of Calculus applies: if \(F'(x)=\cot^m x\,\csc^n x\), then the integral from \(a\) to \(b\) is \(F(b)-F(a)\).
For positive \(m+n\), the singularities at \(k\pi\) are not removable. Near \(x=k\pi\), \(\sin x\) behaves like \(x-k\pi\), while \(\cos x\) approaches \(1\) or \(-1\). Thus the magnitude of \(\cot^m x\,\csc^n x\) behaves like a nonzero constant times \(|x-k\pi|^{-(m+n)}\). Since \(m+n\geq 1\), the corresponding one-sided integral diverges. A principal value based on cancellation is a different notion and does not make the ordinary improper integral converge.
Evaluate First by Substitution When It Fits
The derivative identities \(\frac{d}{dx}(\cot x)=-\csc^2 x\) and \(\csc^2 x=1+\cot^2 x\) make a cotangent substitution effective when a factor of \(\csc^2 x\) is available. On an interval where the integrand is continuous, set \(u=\cot x\), so \(du=-\csc^2 x\,dx\), and transform the limits along with the integrand.
Worked Example: A Cotangent Substitution on a Closed Interval
Evaluate \(\int_{\pi/4}^{\pi/3}\cot^3 x\,\csc^2 x\,dx\). Neither endpoint nor any point between them is a multiple of \(\pi\), so the integrand is continuous on the interval.
Set \(u=\cot x\), giving \(du=-\csc^2 x\,dx\). The transformed endpoint values are \(u(\pi/4)=1\) and \(u(\pi/3)=1/\sqrt{3}\). Therefore
To check, an antiderivative in \(x\) is \(F(x)=-\frac14\cot^4 x\). Differentiation gives \(F'(x)=\cot^3 x\,\csc^2 x\). Its endpoint difference is \(-1/36-(-1/4)=2/9\), as obtained by substitution.
Definite Reduction Formulas
When a direct substitution does not finish the integral, reduction formulas replace a higher power by a lower one and an explicit endpoint term. The endpoint term must be evaluated at both limits; the recurrence does not discard it.
Write \(I_n(a,b)=\int_a^b\csc^n x\,dx\) on an interval avoiding all \(k\pi\). For integers \(n\geq 2\), integration by parts gives the cosecant-power recurrence
It reduces even powers to \(I_0(a,b)=b-a\), and odd powers to \(I_1\). The base case \(I_1\), on any interval avoiding the poles, is given by the antiderivative \(\ln|\csc x-\cot x|\). The recurrence requires \(n\geq2\); it should not be applied to \(n=1\).
Worked Example: Reduce a Definite Cosecant Fourth Power
Evaluate \(\int_{\pi/4}^{\pi/2}\csc^4 x\,dx\). Apply the recurrence with \(n=4\):
At \(x=\pi/2\), \(\csc^2 x\,\cot x=1\cdot0=0\). At \(x=\pi/4\), \(\csc^2 x\,\cot x=2\cdot1=2\). Hence the boundary term is \(0-(-2/3)=2/3\). For the lower power, \(\int\csc^2 x\,dx=-\cot x\), so
Consequently, \(I_4=2/3+(2/3)(1)=4/3\). A corresponding antiderivative is \(F(x)=-\frac13\csc^2 x\,\cot x-\frac23\cot x\). Differentiating gives \(F'(x)=\csc^4 x\), and evaluating \(F(\pi/2)-F(\pi/4)\) gives \(0-(-4/3)=4/3\).
There is also a reduction formula for mixed powers. Let \(J_{m,n}(a,b)=\int_a^b\cot^m x\,\csc^n x\,dx\), with \(m\geq1\), \(m+n>1\), and an interval avoiding the poles. Then
For \(m=1\), the last term has coefficient zero, so the formula evaluates the integral directly. For \(m\geq2\), it lowers the cotangent exponent by two. The stated conditions matter: when \(m+n=1\), the denominator vanishes and this recurrence does not apply.
Why the Mixed Recurrence Works
The recurrence follows by differentiating a product, then using \(\csc^2 x=1+\cot^2 x\). On an interval without poles, all the functions involved are differentiable, so the product rule and the Fundamental Theorem of Calculus apply.
For \(m\geq1\), the product rule and the derivative identities give \(\frac{d}{dx}(\cot^{m-1}x\,\csc^n x)=-(m-1)\cot^{m-2}x\,\csc^{n+2}x-n\cot^m x\,\csc^n x\).
Because \(\csc^{n+2}x=\csc^n x(1+\cot^2 x)\), the first product on the right is \(\cot^{m-2}x\,\csc^n x+\cot^m x\,\csc^n x\).
The derivative is therefore \(-(m-1)\cot^{m-2}x\,\csc^n x-(m+n-1)\cot^m x\,\csc^n x\).
Integrating the derivative gives its endpoint difference. Rearranging for \(J_{m,n}(a,b)\) yields the stated recurrence; division is valid because \(m+n-1>0\).
Worked Example: Use the Mixed-Power Recurrence
Evaluate \(\int_{\pi/4}^{\pi/3}\cot^2 x\,\csc^2 x\,dx\). Here \(m=2\), \(n=2\), and the interval has no pole. The mixed recurrence gives
At \(\pi/3\), \(\cot x\,\csc^2 x=(1/\sqrt3)(4/3)=4/(3\sqrt3)\). At \(\pi/4\), the product is \(1\cdot2=2\). Thus the boundary term is \(-4/(9\sqrt3)-(-2/3)=2/3-4/(9\sqrt3)\). Also,
Combining the terms gives \(J_{2,2}=2/3-4/(9\sqrt3)-(1/3)(1-1/\sqrt3)=1/3-1/(9\sqrt3)\). To check, \(F(x)=-\cot x\,\csc^2 x/3+\cot x/3\) has derivative \(\cot^2 x\,\csc^2 x\). Its endpoint difference is \(1/3-1/(9\sqrt3)\), matching the recurrence calculation.
Check Endpoint Behavior Before Using an Antiderivative
An antiderivative formula does not establish that an improper integral converges. For example, the integral of \(\csc x\) from \(0\) to \(\pi/2\) has a singular endpoint. Using \(\int\csc x\,dx=\ln|\csc x-\cot x|\), for \(0<\varepsilon<\pi/2\) the truncated integral is
Here \(\csc\varepsilon-\cot\varepsilon=\tan(\varepsilon/2)\), which is positive and tends to zero as \(\varepsilon\to0^+\). Therefore the logarithm tends to \(-\infty\), and the integral tends to \(+\infty\). The improper integral diverges; the antiderivative does not give it a finite value.
A Reliable Evaluation Checklist
For a definite cotangent-cosecant power integral, first identify the interval and test it for poles \(k\pi\). If the interval avoids them, choose an applicable substitution or reduction formula, keep all endpoint terms, and reduce only to a valid base case. If the interval has a singular endpoint or an interior pole, evaluate the required one-sided limits before treating the result as an ordinary finite integral.
These checks are part of the evaluation, not optional bookkeeping. They distinguish a valid finite definite integral from an expression whose antiderivative is usable only on pole-free intervals, or whose improper limit does not exist finitely.
Check Your Understanding
For each question, state any interval conditions needed before evaluating.
- Which substitution directly evaluates \(\int_a^b\cot^5 x\,\csc^2 x\,dx\), and how should the limits be changed?
- Use the cosecant-power recurrence to express \(I_6(a,b)\) in terms of \(I_4(a,b)\) and an endpoint term.
- For what values of \(m,n\) does the mixed recurrence stated here apply?
- What must be checked if an interval contains an interior point \(k\pi\)?
- Why is direct substitution of a singular endpoint into an antiderivative insufficient to establish convergence?