Modeling and Solving the HSR Planning Optimization Problem
4.2 IMPLEMENTATION OF THE SIMULATED ANNEALING ALGORITHM
The implementation of the SAA to solve the HSR planning optimization problem is based on previous applications of the algorithm. Particularly, the implementation follows closely Cunha (1999) and Cunha and Sousa (2001), according to the flowchart in Figure 4-10.
As discussed in section 3.2.2 the implementation of the SAA requires the definition of an initial HSR configuration, the definition of the neighborhood of any current configuration and the procedures to generate new candidate HSR configurations and the cooling schedule of the algorithm.
The procedures for the generation of candidate configurations allow one to define a new HSR candidate configuration by perturbing the current configuration within its neighborhood structure. The cooling schedule defines the initial temperature of the SAA, the stopping
Forbidden land-use ΩFE
Restricted land-use γλs > 0 Land-use exempt from
restrictions γλs = 0
temperature criteria, the rate of temperature decrease and the minimum number of iterations to be assessed before equilibrium is reached at each temperature step. The following sections detail both the procedures for generating candidate HSR configurations and the cooling scheduled implemented for solving the HSR planning optimization problem.
Existing literature discusses different possible methodologies for defining an initial system configuration such as the use of heuristics (Johnson and McGeoch 1997) or an arbitrarily random or best guess configuration (Bertsimas and Nohadani 2010; de Weck and Willcox 2010). Bertsimas and Nohadani (2010) discuss that if the SSA implementation allows the global search of the feasible space, the initial configuration will not interfere with the accessibility of the search space nor interfere with the quality of the final solution. Given that random- and heuristic- generated initial configurations lead to significant overhead computation time and complexity, an arbitrarily user-specified and feasible HSR configuration is considered.
Figure 4-10 SAA flowchart.
4.2.1 GENERATION OF HSR CANDIDATE CONFIGURATIONS
The procedure to generate new candidate HSR configurations starts by establishing the neighborhood of any current configuration and the new candidate configuration is obtained by changing, randomly in the neighborhood, the current one. The procedures adopted allow a fully integrated 3D change of the configurations by a random 3D repositioning of the nodes of the discretization mesh ΩN constituting the HSR configuration, within the neighborhood structure.
Consider the definition of the discretization mesh ΩN. The vertices of the mesh represent the allowed 3D position for the nodes of each solution. Figure 4-1 illustrates such a 3D discretization mesh defining the permissible node positions for the HSR configurations for a synthetic case-study.
Given the representation of the HSR configurations by linear sections, obtaining a new configuration layout consists in defining a new set of nodes and their respective linear sections. The neighborhood structure thus defines the maximum envelope distance at which each node can be repositioned.
Figure 4-11 shows the 3D neighborhood of a general node of ΩN for the discretization mesh in Figure 4-1. Moves are allowed to any of the immediate nodes varying x, y or z, or a combination of the three. As shown in Figure 4-11, the current gray (center) node may be randomly moved to one of the 26 neighboring yellow positions, in addition to be allowed to remain at the current one. Effectively, the new candidate configuration’s node position is randomly drawn from the set of the 27 3D positions within the neighborhood envelope.
The neighborhood of a mandatory node differs from the general case. This should be specified for each case-study application and two options are available: randomly move the nodes vertically to the upper or lower positions keeping the current plan view projection (x- and y- coordinates) or disallowing moves of any kind.
Figure 4-11 3D neighborhood definition for a current gray (center) node.
An example of a current configuration perturbed into a neighboring candidate configuration is shown in the plan view of Figure 4-12. For this simple case, a current configuration is formed by linear sections c1, c2 and c3, connecting the start and end mandatory nodes. Analyzing the transformation from the start node towards the end node of the configuration, one observes the end node of section c1 is randomly moved to the indicated neighbor position, forming the new candidate configuration section n1. Since, except for the end of the configuration, the end node of a linear section is the start node of the consecutive linear section, also section n2 of the new configuration will differ from section c2. The alignment of sections c3 and n3, however, coincide. This analysis assumes that variations in the z-direction are null.
Figure 4-12 Perturbing a current configuration into a neighboring candidate configuration.
Stating sections c3 and n3 are coincident, even if three-dimensionally coincident, does not mean their cost is the same. Although the cost of a linear section varies with its length, the cross-sections adopted are major factors influencing the cost and these can vary for 2 linear sections with identical 3D configuration.
If a bridge is required in the new section n2, it may be extended into part of section n3, while if section c2 requires only an embankment, section c3 may not include a bridge cross-section.
This emphasizes the continuity required in the cross-sections, for which the cross-section at a given point may be influenced by the cross-sections upstream and downstream of that point.
The aim of generating new candidate HSR configurations within a neighborhood is to allow small rearrangements to be tested instead of profound changes. In this context, the degree of freedom with which the current configuration is perturbed is significant. The degree of freedom, in the case of the HSR optimization problem, is related with the number of nodes to
Section c1
Section n1
Section n2
Section c2
Section c3 = Section n3
x
y START
END
be randomly perturbed in the neighborhood. Jilla and Miller (2001) present a study on the influence of the degree of freedom on the SAA performance for the design of distributed satellite systems. The study observes that if the degree of freedom is too low it is easy for the algorithm to be circumscribed to part of the design space. Conversely, if the degree of freedom is too large the algorithm engages in a random search and no longer takes advantage of the local neighborhood search properties. The implementation of the SAA should thus specify the number of nodes to be randomly perturbed from one configuration to another, adjusted to the case-study specifics.
In summary, the generation of candidate HSR configurations considers the perturbation of a specified number of randomly chosen 3D nodes, to be repositioned according the allowed moves for mandatory and general nodes.
4.2.2 COOLING SCHEDULE
The implementation of the SAA requires that an initially high temperature is considered, which is progressively decreased until an algorithm stopping criterion is reached. Different cooling schedules can be implemented (Aarts et al. 1997; de Weck and Willcox 2010). As discussed by Pardalos et al. (2000) the choice of a cooling schedule is very difficult, as one cannot appreciate, a priori, its performance for the problem in question.
The choice relies on an adaptive geometric (Johnson et al. 1989), also termed exponential (Ingber 1993; de Weck and Willcox 2010), cooling schedule based on the implementations for solving water supply infrastructure problems by Cunha (1999) and Cunha and Sousa (2001), and based on the research by Johnson et al. (1989). Four parameters are considered:
a: the elasticity of acceptance that defines the probability of accepting a transition from the initial configuration to a new candidate configuration that yields higher cost than the initial one. The probability is defined as a percentage and it is used to define the initial temperature of the algorithm by t1= ˗0.1c(s1)/ln(a), where c(s1) is the cost of the initial configuration. This expression defines an initial temperature that allows a%
of configurations, with a 10% higher cost than the initial configuration, to be accepted.
n1: the minimum number of algorithm iterations to be performed at each temperature.
A state of equilibrium (although not the equilibrium distribution of Markov chains
which requires an execution time exponentially dependent on the problem size) is to be reached at each temperature before the temperature decrease step. This is measured by decreasing the temperature only when no overall best configuration is attained or the average cost of the evaluated configurations does not improve. If better optimum configurations are found or if the average cost of the configurations improves, n1
configurations are again evaluated. This defines the adaptability of the cooling schedule.
r: the rate of temperature decrease, whenever a temperature decrease occurs. A geometric decrease rate is chosen with a constant r factor. The temperature decrease at each level is governed by tk=rk t1. The value chosen is of great influence on the quality of the results achieved (Aarts et al. 1997; Johnson et al. 1989): if the rate is too low (large r) the algorithm performance can resemble a random search (virtually any neighboring configuration is accepted), whereas small values of r can relate to performing as an iterative improvement, which terminates at the first local optimum encountered. Typical values can range between 0.7 and 0.99 (Cunha 1999; de Weck and Willcox 2010).
n2: the number of temperature decreases to be performed without improvement of the optimum or the average cost. It establishes the stopping criterion of the algorithm.
Johnson et al. (1989) discuss that the amount of time the SAA spends in the intermediate temperature range, between very high and very low temperatures, affects the quality of the solutions. Thus, the adaptive cooling schedule is considered in the implementation presented for the HSR planning problem. When compared with a fixed number of evaluated configurations at each temperature step, the adaptive cooling schedule allows the algorithm to spend more time at these intermediate temperatures.
Finally, some important observations for implementing the SAA to different problems have been introduced in literature. These regard the effectiveness of the cooling schedule and include the following:
Kirkpatrick (1984) and Van Laarhoven and Aarts (1987) suggest that the initial temperature should be such that at least 80% of the computed configurations are
accepted at that temperature. In these conditions of high initial temperatures, one might expect the final solution to be independent of the initial solution (Cunha 1999).
Johnson et al. (1989) suggest that obtaining the best results it is necessary to allow for long annealing runs. Increasing the length of an annealing run is more effective if uniformly throughout the schedule rather than at the beginning and at the end of the schedule. This can be done with the increase of the cooling ration r, the number of iterations n1, or by using an adaptive cooling schedule.
Johnson et al. (1989) observe that even with the implementation of long SAA runs, a large variation in the quality of the solutions can be obtained in different runs.
4.3 SOFTWARE TESTING: APPLICATION TO A SYNTHETIC CASE-STUDY