Primitives which Differ by Constant

Theorem
Let $F$ be a primitive for a real function $f$ on the closed interval $\left[{a .. b}\right]$.

Let $G$ be a real function defined on $\left[{a .. b}\right]$.

Then $G$ is a primitive for $f$ on $\left[{a .. b}\right]$ iff:
 * $\exists c \in \R: \forall x \in \left[{a .. b}\right]: G \left({x}\right) = F \left({x}\right) + c$

That is, iff $F$ and $G$ differ by a constant on the whole interval.

Necessary Condition
Suppose $G$ is a primitive for $f$.

Then $F - G$ is continuous on $\left[{a .. b}\right]$, differentiable on $\left({a .. b}\right)$, and for any $x \in \left({a .. b}\right)$, we have:

From Zero Derivative means Constant Function it follows that $F - G$ is constant on $\left[{a .. b}\right]$, hence the result.

Sufficient Condition
Now suppose $G \left({x}\right) = F \left({x}\right) + c$.

We compute:

Hence $G$ is also a primitive for $f$.