Therefore, the choice of routes minimizing total energy is an equilibrium. The above proof outlines a procedure known as best response dynamics, which finds an equilibrium for a linear traffic graph and terminates in a finite number of steps. The algorithm is termed "best response" because at each step of the algorithm, if the graph is not at equilibrium then some driver has a best response to the strategies of all other drivers and switches to that response. Pseudocode for Best Response Dynamics:  At each step, if some particular driver could do better by taking an alternate path (a "best response"), doing so strictly decreases the energy of the graph. If no driver has a best response, the graph is at equilibrium. Since the energy of the graph strictly decreases with each step, the best response dynamics algorithm must eventually halt. If the travel time functions are linear, that is formula_32 for some formula_33, then at worst, traffic in the energy-minimizing equilibrium is twice as bad as socially optimal.