The GA Procedure

Objective Function

evaluates a standard objective function from within a user subroutine

r = Objective( selected, seg, type<, parameter1, parameter2, ...> );

The inputs to the function are as follows:

selected        is an array that specifies the solution to be evaluated.
segis the desired segment of the solution to be evaluated.
typeis objective function name, which also determines the number and type of parameters expected.
parameter1-nare optional parameters applicable to particular objective functions.

The accepted values for type and the corresponding parameters are summarized in Table 1.3.

Table 1.3: Objective Function Types
type encodings parameters  
'TSP'sequencedistances 
The parameters are as follows:

distances        is a matrix of distances between locations, such that  distances[i,j] is the distance between location i and j.

The Objective call should be made only from within a user objective function. The precise actions of the standard objective functions are described in the section "Objective Functions".

Previous Page | Next Page | Top of Page