PSO coding how to declare the Food availability coding?
Show older comments
food avalailabily how to declare that function i dnt know please help..... i have attached my coding below please refer to that
Food_availability=Objective function with one input variable (for more than one variable you may use array) % example for two variable % function f = funfunc(array) % a=array(1); % b=array(2); % f = a+b ; % end % Food_availability is a string, for above example : 'funfunc'
getting this error Completed 0 % ...Error using Food_availability Too many input arguments.
Error in Particle_Swarm_Optimization (line 103) availability(p,itr)=feval(Food_availability,parameter);
Error in funfunc (line 15) y=Particle_Swarm_Optimization(Bird_in_swarm, Number_of_quality_in_Bird, MinMaxRange, Food_availability, availability_type, velocity_clamping_factor, cognitive_constant, social_constant, Min_Inertia_w
Answers (0)
Categories
Find more on Particle Swarm in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!