The problem solved by the Stepping Stone algorithm is as follows:
Let’s take an example to show how the algorithm works. Let’s take four origins and five applicants with the costs and quantity following the table:
c_{ij}

D_{1}

D_{2}

D_{3}

D_{4}

D_{5}

offer

O_{1}

7

12

1

5

6

12

O_{2}

15

3

12

6

14

11

O_{3}

8

16

10

12

7

14

O_{4}

18

8

17

11

16

8

demande

10

11

15

5

4

It is possible to perform the algorithm using two tables (one for costs, one for flows). It is also possible to display the two values in the same box since only the flow will vary.
Step 1: To obtain a basic solution
By Northwest corner
2. Adjust the supply and demand numbers in the respective rows and columns allocation
3. If the supply for the first row is exhausted, then move down to the first cell in the next row
4. If the demand for the first cell is satisfied then move horizontally to the next cell
5. If for any cell supply equals demand then the next allocation can be made in cell either in the next row or column
6. Continue the procedure until the total available quantity is fully allocated to the cells as required.
f_{ij}

D_{1}

D_{2}

D_{3}

D_{4}

D_{5}

offer

O_{1}

10

2

–

–

–

12

O_{2}

–

9

2

–

–

11

O_{3}

–

–  13 
1

–

14

O_{4}

–

–

–

4

4

8

demande

10

11

15

5

4

The total cost of the basic solution is: 10*7+2*12+9*3+2*12+13*10+12+4*11+4*16 = 395.
By minimum’s method
2. If the minimum cost is not unique, then you are at liberty to choose any cell.
3. Choose the value of the corresponding x_{ij} as much as possible subject to the capacity and requirement constraints.
4. Repeat steps 13 until all restrictions are satisfied.
By Vogel’s approximation (or BalasHammer)
1. Determine a penalty cost for each row (column) by subtracting the lowest unit cell cost in the row (column) from the next lowest unit cell cost in the same row (column).
3.
 If there is exactly one row or column left with a supply or demand of zero, stop.
 If there is one row (column) left with a positive supply (demand), determine the basic variables in the row (column) using the Minimum Cell Cost Method. Stop.
 If all of the rows and columns that were not crossed out have zero supply and demand (remaining), determine the basic zero variables using the Minimum Cell Cost Method. Stop.
In any other case, continue with Step 1.
The first iteration of the method gives: D_{O1} = 4, D_{O2} = 3, D_{O3} = 1, D_{O4} = 3, D_{D1} = 1, D_{D2} = 5, D_{D3} = 9, D_{D4} = 1, D_{D5} = 2. The column D_{3} have the biggest cost difference, its lowest cost is 1 so we saturate this element O_{1} D_{3} with the flow min(12, 15). The row O_{1} is saturated.
f_{ij}

D_{1}

D_{2}

D_{3}

D_{4}

D_{5}

offer

O_{1}

X

X

12

X

X

12

O_{2}

–

–

–

–

–

11

O_{3}

–

–  – 
–

–

14

O_{4}

–

–

–

–

–

8

demande

10

11

15

5

4

For the new cost difference calculation, we will no longer consider the values of raw O_{1}. We get after 5 iterations to the following configuration:
f_{ij}

D_{1}

D_{2}

D_{3}

D_{4}

D_{5}

offer

O_{1}

–

–

12

–

–

12

O_{2}

–

11

–

–

–

11

O_{3}

10  –  – 
–

4

14

O_{4}

–

–

3

5

–

8

demande

10

11

15

5

4

Step 2: Calculating potentials MODI
Once you have a basic solution, the idea is to modify the solution in order to improve the objective function. That is to say that the flow must be modified. For that, we will choose a flow lowering at most the total cost of transport. The first step in determining this flow is to calculate the potentials. The potentials are calculated ONLY on the boxes having a nonzero flow!
We can then calculate other potentials. The potentials are calculated gradually. In our case, we calculated the potential of raw 1 from c_{12}, so it is possible to calculate the potential of column 1 or column 2.
We can solve for column 1, p_{D1} = c_{11} + P_{O1} = 7. For raw 2, p_{D2} = c_{12} + P_{O1} = 12. Dnd so on: p_{O2} = p_{D2} – c_{22} = 12 3 = 9; p_{D3} = 21; p_{03} = 11; P_{D4} = 23: P_{O4} = 12; P_{D5} = 28.
Step 3: Calculation of unit cost variation
v_{ij}

D_{1}

D_{2}

D_{3}

D_{4}

D_{5}

p_{O}

O_{1}

–

–

20

18

19

0

O_{2}

17

– 
–

8

5

9

O_{3}

12  15  – 
–

10

11

O_{4}

23

8

8

–

–

12

p_{D}

7

12

21

23

28

Step 4: Calculation of the maximum amount of flow
For example, the element 0_{1}D_{3} takes the following circuit f_{13} > f_{12} > f_{22} > f_{23} > f_{13}with a minimum flow of 2.
f_{ij}

D_{1}

D_{2}

D_{3}

D_{4}

D_{5}

p_{O}

O_{1}

–

–

2 
1

1

0

O_{2}

–  – 
–

1

1

9

O_{3}

–  –  – 
–

1

11

O_{4}

–

–

–

–

–

12

p_{D}

7

12

21

23

28

By multiplying f_{ij}*v_{ij}, we know the variation of the total cost by the modification by the flow f_{ij}. We choose the element with the largest f_{ij}*v_{ij}, here it is O_{1}D_{3}
Step 5: To update the table
The computation of update of the waves is done by the rule of the « + – » without counting the return to the box of origin. Thus in the circuit: f_{13} += 2, f_{12} =2, f_{22} += 2 and f_{23} = 2. The table is as follows:
f_{ij}

D_{1}

D_{2}

D_{3}

D_{4}

D_{5}

offer

O_{1}

10

22 = –

0+2 = 2 
–

–

12

O_{2}

–  9+2 = 11 
22 = –

–

–

11

O_{3}

–  –  13 
1

–

14

O_{4}

–

–

–

4  4 
8

demande

10

11

15

5

4

The total cost of the basic solution is: 10 * 7 + 2 * 12 + 9 * 3 + 2 * 12 + 13 * 10 + 12 + 4 * 11 + 4 * 16 = 395. The cost of this solution is: 10 * 7 + 11 * 3 + 2 * 1 + 13 * 10 + 12 + 4 * 11 + 4 * 16 = 355. This is the basic solution minus f_{13}*v_{13} = 2*20 = 40.
In our example, we have in the end the following table:
f_{ij}

D_{1}

D_{2}

D_{3}

D_{4}

D_{5}

offer

O_{1}

–

–

12 
–

–

12

O_{2}

–  11 
–

–

–

11

O_{3}

10  –  – 
–

4

14

O_{4}

–

–

3

5  – 
8

demande

10

11

15

5

4

With a total cost of: 10*8+11*3+12*1+3*17+5*11+4*7 = 259.
Aside
We talk about flow because the problem is solved as a problem of min cost flow (maximum flow at minimum cost) in a complete bipartite graph – a set of sources connected to a set of sinks (hence the rule of « + – » since we go once in the direction of the flow then in the wrong direction in the chosen circuit).