You are on page 1of 8

Notes on Mathematical Notation

1. Summation Notation ..........................................................................................1


2. Product Notation................................................................................................2
3. LP Example: The Product Mix Problem.............................................................2
4. A Second LP Example: The Transportation Problem ........................................5
5. An Example from Statistics: The Covariance Formula ......................................6

Mathematical notation, like any foreign language, can be completely


incomprehensible when first seen. However, once one gets beyond the initial
disorientation from looking at unfamiliar symbols, the advantages of mathematical
notation become clear. Mathematical notation can be a useful shortcut to writing out
long equations. It can be used to illustrate many examples simultaneously, by replacing
numbers with letters. In short, it is a useful way to communicate mathematical ideas.

1. Summation Notation

To start, we will illustrate two of the most important pieces of mathematical


notation: the use of letters for numbers and the symbol for summation. The average of
the three numbers 2, 4, 5 is (2 + 4 +5)/ 3. The average of the five numbers 1, 3, 6, 7, 10
is (1 + 3 + 6 + 7 + 10)/ 5. The idea of an average is simply to add the numbers and then
divide by the total number of numbers in the sum. Instead of explaining the concept in
words, or giving several illustrations with actual numbers, we can do the following. Let n
be the number of numbers to be averaged, and let x1, x2, , xn represent the numbers.
In the first example, n = 3, x1 = 2, x2 = 4, and x3 = 5. In the second example, n = 5, x1 =
1, x2 = 3, x3 = 6, x4 = 7, and x5 = 10. The same notation can be used to cover many
possible cases. The sum of the numbers is x1 + x2 +  + xn. The average is (x1 + x2 +
 + xn)/n.

The sum can be written in a more compact form as


n

x
i 1
i = x1 + x2 +  + xn.

The Greek capital sigma, , indicates the summation operation, i.e., addition. (Note the
alliterative mnemonic device: sigma = summation.) The subscript i=1 and superscript n
on the capital sigma means that the index of summation, i, should take on all integer
values from 1 to n. Since the term following the summation sign is xi, this means that the

n
numbers x1 to xn are the quantities to be added together. The notation i 1
x i is just a
compact way of writing x1 + x2 +  + xn.

The average (arithmetic mean) of the numbers can be written as

1 n 1

n i 1
x i = (x1 + x2 +  + xn).
n

Decision Models & Optimization Page 1


Notes on Mathematical Notation

The symbol i is called a dummy argument, because it has no effect on the result. Any
other letter could be used in its place, and the meaning would be the same. That is, the
average of x1, , xn could also be written as

1 n 1

n j 1
x j = (x1 + x2 +  + xn).
n

2. Product Notation

Also useful is the symbol for a product, the Greek letter capital pi, . (The
mnemonic here is pi -- product.) To illustrate, suppose the return from an investment is
2% in the first month, 4% in the second month and -1% in the third month. Then the
total return for the three month period is (1.041.020.99) - 1 = 0.050192. In general the
total return for n time periods can be calculated as follows. Let r1, , rn represent the n
individual returns. The total return can be written as
n

 (1 r ) - 1 = (1+ r1)(1+ r2) (1+ rn) - 1 .


i 1
i

Note that the product symbol (as well as the summation symbol) only applies to the
symbols in parentheses that immediately follow the product sign. That is,
n

 (1 r ) - 1  [(1+ r1) - 1][ (1+ r2) - 1]  [(1+ rn) - 1].


i 1
i

3. LP Example: The Product Mix Problem

Mathematical notation can be used to simplify the writing of very large problems.
To illustrate the idea on a small scale, consider the following LP known as a product mix
problem. This example will also illustrate the use of doubly subscripted letters.

Consider the program with these decision variables.


Let x1 = # of barrels of ale to produce, and
x2 = # of barrels of beer to produce.

Our objective function is:

Max 13 x1 + 23 x2
subject to some constraints:

corn) 5 x1 + 15 x2  480
hops) 4 x1 + 4 x2  160
malt) 35 x1 + 20 x2  1190
x1  0, x2  0

Decision Models & Optimization Page 2


Notes on Mathematical Notation
The linear program is called a product mix problem, because the objective is to
find the best mix of products (x1 and x2) in the next planning period. “Best” is defined in
terms of maximizing profit, where the production of each product contributes to the
overall profit. Scarce resources limit the possible production alternatives. In this
example there are 2 decision variables (x1 and x2), 3 constraints, and 2 nonnegativity
restrictions.

The general form of the product-mix problem uses the following quantities.
n is the number of products (n = 2 in our example).
xj represents the production level for product j, for j = 1, , n.
pj is the profit from production of one unit of product j, j = 1, , n. (In the
example, p1 = 13 and p2 = 23.)
m is the number of scarce resources (m = 3 in the example).
aij is the amount of resource i needed to produce one unit of product j,
for i = 1, , m and j = 1, , n. (In our example, a11 = 5, a12 = 15, a21 =
4, a22 = 4, a31 = 35, and a32 = 20.)
bi is the amount of resource i available, i = 1, , m. (In the previous
example, b1 = 480, b2 = 160, b3 = 1190.)

