# Why can't $\int_{-1}^1{\frac{dx}{x}}$ be evaluated?

So I just saw this question on brilliant.org and found that many people argued over whether this could be evaluated. My answer was 0 because it is an odd function, but others argued that because of the vertical asymptote it can't properly be evaluated.

I understand the general concept of there being 'different' infinities because functions have different rates of change. However, I find this one especially baffling because this function fits the criteria $$1)\frac{d^{2n-1}}{dx^{2n-1}}f(x)=\frac{d^{2n-1}}{dx^{2n-1}}f(-x)$$ $$2)\frac{d^{2n}}{dx^{2n}}-f(x)=\frac{d^{2n}}{dx^{2n}}f(-x)$$ $$3) -f(x)=f(-x)$$

I know that all odd functions fit this criteria, but I'm writing this explicitly because this means that they shouldn't be different infinities at all; they start at opposite points, and go at the same rates at all times.

If this integral were expressed as a series representing $\int_{-1}^0{\frac{dx}{x}}$ and $\int_{0}^1{\frac{dx}{x}}$, there would always be a pair of points that cancel out, despite both integrals approaching infinity as they get closer to 0.

This makes it even more baffling, because I remember the sum of all whole numbers being -1/12 - the derivation of which required the canceling of many pairs of numbers representing the series.

My question is: How can we justify that $\int_{-1}^1{\frac{dx}{x}}$ is not integrable because of the vertical asymptote if the infinities we're dealing with are the 'same infinities' although with opposite signs?

• It's not the vertical asymptote as such. But $\frac{1}{x}$ has a non-integrable singularity at $0$. Hence $\int_{-1}^1 \frac{dx}{x}$ doesn't exist. However, $\operatorname{v.p.} \int_{-1}^1 \frac{dx}{x}$, the pricipal value integral, exists and is $0$. Commented Nov 3, 2015 at 14:40
• This depends on a convention you take. This function is not Riemann-integrable in standard meaning of this, because it's unbounded and not defined at $0$. But, as Daniel mentions, it makes sense to speak of the principal value of this integral which is equal to $0$. Commented Nov 3, 2015 at 14:42

What you say to this depends a bit on your definition. One way to deal with integrals where you integrate over a point not in the domain, is to split the integral up into two integrals. This is the definition/approach taken in for example Stewart's calculus book. So $$\int_{-1}^1 \frac{1}{x}\;dx = \int_{-1}^0 \frac{1}{x}\; dx + \int_0^{1}\frac{1}{x}\; dx.$$ We say that the integral exists if both of these exits. But $$\int_0^1\frac{1}{x}\;dx = \lim_{t\to 0^+} \int_t^1\frac{1}{x}\;dx$$ does not. So $$\int_{-1}^1\frac{1}{x}\; dx$$ does not exist. And this is the common way to consider the integral.

There is a way to assign a value to the integral. For more about that, see this Wikipedia article: https://en.wikipedia.org/wiki/Cauchy_principal_value.

I don't know about you, but when I was first introduced to the antiderivative of $1/x$, I was pretty confused. It made sense that the answer was $\ln(x)+C$, but changing this to $\ln|x|+C$ seems to make no sense. It's justified as being just the addition of a constant, $i\pi$, and indeed you can verify the derivative is the same (still $1/x$), but it seems instead that you're only adding $i\pi$ to the function for $x<0$, and nothing when $x>0$. In other words, you're not actually adding a constant at all, but rather the function $i\pi\left(1-H(x)\right)$ (where $H(x)$ is a unit step at 0).

Indeed, this kind of thing wouldn't be OK if we were dealing with ordinary continuous functions -- if you added a constant to one point of the function, that would affect the values of every other point in the function (one way of demonstrating this is the Taylor series). But since $\ln(x)$ has a singularity at $x=0$, the derivative is not defined at that point anyway, so one side of the function can be independent of the other.

Why is this important? Well, consider evaluating the integral

$$\int_{-1}^1\frac{dx}x$$

Now, the presence of the singularity would not directly make it a bad idea to use the fundamental theorem of calculus to evaluate this integral (look here to understand where it would directly be a bad idea) -- or at least it wouldn't necessarily be, if you choose $\ln|x|$ as the antiderivative, since then the antiderivative would come back from infinity in the same direction, so the same overall path is transversed.

If you don't understand this argument, go look at the link above!

But because there are multiple consistent antiderivatives, we still can't apply the fundamental theorem of calculus. For instance,

$$\begin{array}{l}\ln \left| 1 \right| - \ln \left| { - 1} \right| = 0\\\ln \left( 1 \right) - \ln \left( { - 1} \right) = - i\pi \end{array}$$

So instead you define a principle value, skirting around the singularity by taking

$$\int_{-1}^{-\epsilon}\frac{dx}x+\int_{\epsilon}^{1}\frac{dx}x=\ln(\epsilon)-\ln(\epsilon)=0$$

This is okay, because regardless of whether you use $\ln(x)$ or $\ln|x|$ as the antiderivative, the arbitrary constants cancel out on each side of the singularity. I.e. if you have a $+i\pi$ term to the left of the singularity, this exists for both $-1$ and $-\epsilon$, and thus cancels out as in any ordinary integral.

