If we know the following: $$\int_a^b f(x) \,dx= k$$ and: $$\int_a^b g(x) \,dx= k$$ Can we deduce that $f(x) = g(x)$? If not, could someone find me an example where the above is the case and $f(x)$ does not equal $g(x)$? Thanks in advance.
-
2$a=-1,b=1,f=x,g=x^3.$ – coffeemath Jul 13 '23 at 10:22
-
2I like $\int_0^1 x,dx = \int_0^1(1-x),dx$ by a change of variable. – GEdgar Jul 13 '23 at 11:19
-
2The current answers are fixing a and b and then showing a counterexample. There are examples where the integral of a function over any two limits can be the same and the function still not determined (e.g. with discontinuities), but I'm not sure these fit into the scope of a calculus 1 question as this appears to be. I think "for the purposes of calculus 1" the statement may be true, by the fundamental theorem of calculus. – fish Jul 13 '23 at 18:14
-
The questions have answered me well enough to this stage. I am not worried about further calculus yet lol. – Nav Bhatthal Jul 13 '23 at 18:32
-
A way to intuit this is that the mean of a continuous function over an interval is calculated as the definite integral over the interval divided by the length of that interval. So saying two functions have the same integral over an interval is identical to saying they share the same mean over that interval. And the mean of a continuous function doesn’t uniquely identify it. So just because two functions have the same definite integral over the same interval doesn’t mean they’re the same function. – bob Jul 13 '23 at 18:53
-
Matthew Leingang makes a great point in their answer—you need to edit your question to specify whether you mean the case where there exists an interval over which the integrals are equal, or whether you mean the case where over all possible intervals the integrals are equal. These two cases are two very different questions with different answers. – bob Jul 13 '23 at 19:04
-
2However, if they are equal for any choice of $a$ and $b$, then I believe it follows that $f=g$. Edit: just realized this was addressed in Mathew Leingang’s answer. – David Raveh Jul 14 '23 at 00:00
-
@bob What does the mean have to do with anything in the first place? – Accelerator Jul 14 '23 at 02:16
-
@Accelerator I’m not sure what your objection is? Could you explain it a bit more? FWIW I’m not making a proof or rigorous mathematical argument by bringing the mean into the discussion, I’m showing that the statement about integrals, which isn’t necessarily intuitive, becomes a lot more intuitive if you convert it to an equivalent statement about means of functions. That was my whole purpose. I hope this helps. But curious what your objection is? – bob Jul 14 '23 at 02:58
-
@bob I don't see what the mean has to do with anything. You're basically saying $\int_{a}^{b}f\left(x\right)dx=\int_{a}^{b}g\left(x\right)dx$ implies that $\frac{1}{b-a}\int_{a}^{b}f\left(x\right)dx=\frac{1}{b-a}\int_{a}^{b}g\left(x\right)dx$, but how does that show if $f(x)$ and $g(x)$ are equal to each other or not? – Accelerator Jul 14 '23 at 03:10
-
Correct. I’m saying that it’s easier for a non-mathematician to see that equality of means doesn’t imply equality of functions than it is for them to see that equality of definite integrals doesn’t imply equality of functions. And switching mentally from definite integrals to means is mathematically valid because of the argument I made. That’s all. I’m trying help OP develop an intuition for why the result isn’t surprising. – bob Jul 14 '23 at 13:09
-
1@Accelerator Considering "integration as area-under-the-curve" kipf's answer basically says that we cannot conclude two mountain ranges are the exact same shape simply because their average elevation is the same over one particular interval. Considering "integration as area-under-the-curve" MatthewLeingang's answer says, that if we examine two mountain ranges, and find that the average elevation is the same for any and every interval we could possibly imagine (no matter how wide or small, where we start or stop, etc.) then the two mountain ranges must be the same shape. – DotCounter Jul 14 '23 at 15:01
-
1@bob The above mountain range analogy should hopefully line up with the intuitions you were trying to build. – DotCounter Jul 14 '23 at 15:03
-
@AmateurDotCounter Absolutely, thanks for the concrete example. I’ll add it to my answer! – bob Jul 14 '23 at 15:09
4 Answers
$$\int_0^{\pi} \cos x \, \mathrm dx = 0 \quad \text{and} \quad \int_0^\pi 0 \, \mathrm dx=0,$$ (so $a=0$, $b=\pi$, $k=0$, $f(x) = \cos x$ and $g(x) =0$), but $\cos x \ne 0$ so $$f(x) \ne g(x).$$ There are many, many other examples. There is no reason that because the area under the graph of two functions is the same between two points, that they should be the same function.
Edit: I assume here that $a$ and $b$ are fixed. Please see the other answers to this question if they aren't!
- 2,357
-
2Thanks for your answer, atleast you did not just downvote and leave. $+1$ – Nav Bhatthal Jul 13 '23 at 09:57
The problem doesn't say whether $a$ and $b$ are existentially or universally quantified. If we assume the latter, and something more about $f$ and $g$, we can assert:
Claim: If $f$ and $g$ are continuous functions and $$\int_a^b f(x)\,dx = \int_a^b g(x)\,dx$$ for all real numbers $a < b$, then $f(x) = g(x)$ for all $x$.
To prove this, it is enough to show: If $h$ is continuous and $\int_a^b h(x)\,dx = 0$ for all $a < b$, then $h(x) = 0$ for all $x$.
To prove this, it is enough to show the contrapositive: If $f$ is continuous, and there exists $x_0$ such that $f(x_0) \neq 0$, then there exist real numbers $a < b $ such that $\int_a^b f(x)\,dx \neq 0$.
And finally, it is enough to show that: If $f$ is continuous, and there exists $x_0$ such that $f(x_0) > 0$, then there exist real numbers $a< b$ such that $\int_a^b f(x)\,dx > 0$.
The gist of the argument is that: if $f$ is continuous, and positive at a point, it is positive on an open interval around that point. The integral of $f$ over that interval must be positive.
Here is the formal proof: Let $\epsilon = f(x_0)/2$. There exists $\delta$ such that $|f(x) - f(x_0)| < \epsilon$ when $|x-x_0| < \delta$. Let $a =x_0 - \delta/2$ and $b = x_0 + \delta/2$. Then $f(x) > f(x_0)/2$ for all $x$ in $[a,b]$. So $$\int_a^b f(x) > (f(x_0)/2) \cdot (b-a) = \frac{f(x_0)}{2}\cdot \delta$$
Notice how the proof breaks down without the continuity assumption. The function $f$ which is $1$ at $x=0$ and $0$ elsewhere has $f(0) > 0$, but for all $a < b$, $\int_a^b f(x)\,dx = 0$.
- 26,112
-
6Worth emphasising the "if f and g are continuous", because that's not specified in the question, but is critical to the proof :) – psmears Jul 13 '23 at 21:27
-
@psmears: Right you are. I've emboldened the word and added a paragraph emphasizing the importance of this assumption. I thought bringing in this example would be useful because it wasn't entirely clear from the OP what assumptions on $f$ were in play. – Matthew Leingang Jul 14 '23 at 15:16
-
Hm. Then why not just fix $a$ and, using differentiability of indefinite integrals (in this case for continuous integrands), differentiate the given relation in $b$? – Vandermonde Jul 14 '23 at 21:03
-
@Vandermonde: personally, I am fond of how this fact is equivalent to something pretty intuitive about continuous functions: if a function is positive at a point, it's positive near that point. But your way is nice too. – Matthew Leingang Jul 17 '23 at 15:31
Counterexample:
\begin{align} 1=\int_{0}^{1}dx=\int_{0}^{1}(2x)dx \end{align}
and
\begin{align} f(x)=1\ne g(x)=2x \end{align}
- 152
No and here’s a way to intuit why (note: this is not a proof or mathematically rigorous argument, just an aid in understanding intuitively why the answer is what it is):
The mean of a continuous function over an interval is calculated as the definite integral over the interval divided by the length of that interval. So saying two functions have the same integral over a non-zero length interval is identical to saying they share the same mean over that interval. And the mean of a continuous function doesn’t uniquely identify it. For example consider how many different continuous functions you could construct that have mean zero over some non-zero length interval. For a real-life analogy courtesy of @AmateurDotCounter, imagine you have two mountain ranges that have the same average (mean) height. Does this mean the two mountain ranges have exactly the same shape?
So just because two functions have the same definite integral over the same interval doesn’t mean they’re the same function. It’s also the intuition behind the counter-examples that have been provided in other answers: each function in such a pair share the same mean and thus the same integral over some non-zero length interval.
Note: in my answer I assume that OP means that there exists an interval [a,b] such that the integrals of the two functions over that interval are equal.
- 202