Note: The double subscript ij on the letter a does not indicate the
multiplication of i and j. If there is any chance of confusion, ij can be replaced
with i,j.

The letters used are of four types. First, n and m are used to indicate the size of
the problem. They represent the number of decision variables and constraints. Second,
i and j are indices, i.e. dummy arguments, used to number (or index) the variables and
constraints. Third, the xj's are decision variables, whose optimal values are not known
until the linear program is solved. Finally, the pj's, bi's, and aij's are given data. These
letters are used to represent numbers that are fixed in advance. Even though the data is
represented by letters, they are not variables that change, they are fixed quantities.

Using this notation, the linear program can be written as


n
max p x
j 1
j j

subject to:
n

a
j 1
1j x j  b1
n

a
j 1
2j x j  b2
n

a
j 1
3j x j  b3

x1  0, x2  0

Decision Models & Optimization Page 3


Notes on Mathematical Notation

n
The objective function has been written as j 1
p j x j which is shorthand for p1 x1
+ p2 x2. Using the values of p1 and p2 from the example, the objective is 13 x1 + 23 x2.

n
The first constraint, a x j  b1 is short for a11 x1 + a12 x2  b1. Using the values from
j 1 1 j

the example, the constraint is 5 x1 + 15 x2  480.

The preceding notation can be simplified further by noticing that all of the
constraints have exactly the same form. The most compact form is:
n
max p x
j 1
j j

subject to:
n

a x
j 1
ij j  bi i  1,, m

xj  0 j = 1, ,n

We have saved some space by employing our knowledge of the pattern in the
constraints. Now we will explain what the new notation means.

The notation i = 1, , m means that there are m constraints. To write the first constraint
 aij x j  bi . This gives  j 1a1j x j  b1 . For the
n n
substitute i = 1 in the expression j 1

second and third constraints replace i by 2 and 3, respectively.1 The nonnegativity


restrictions, xj  0 for j = 1, , n, are short for x1  0, x2  0.

There are several advantages to writing the product-mix formulation using this
notation. First, all standard product-mix problems are represented by the same
formulation, and it pays to be familiar with the pattern that product-mix problems take—
so we can immediately recognize them when they arise. Second, it is very compact.
Just a few lines of text are used to represent a problem that could have n = 100
products and m = 1000 scarce resources. A problem this large would be difficult to
convey by directly writing out the entire formulation. Abbreviating the formulation with
ellipses () is not always clear. Third, it can be used to formulate a problem before the
data is gathered. The formulation can be used to see that the necessary data to gather
are the pj's, bi's and aij's.

1
One of the most common mistakes is to incorrectly write the m constraints

n
j 1
a ij x j  bi i  1,, m
as
 
m n
i 1 j 1
a ij x j  bi i  1,, m .
The latter is not correct. First, it only represents one constraint. Second, after expanding the
summations, the left-hand side doesn't depend on i, while the right-hand side does.

Decision Models & Optimization Page 4


Notes on Mathematical Notation
4. A Second LP Example: The Transportation Problem

This linear programming example is called a transportation problem. The


formulation will illustrate the use of double summation. It uses the following notation.

m is the number of factories, indexed i = 1, , m.


n is the number of retail outlets, indexed j = 1, , n.
xij is the number of units to ship from factory i to retail outlet j, for i = 1,
, m and j = 1, , n.

The following example illustrates the formulation for m = 2 factories and n = 3


retail outlets. The objective is to minimize the total cost of shipping goods from the
factories to the retail outlets. The unit cost of shipping varies because of the location of
the factories relative to the retail outlets. The constraints enforce that no more can be
shipped from a factory than is available. Additional constraints ensure that the demand
at each retail location is met.

Our formulation of the transportation problem looks like:

min 4x11 + 3x12 + 2x13 + 5x21 + 4x22 + 6x23


subject to:
supply 1) x11 + x12 + x13  10
supply 2) x21 + x22 + x23  15
demand 1) x11 + x21  8
demand 2) x12 + x22  11
demand 3) x13 + x23  6
xij  0 for all i and j

The general form of the transportation problem uses the following additional quantities.
cij is the unit cost of shipping from factory i to retail outlet j, for i = 1, ,
m and j = 1, , n. (In the previous example, c11 = 4, c12 = 3, c13 = 2,
c21 = 5, c22 = 4, and c23 = 6.)
si is the supply of goods at factory i, i = 1, , m. (In the previous
example, s1 = 10 and s2 = 15.)
dj is the demand requirement at retail outlet j, j = 1, , n. (In the
previous example, d1 = 8, d2 = 11, and d3 = 6.)

Using the previous definitions and summation notation, the previous linear program can
be written more succinctly as follows.
m n
min c x
i 1 j 1
ij ij

subject to:
n
supply i) x
j 1
ij  si i  1,, m

Decision Models & Optimization Page 5


Notes on Mathematical Notation
m
demand j) x
i 1
ij  si j  1,, n

xij  0 for all i and j

The objective function can be understood by expanding one summation at a time.