In this sense, $\ln\left|x\right|$ can be considered the "principal antiderivative" of $1/x$. But there's nothing particularly special about this value. One may take the limit a little differently, so you don't approach 0 at the same rate from both sides, for instance --

$$\int_{ - 1}^{ -\epsilon } {\frac{{dx}}{x}} + \int_{n\epsilon}^1 {\frac{{dx}}{x}} = \ln \left( \epsilon \right) - \ln \left( {n\epsilon} \right) = \ln \left( {\frac{1}{n}} \right)$$

This is equivalent to cancelling out your areas in a different "order" on the graph, which allows you to leave some remainder area.

The integrand is not defined at $x=0$, so basically this expression is not meaningful yet. Once we ask a precise mathematical question, we can answer it. So what might we mean by the expression $\int_{-1}^1 \frac{1}{x}\; dx$ in the first place? We could ask what is

$\lim_{\delta \to 0} \int_{-1}^{-\delta} \frac{1}{x}\; dx + \int_{\delta}^1 \frac{1}{x}\; dx$?

The answer is zero for essentially the reasons you have outlined.

But we could also ask if the limit

$\lim_{(\alpha,\beta) \to (0,0)} \int_{-1}^{-\alpha} \frac{1}{x}\; dx + \int_{\beta}^1 \frac{1}{x}\; dx$

exists or similar such questions. Now it looks bad. We could, for example, take $(\alpha,\beta) = (\delta,\delta^2)$ and let $\delta \to 0$. Now the positive part of the expression contributes $2\log \delta$, but the negative part only $-\log \delta$.

First, the function does not fit these criteria at $x=0$, so the tricks for odd functions do not necessarily apply. Second, the critical flaw here is when you say "go at the same rates at all times." Presupposed in this statement is that, for the Riemann sum, you have partitioned the intervals in the exact same way. However, for the integral to exist, you need the limit to be the same regardless of how you partition. And if you partition the negative side differently than the positive side, you will get a different answer.

• Don't we assume the same partition since they share the differential dx? Commented Nov 3, 2015 at 14:45
• No, there is no reason to assume that.
– Paul
Commented Nov 3, 2015 at 14:50
• IIRC we don't have to have any two of the Riemann rectangles from any partition to have the same width. Commented Nov 3, 2015 at 14:59
• @Striker The differential is just notation. It plays no role on the definition of the integral whatsoever. Commented Oct 19, 2021 at 12:08

I don't think there's any answer that will completely satisfy you.

The question is reminiscent of (but more advanced than): "why can't we say $1/0 = \infty$?", and the answer is the same:

• it would make some other facts false that we have that are more important to us (e.g. for division by zero, that we can solve $ax = b$ uniquely for $x$ when $b \neq 0$; for this improper integral, that $\int_a^b f(x) dx = \int_a^c f(x) dx + \int_c^b f(x) dx$.)

• the reasons those facts are more important to us are is because we use them more often, but if we really wanted, we could introduce the convention that you prefer, at the cost that most of our facts would have a lot of caveats in them.

• in fact, some mathematicians DO use the "unconventional convention" in certain contexts where it is more convenient (for instance, automorphisms of the Riemann sphere are easiest to work with if we assert $1/0 = \infty$; the Cauchy principal value of an integral is calculated exactly as you describe.)

The reason I doubt you'll find this satisfying is that only after you work with "bad" integrals on a regular basis do you really worry about when the rules for manipulating integral symbols apply. In the real-world, these don't come up so much (at least for division by zero, a good calculus student should come to appreciate why we leave it undefined. For integrals, I imagine that anyone who doesn't have an undergrad education in pure math is going to be unsatisfied that we don't just define the value to be the Cauchy principal value in this case, even though I believe our conventions are correct.)

