% Particle Swarm optimalisation % BSDLicence % Rick van der Zwet - 0433373 - % Modeled after http://en.wikipedia.org/wiki/Particle_swarm_optimization % Iterate on multiple vectors function fitness = SHGa(v) for i = 1:length(v(1,:)) fitness(i) = SHG(v(:,i)); end end