m n m

  c x  (c x
i 1 j 1
ij ij
i 1
i i1  c i 2 x i 2 c in x in )

 c11x11  c12 x12 c1n x1n


 c 21x 21  c 22 x 22 c 2n x 2n

 c m1x m1  c m2 x m2 c mn x mn

In some instances, you may see the double summation shortened to


m n

 cij xij    cij xij


i, j i 1 j  1

The subscript i, j on the summation sign means for all possible pairs of values of the
indices i and j. This has the same effect as the double summation.

5. An Example from Statistics: The Covariance Formula

Suppose there are m random variables, denoted X1, , Xm. Let a1, ,am be
constants. Then using the definitions of variance and covariance, the following formula
can be shown to hold.
m m m m
Var ( a j X j )   a 2j Var( X j )  2  ai a j C ov( X i , X j ) .
j 1 j 1 i 1 j  i

No doubt the formula looks a tad intimidating at first glance, even for those with
strong stomachs. But with a little persistence, we'll see it's not so bad. To understand
such a formula, it helps to write down a few special cases. For the case of m = 2
random variables, the formula is

Var(a1X1 + a2X2) = a12 Var(X1) + a22 Var(X2) + 2a1a2 Cov(X1,X2).

For m = 3 random variables, the formula is

Var(a1X1 + a2X2 + a3X3) = a12 Var(X1) + a22 Var(X2) + a32 Var(X3) + 2a1a2 Cov(X1,X2) +
2a1a3 Cov(X1,X3) + 2a2a3 Cov(X2,X3).

In this case, the double summation means “add over all pairs of indices i, j for
which j > i.” When i = 1 the indices j between 1 and m that meet the requirement are j =

Decision Models & Optimization Page 6


Notes on Mathematical Notation
2 and j = 3. When i = 2, only j = 3 meets the requirement of j > i. When i = 3, no values
of j meet the requirement. This gives the final three terms in the previous equation.

The variance formula can be expressed in an equivalent way by using the


symmetry property of covariance. This property says that Cov(Xi,Xj) = Cov(Xj, Xi), i.e.,
the covariance of two random variables is the same no matter what order they are listed
in. The variance formula can also be written as
m m m m
Var ( a j X j )   a 2j Var( X j )    ai a j C ov( X i , X j ) .
j 1 j 1 i 1 j 1
j i

The difference is in the way that the final double summation is written. To see that this
formula is equivalent to the one before, let's write it out for m=2.

The formula for m=2 looks like

Var(a1X1 + a2X2) = a12 Var(X1) + a22 Var(X2) + a1a2Cov(X1,X2) + a2 a1Cov(X2,X1)


= a12 Var(X1) + a22 Var(X2) + 2a1a2 Cov(X1,X2).

The last equality follows from the symmetry property of covariance. In a similar manner,
the formula can be shown to be equivalent for any m.

Using the fact that Var(Xj) = Cov(Xj, Xj), the covariance formula can also be
written as
m m m
Var ( a j X j )    ai a j C ov( X i , X j ) .
j 1 i 1 j 1

Again, the equivalence of the different formulas can be seen by expanding the
summations and using the properties of covariance to simplify the result.

Acknowledgment: The note was originally prepared by Professor Mark Broadie, Graduate School of
Business, Columbia University 1995.

Decision Models & Optimization Page 7


Notes on Mathematical Notation
Sample Question to Reinforce Concepts (optional)

Consider the following project selection program. A company can invest in 3


projects over the next 4 years. The cash flows for each project are given in the next
table. In the table, negative numbers indicate cash requirements; positive numbers
indicate cash inflows. Each project can be funded at any level between 0% and 100%.
The company has $3,000 to invest initially. In addition, from previous investments, the
company has cash flows of $500 and $200 in the succeeding two years. The firm can
invest surplus cash at 8% in any year.

Table of Cash Flow Requirements (Projected)


Year Project 1 Project 2 Project 3
1 -3,000 -2,000 -2,000
2 2,500 500 2,000
3 1,500 2,500 -1,000
4 1,000 900 1,100

The linear programming formulation to maximize the firm's final net worth is given
next. The LP formulation uses the following decision variables:

P1 = fraction to invest in project 1


P2 = fraction to invest in project 2
P3 = fraction to invest in project 3
C1 = surplus cash to be invested at 8% in year 1
C2 = surplus cash to be invested at 8% in year 2
C3 = surplus cash to be invested at 8% in year 3

The linear program is:

MAX 1000 P1 + 900 P2 + 1100 P3 + 1.08 C3


Subject To:
2) - 3000 P1 - 2000 P2 - 2000 P3 - C1 = - 3000
3) 2500 P1 + 500 P2 + 2000 P3 + 1.08 C1 - C2 = - 500
4) 1500 P1 + 2500 P2 - 1000 P3 + 1.08 C2 - C3 = - 200
5) P1 1
6) P2 1
7) P3 1

Use the ideas in this note to formulate a general form of the project selection
linear program. In your formulation, assume that there are n possible projects to select
from and each project has cash requirements for the next m years. Define any notation
that is used in your formulation.

Decision Models & Optimization Page 8

You might also like