# Riemann-Stieltjes Integrals with the Greatest Integer Function as an Integrator

Recall from the Riemann-Stieltjes Integrals with Multiple-Discontinuity Step Functions as Integrators page that if $f$ is a function on the interval $[a, b]$ and $\alpha$ is a step function on $[a, b]$ with jump discontinuities at $x_1, x_2, ..., x_n$ in $[a, b]$, then at each $x_k$ for $k = 1, 2, ..., n$ if $f$ and $\alpha$ are both not discontinuous from the left at $x_k$ and are not both discontinuous at the right at $x_k$ then $f$ is Riemann-Stieltjes integrable with respect to $\alpha$ on $[a, b]$ and:

(1)Where $\displaystyle{\alpha (x_k^+) = \lim_{x \to x_k^+} \alpha(x)}$ and $\displaystyle{\alpha (x_k^-) = \lim_{x \to x_k^-} \alpha (x)}$ for each $k \in \{1, 2, ..., n \}$ and if $x_1 = a$ we define $\alpha (x_1^-) = \alpha(a)$ and if $x_n = b$ we define $\alpha (x_n^+) = \alpha(b)$.

Also recall from The Greatest Integer Function page that the greatest integer function output of a real number $x \in \mathbb{R}$ is denoted $[x]$ and is the greatest integer less than or equal to $x$, i.e., $[x] \leq x < [x] + 1$.

We will now look at a rather nice theorem which tells us that every finite sum can be expressed as a Riemann-Stieltjes integral.

Theorem 1: Let $(a_k)_{k=1}^{n}$ be a finite sequence of numbers. Then the sum $\sum_{k=1}^{n} a_k$ can be expressed as a Riemann-Stieltjes integral by defining $f(x) = \left\{\begin{matrix} 0 & \mathrm{if} \: x = 0\\ a_1 & \mathrm{if} \: 0 < x \leq 1 \\ a_2 & \mathrm{if} \: 1 < x \leq 2 \\ \vdots \\ a_n & \mathrm{if} \: n-1 < x \leq n \end{matrix}\right.$. Then $\int_0^n f(x) \: d [x] = \sum_{k=1}^{n} a_k$. |

**Proof:**We note that $f$ is continuous on the left at the discontinuties (integers) throughout $[0, n]$ and $\alpha$ is continuous on the right at the discontinuties throughout $[0, n]$. Therefore $f$ and $\alpha$ are not both discontinuous on the left at these discontinuities and not both discontinuous on the right at these discontinuities. Therefore $f$ is Riemann-Stieltjes integrable with respect to $\alpha$ on $[0, n]$ and:

## Example 1

**Consider the finite sequence $(a_k)_{k=1}^{5} = (1, 2, 3, 4, 5)$. Express the sum of this sequence as a Riemann-Stieltjes integral.**

This sequence has $n = 5$ terms and by Theorem 1 we have that:

(3)Where the function $f$ is given by:

(4)