I think my PSO code is correct but I don’t know why I get this error? I am using this code for other problems it is working fine but on prinkinsons data it is showing error. Anybody who can help?

2 Ansichten (letzte 30 Tage)
Reference to non-existent field 'Position'.
Error in PSO (line 85)
+ c2*rand(VarSize).*(GlobalBest.Position -
particle(i).Position);
Error in pso2 (line 33)
out = PSO(problem, params);

Antworten (1)

Alan Weiss
Alan Weiss am 21 Apr. 2021
I suggest that you learn to use the debugger.
Alan Weiss
MATLAB mathematical toolbox documentation

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by