i am using Matlab2010a .how do i eliminate this error: ??? Undefined function or method 'initializega' for input arguments of type 'double'. Error in ==> PID_GA at 8 initPop=initializega(populationSize,variableBounds,evalFN,evalOps,options);
2 views (last 30 days)
Show older comments
%Initialising the genetic algorithm populationSize=80; variableBounds=[-100 100;-100 100;-100 100]; evalFN='PID_objfun_MSE'; %Change this to relevant object function evalOps=[]; options=[1e-6 1]; initPop=initializega(populationSize,variableBounds,evalFN,evalOps,options); %Setting the parameters for the genetic algorithm bounds=[-100 100;-100 100;-100 100]; evalFN='PID_objfun_MSE'; %change this to relevant object function evalOps=[]; startPop=initPop; opts=[1e-6 1 0]; termFN='maxGenTerm'; termOps=100; selectFN='normGeomSelect'; selectOps=0.08; xOverFNs='arithXover'; xOverOps=4; mutFNs='unifMutation'; mutOps=8; %Performing the genetic algorithm [x,endPop,bPop,traceInfo]=ga(bounds,evalFN,evalOps,startPop,opts,... termFN,termOps,selectFN,selectOps,xOverFNs,xOverOps,mutFNs,mutOps);
0 Comments
Answers (0)
See Also
Categories
Find more on Genetic Algorithm in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!