We saw that in various context an index set has a natural order. If the set is a sequence of time
periods or time points, for instance, then we order the elements within this set according to its
natural sequence and we expect that the index mechanism is applied in this order. We take
an example: Suppose P is a set of time periods or time points. Furthermore, x_{p} is
the production level in period p ∈ P, d_{p} is the demand in period p, and s_{p} is the
stock level at the end of period p. Then we can build a balance equation at each
period:

Formally this can be written as follows (strictly speaking p has two different meaning
here: once for a duration and once for a time point (s_{p}), be careful to model this
correctly):

In this example we make a reference to s_{p-1}, that is, to the time period before p. This would
have no meaning, if the set P were not ordered. However, if we make reference to a different
element then we must be careful to check of whether the element exists. In the expression above
there is an undefined reference: if p = 1 then the expression s_{p-1} = s_{0} is not defined. Hence
strictly speaking, the expression above is only valid for p ∈ P -{1}, we must exclude the first
period and the balance equation of the first period is treated apart, or we must define s_{0}
separately.