Cognitive weight is also used to adjust the swarm speed. It is the factor that determines the extent to which the particle will follow its own best solution. 1.49445 is the default value:
The code is as follows:
// Update Swarm Speed
Swarm[i].Speed[j] = Intertia * Swarm[i].Speed[j] + CognitiveWeight * Swarm_Random() * (Swarm[i].BestPosition[j] - Swarm[i].Position[j])+ SocialWeight * Swarm_Random() * (GlobalBest.BestPosition[j] - Swarm[i].Position[j]);
Cognitive Weight = 1.49445:
3D Plot
Cognitive Weight = 1.19445:
3D Plot