Home

## Latex

A minimization problem:

$$f(x,y)=x sin(\sqrt{|y+1-x|})cos(\sqrt{|x+y+1|}) + (y+1)cos(\sqrt{|y+1-x|})sin(\sqrt{|x+y+1|})$$

$$-512 \leq x_i \leq 512$$

$$\text{In 2 dimensions, the minimum is at }f(-488.6326, 512) = -511.73$$

In the python code below I use the weighted wrap method for expanding functions. For example, expanding the two dimensional function $f(x,y)$ to four dimensions: $g(x_1,x_2,x_3,x_4)=w_1f(x_1,x_2)+w_2f(x_2,x_3)+w_3f(x_3,x_4)+w_4f(x_4,x_1)$. This is described in more detail in "The Island Model Genetic Algorithm: On Separability, Population Size and Convergence".

## Python

def fitnessFunc(self, chromosome):
""" """
if len(chromosome) <= 2:
return self.ranaHelperFunction(0, chromosome)
else:
total = 0
for i in xrange(len(chromosome)):
total += self.weights[i] * self.ranaHelperFunction(i, chromosome)

def ranaHelperFunction(self, index, chromosome):
x = chromosome[index]
y = chromosome[(index+1)%len(chromosome)]
return x*math.sin(math.sqrt(math.fabs(y+1-x)))*math.cos(math.sqrt(math.fabs(x+y+1))) + (y+1)*math.cos(math.sqrt(math.fabs(y+1-x)))*math.sin(math.sqrt(math.fabs(x+y+1)))


## Sources

The following may or may not contain the originator of this function.

The Island Model Genetic Algorithm: On Separability, Population Size and Convergence
@article{separabilityConvergence,
location = {http://www.scientificcommons.org/42876414},
title = {The Island Model Genetic Algorithm: On Separability, Population Size and Convergence},
author = {Darrell Whitley and Soraya Rana and Robert B. Heckendorn},
abstract = {Parallel Genetic Algorithms have often been reported to yield better performance than Genetic Algorithms which use a single large panmictic population. In the case of the Island Model genetic algorithm, it has been informally argued that having multiple subpopulations helps to preserve genetic diversity, since each island can potentially follow a different search trajectory through the search space. It is also possible that since linearly separable problems are often used to test Genetic Algorithms, that Island Models may simply be particularly well suited to exploiting the separable nature of the test problems. We explore this possibility by using the infinite population models of simple genetic algorithms to study how Island Models can track multiple search trajectories. We also introduce a simple model for better understanding when Island Model genetic algorithms may have an advantage when processing some test problems. We provide empirical results for both linearly separa...},
journal = {Journal of Computing and Information Technology},
year = {1998},
volume = {7},
pages = {33--47},
url = {http://citeseerx.ist.psu.edu/viewdoc/summary?doi=?doi=10.1.1.36.7225},
institution = {CiteSeerX - Scientific Literature Digital Library and Search Engine [http://citeseerx.ist.psu.edu/oai2] (United States)},
}

Evaluating evolutionary algorithms

## Notes

According to "The Island Model Genetic Algorithm: On Separability, Population Size and Convergence" the global optimimum occurs when all inputs are set to -512 and the optimum value is -511.70. However, other sources claim that the optimal point, at least in 2 dimensions, occurs at -488.6326, 512, and we have confirmed that the fitness at -488.6326, 512 is superior. We are not certain how the optimum changes (or if it changes) when this function is extended to higher dimensions. Perhaps Whitley, et al. were referring to the function in higher dimensions or the value they cite is a typo.