# Show that there exists a $c : f(c) = g(c)$

I'll try to present a solution for this problem, and I hope I can receive feedback on what went wrong, if something went wrong of course.

Let $$f, g : [a, b] \to \Bbb R$$ be continuous functions and $$\int_{a}^{b} f(x) dx = \int_{a}^{b} g(x) dx$$. Show that there exists $$c \in [a, b]$$ such that $$f(c) = g(c)$$.

Solution

Let's define $$h(x) = \int_{a}^{x}f(x)dx-\int_{a}^{x}g(x)dx$$

$$h(x)$$ is continous, since $$f(x)$$ and $$g(x)$$ is continous. I hope this argument is correct.

We see $$h(a) = h(b) = 0$$.

Applying Rolle's Theorem, we get that $$\exists \xi \in (a,b) : h'(\xi) = 0$$

In other terms,

$$f(\xi) = g(\xi)$$

$$\square$$

Thanks!

• It looks fine to me. Commented Oct 16, 2021 at 16:22
• Apart from what Aryaman Maithani told you, I would change $h(x) = \int_{a}^{x}f(x)dx-\int_{a}^{x}g(x)dx$ to $h(x) = \int_{a}^{x}f(t)dt-\int_{a}^{x}g(t)dt$. The first way to write it is not wrong, but it may be considered as poor writing style. Read a discussion about that here. Commented Oct 16, 2021 at 16:31
• @Bergson Thank you. That's how we usually write it, at least in class :) Commented Oct 16, 2021 at 17:13

Instead of claiming $$h$$ to be continuous, you need that $$h$$ is differentiable, in order to apply Rolle's Theorem. The differentiability follows since $$f$$ and $$g$$ are continuous, so then the Fundamental Theorem of Calculus tells you that $$h$$ is differentiable.
Here's another method: Assume for the sake of contradiction that the statement is not true. Define $$h := f - g$$. By assumption, $$h$$ is never zero. Thus, $$h$$ is of one sign. WLOG, $$h > 0$$. But this means that $$\int_a^b h > 0$$, contradicting our assumption.
(The work here is gone into showing that $$h > 0 \implies \int_a^b h > 0$$.)
• @Tanamas: You're most welcome! :) To answer your question, let us forget the hypothesis of this question and look at something more general: Let $f:[a, b]\to\Bbb R$ be a function which is Riemann integrable on interval of the form $[a, x]$ for all $x \in [a, b]$. Then, we can define the function $F : [a, b] \to \Bbb R$ by $$F(x) := \int_a^x f(t)dt.$$ Then, $F$ is (1) always continuous at every point. Moreover, (2) if $f$ is continuous at $c \in [a, b]$, then $F$ is differentiable at $c$. Thus, (3) if $f$ is continuous (everywhere), then $F$ is differentiable (everywhere). Commented Oct 16, 2021 at 17:23