• So, if I'm understanding you correctly, the reason why this is not evaluable is that we don't want to add caveats to the assertion that functions are not integrable over parts not included in their domain. We would rather keep the definitions as is, and introduce other ideas (like the Cauchy principal value) for other contexts. If it's true, I'm perfectly fine with that. I will say, however, that it can be quite confusing to people like me, who are first learning concepts and are denied intuition by the lack of caveats. Commented Nov 3, 2015 at 15:17
• I would say the "intuitive" picture is that an integral is "painting the area from left to right." If at any point you need infinite amounts of paint, you give up. It's true that we cancel paint above the axis with paint below the axis, but we're only allowed to do that after we painted. What I suspect is that your intuition (this is why I don't like the word intuition) is that the definition of integration is the fundamental theorem of calculus, and if that were so we'd want $\int_{-1}^1 \frac{dx}{x}$ to be $0$. Commented Nov 3, 2015 at 15:23
• (What I mean by this: a lot of students, when they first encounter integration, think $\int_a^b f(x) dx$ means $F(b) - F(a)$, where $F$ is an antiderivative of $f$; they then think it's a theorem that this calculates areas for them. Mathematically, it's more sensible to define the integral as the area and then prove the FTC. From this perspective, infinite areas are highly problematic, even if they cancel; it's analogous to trying to make sense out of $\infty - \infty = 0$.) Commented Nov 3, 2015 at 15:25
• @Striker The caveats you want would defy your intuition, or anyone else's, for that matter, far more than this particular integral not existing does. But also, your intuition is not being denied. Mathematics are inherently counterintuitive, and this is something that everyone needs to learn to accept in the long run. Everyone has at experienced the feeling that mathematics were not intuitive to them, but we end up needing to overcome it. It is what it is. Commented Oct 19, 2021 at 12:28

By definition, for a function to be integrable over an interval, the function must be defined over that interval. Thus, $\frac{1}{x}$ is not integrable over $[-1;1]$ since it is not defined over that interval.

Even if we talk of improper integrals, we would get $\infty-\infty$ which is an indeterminate form, making the usual way of calculating improper integrals useless here.

However, your remark is not redundant and such a concept has already been done. That concept is the Cauchy Principal Value which assigns values to such integrals as yours.

$PV \int_{-1}^{1}\frac{dx}{x}=\lim_{a\to0+}\int_{-1}^{-a} \frac{dx}{x}+\int_{a}^1 \frac{dx}{x}$

This is shown to be $0$ through easy calculation which captures the intuitive concept behind your remarks.

Consider a function $$f : [-1,1] \rightarrow \mathbb R$$. The Riemann integral of $$f$$, denoted by $$\int_{-1}^1 f dx$$ is defined as the limit of the Riemann sums of $$f$$, if said limit exists. However, $$f : \mathbb R\setminus\{0\} \rightarrow \mathbb R$$ has a non-removable singularity at $$0$$, and to be more precise, an unbounded singularity, which intuitively, means that $$f$$ "blows up" at $$0$$. Thus, even if we let $$f(0) = a$$ for some real $$a$$, the Riemann sums would not converge, due to this singularity. Since the Riemann sums do not converge, $$\int_{-1}^1 f dx$$ simply does not exist in this case.

I understand the general concept of there being 'different' infinities because functions have different rates of change. However, I find this one especially baffling because this function fits the criteria... I know that all odd functions fit this criteria, but I'm writing this explicitly because this means that they shouldn't be different infinities at all; they start at opposite points, and go at the same rates at all times.

This is inaccurate. I would refrain from trying to use the concept of infinity to intuitively understand this. Also, "rate" in this context does not refer to the derivative. As I just explained, $$\int_{-1}^1 f dx$$ does not exist. So instead, it makes sense to talk about $$\int_{-1}^{-\delta}f dx + \int_{\epsilon}^{1} f dx$$, and let $$\delta \rightarrow 0^+, \epsilon \rightarrow 0^+$$. The fact that $$\delta$$ and $$\epsilon$$ are independent of each other is what people actually mean when they say "the rates are different". As you will see, this limit with $$\delta \rightarrow 0^+, \epsilon \rightarrow 0^+$$ does not exist. Hence, the integral in question does not exist, even as an improper integral.

The Cauchy principal value is what you get when you let $$\delta = -\epsilon$$. Intuition would suggest this due to the symmetry between $$-1$$ and $$1$$, but this is actually only the average. What I mean is that, in a very precise sense, if you look at the average value of $$\int_{-1}^{-\delta}f dx + \int_{\epsilon}^{1} f dx$$ near the singularity, and you then evaluate the limit of the average, you get 0. That is actually the essence of what the Cauchy principal value is: an operator that takes a singularity and replaces it by the average of the function near that singularity, in a precisely well-defined way.

If this integral were expressed as a series representing..., there would always be a pair of points that cancel out, despite both integrals approaching infinity as they get closer to 0. This makes it even more baffling, because I remember the sum of all whole numbers being -1/12 - the derivation of which required the canceling of many pairs of numbers representing the series.

The "sum" of "whole" numbers is not $$-1/12$$. This is painfully inaccurate, and the Numberphile video on the subject was somewhat misleading, because they did not sufficiently emphasize the technical details behind what they were claiming. For starters, you cannot have a "sum" of infinitely many objects. A "sum" is inherently an operation on n-tuples. You can, however, used sums to define the discrete integral of a sequence, and evaluate this discrete integral, then find what the discrete integral converges to, and in the context of calculus, this is often called an "infinite sum", even though this is just abuse of language. Also, the Ramanujan summation that gives $$-1/12$$ for an answer when the sequence of positive integers is given is not actually the limit of the discrete integral of this sequence. This is a whole rabbit hole of its own that deserves to be discussed in another post, but the point is, no mathematician is "cancelling out" any "infinities" to obtain any valid results. At no point are we ever even dealing with infinite quantities. This is entirely a matter of limits, and understanding how the limits work intuitively and in context.

Anyway, to summarize: the Riemann integral of $$f$$ does not exist, because $$f$$ "blows up" at 0, and the improper integral also does not exist, because $$\lim_{\delta\to 0^+, \epsilon\to 0^+} \ln(\frac{\epsilon}{\delta}$$ does not exist. There are no "infinities" to subtract here. That is what your intuition is failing to grasp.