1 package aco
.strategy
.as
;
5 import aco
.mediator
.as
.*;
7 public class ASChoiceInformationStrategy
8 extends ChoiceInformationStrategy
{
10 protected ASMediator acom
;
12 public ASChoiceInformationStrategy(ACOMediator acom
) {
16 public void computeChoiceInformation() {
17 for (int i
= 0; i
< acom
.getNumOfCities(); i
++) {
18 for (int j
= 0; j
< acom
.getNumOfCities(); j
++) {
19 acom
.setChoiceInformation(i
,j
,
20 Math
.pow( acom
.getPheromone(i
,j
), acom
.getAlpha() ) *
21 Math
.pow( acom
.getHeuristicInformation(i
,j
) , acom
.getBeta() ));