Particle Swarm Topology.Random Method
Definition
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.1.0
public static ParticleSwarmTopology Random(
int neighborhoodSize = 3,
int updateFrequency = 10
)
Parameters
- neighborhoodSize Int32 (Optional)
- The size of the neighborhood.
- updateFrequency Int32 (Optional)
- How often to update connections (in iterations).
Return Value
ParticleSwarmTopologyA ParticleSwarmTopology instance representing the random topology.
Remarks
In the random topology, each particle in the swarm is influenced by a randomly selected subset of other particles. The size of this subset is determined by the neighborhoodSize parameter. This means that each particle has a dynamic neighborhood that changes over time, promoting diverse exploration of the search space.
The updateFrequency parameter specifies how often (in iterations) the connections between particles are updated. A higher update frequency means that the neighborhood of each particle changes more frequently, which can help in avoiding local optima by constantly altering the influence network.
The random topology is particularly useful in multimodal optimization problems where maintaining diversity and avoiding premature convergence are crucial. By randomly changing the neighborhood, the swarm can explore different regions of the search space more effectively.
However, the random topology may result in slower convergence compared to more structured topologies like the global topology, where each particle is influenced by every other particle. It is best suited for problems where exploration is more important than rapid convergence.