First we define the notion of **piecewise continuity**:

Definition

We say that a functionfis piecewise continuous on an interval[ if there is a finite set of pointsa,b]such that for every segment a=x_{0}<x_{1}< . . . <x_{N}=b[ wherex_{k−1},x_{k}],the function k= 1,...,N,fhas a limit atfrom the right, limit at x_{k−1}from the left, and is continuous on x_{k}( x_{k−1},x_{k}).

Here is a typical example of a piecewise continuous function:

We have the following statement:

Theorem

If a function is piecewise continuous on a closed interval, then it is Riemann integrable there.

Piecewise continuous functions are useful because they are often used in applications.

Actually, even infinitely many - but countably many - points of discontinuity do not pose a problem. The precise statement concerning how many points of discontinuity are allowed is this:

Theorem

A function defined on a closed interval is Riemann integrable there if and only if the set of its points of discontinuity is of measure zero.

The "measure" in this statement is the Lebesgue measure - which clearly shows
that this is *way* beyond the scope of this Math Tutor.