Cover of Swarm Intelligence Book 

Particle Swarm Optimisation Algorithms

The following classes are available (all discussions assume CIlib version 0.5, and therefor assumes the same directory structure as used in CIlib):

  • gbest PSO [ Show ]
  • lbest PSO [ Hide ]

    Find below the XML specification for a standard Local Best PSO implementation (section 16.1.2).

    <simulator>
      <algorithms>
        <algorithm id="lbest-pso" class="pso.PSO">
          <topology class="entity.topologies.LBestTopology">
            <neighbourhoodSize class="controlparameter.ConstantControlParameter" parameter="3" />
          </topology>
          <iterationStrategy class="pso.iterationstrategies.ASynchronousIterationStrategy" />
          <initialisationStrategy class="algorithm.initialisation.ClonedPopulationInitialisationStrategy">
            <prototypeEntity class="pso.particle.StandardParticle">
              <positionUpdateStrategy class="pso.positionupdatestrategies.StandardPositionUpdateStrategy" />
              <velocityUpdateStrategy class="pso.velocityupdatestrategies.StandardVelocityUpdate">
                <inertiaWeight class="controlparameter.ConstantControlParameter" parameter="0.729844" />
                <cognitiveAcceleration class="controlparameter.RandomizingControlParameter" parameter="1.496180" />
                <socialAcceleration class="controlparameter.RandomizingControlParameter" parameter="1.496180" />
                <vMax class="controlparameter.ConstantControlParameter" parameter="2.0" />
              </velocityUpdateStrategy>
              <velocityInitialisationStrategy class="pso.particle.initialisation.RandomInitialVelocityStrategy" />
            </prototypeEntity>
            <entityNumber value="30" />
          </initialisationStrategy>
        </algorithm>
      </algorithms>
      <problems>
        <problem id="griewank" class="problem.FunctionMinimisationProblem">
          <function class="functions.continuous.Griewank" domain="R(-600, 600)^30" />
        </problem>
      </problems>
      <measurements id="measurements" class="simulator.MeasurementSuite" resolution="1" samples="30">
        <addMeasurement class="measurement.single.Fitness" />
        <addMeasurement class="measurement.single.Diversity" />
        <addMeasurement class="measurement.single.FitnessEvaluations" />
      </measurements>
      <simulations>
        <simulation>
          <algorithm idref="lbest-pso">
            <addStoppingCondition class="stoppingcondition.MaximumIterations" maximumIterations=" 1000 " />
          </algorithm>
          <problem idref="griewank" />
          <measurements idref="measurements" file="data/griewank.lbest.p_30.w_0_72.c1_1_49.c2_1_49.vmax_2.txt" />
        </simulation>
      </simulations>
    </simulator>

    Click here to download this file.

    The XML file above provides a specification for a simulation which executes a standard local best (lbest) PSO (Algorithm 16.2 on page 293) on the griewank function (page 556, Equation A.15). Results of the simulations are written to the data/griewank.lbest.p_30.w_0_72.c1_1_49.c2_1_49.vmax_2.txt file.

    Using the defaults The XML specification above is not as detailed as that given for the gbest PSO. Here the defaults as specified in the implementation of the algorithm are used. These defaults are as given in the discussion on gbest PSO.

    How to specify the neighborhood size? The size of neighborhoods, which are currently only determined based on particle indices (equation 16.8, page 292), is specified via the neighbourhoodSize control parameter. This is set to a constant value of 3. The size is the total number of particles including the particle itself.

    Can any of the parameters and behaviours of the algorithm be changed? Certainly! Have a look at the gbest PSO discussion. Any of the parameters/behaviours mentioned there can be changed using any of the classes available in the corresponding package.

    Which velocity update is used? The velocity update (equation 16.6, page 292) for lbest PSO is used as default.

  • Swarm Initialization [ Show ]
  • Stopping Conditions [ Show ]
  • Neighborhood Topologies [ Show ]