Definite and Indefinite Integrals
An indefinite integral is the whole family of curves sharing one slope pattern; a definite integral picks two endpoints and returns one number.
Why Does This Exist?
Expected values, marginal probabilities and cumulative metrics are definite integrals. Each returns one number with units. Recovering position from velocity, or a loss from its gradient field, is an indefinite integral. It returns a family of curves that differ by a starting offset. Mix the two and you hand back the wrong shape entirely, a function where a number belongs or a number where a curve belongs.
Integration and area builds the area picture. This page draws the boundary both notations share: with limits you compute, without limits you describe.
The one idea you need first
An antiderivative of is any with . Constants differentiate to zero, so antiderivatives come in families. If works for , so does . That is the whole difference between the two integral kinds.
Think of It Like This
A speedometer with and without a trip meter
An indefinite integral is a speed history with no starting odometer. From speeds alone you rebuild the route shape but not its position, and every rebuild shifts by the unknown start. The is that unknown start.
A definite integral presses the trip meter at mile and mile and reports one number. Same speeds, but endpoints pin the answer to miles. Limits are the trip meter. Without them you own a shape, with them you own a measurement.
How It Actually Works
Indefinite integral: a function family. collects every antiderivative. Example: , because differentiating returns for any constant . No limits, no number, just the family.
Definite integral: one number. evaluates the family at both ends and subtracts, so every cancels: . Limits, one number, units of times units of .
Worked example
Integrate both ways.
Indefinite: . Check by differentiating: . Members include , and . They are parallel curves with identical slopes everywhere, as drawn up top.
Definite from to : . One number, about square units. Any you carried cancels in the subtraction, which is why definite answers never mention it.
Watch Out For
Dropping the plus C in the indefinite case
The symptom is a general solution that misses most solutions. You report as the antiderivative and silently drop every vertical shift, then initial conditions have nothing to grip. In ML this bites when you rebuild potentials or integrate gradient fields: one constant per component, each needing its own condition.
Write every time limits are absent, and trade it for a fitted constant the moment data arrives.
Handing a function where a number belongs
The symptom is a probability or expectation left as an unevaluated antiderivative. The shape is right and the type is wrong, so every consumer breaks. Definite integrals answer how much, indefinite integrals answer what shape.
If the question names endpoints, evaluate at both and subtract. If it asks for the family, keep and stop.
The Quick Version
- Indefinite integrals return curve families: .
- Definite integrals return numbers: .
- The cancels in , so definite answers never carry it.
- No limits means describe the family, limits mean compute the measurement.
- Always verify by differentiating the antiderivative back.
- Shape questions want , how much questions want endpoints evaluated.