Could you plz help me guys.

1 visualización (últimos 30 días)
Hussam musbah
Hussam musbah el 20 de Jun. de 2014
Respondida: Hussam musbah el 20 de Jun. de 2014
I am working on something like this subject and every-time I operate this code, it gives me "Undefined function or variable 'x_ga_opt'". So if anyone has the code, could you plz email it to me.

Respuestas (2)

James Tursa
James Tursa el 20 de Jun. de 2014
Can you examine the code to see if it looks like a function or a variable? Maybe it is a variable that was supposed to be defined upstream in the code but didn't for some reason. Or maybe there is a script m-file out there that is supposed to define this variable. Etc etc. You really haven't given us much to go on. Can you search all of the m-files for the string 'x_ga_opt'?

Hussam musbah
Hussam musbah el 20 de Jun. de 2014
Thanks a lot for your response! These are the results???? Undefined function 'mse_test' for input arguments of type 'network'.
Error in @(x)mse_test(x,net,inputs,targets)
Error in validate>@(x)fitness(x,FitnessFcnArgs{:}) (line 136) fitness = @(x) fitness(x,FitnessFcnArgs{:});
Error in fcnvectorizer (line 14) y(i,:) = feval(fun,(pop(i,:)));
Error in makeState (line 47) Score = fcnvectorizer(state.Population(initScoreProvided+1:end,:),FitnessFcn,1,options.SerialUserFcn);
Error in gaunc (line 41) state = makeState(GenomeLength,FitnessFcn,Iterate,output.problemtype,options);
Error in ga (line 351) [x,fval,exitFlag,output,population,scores] = gaunc(FitnessFcn,nvars, ...
Error in Untitled2 (line 29) [x_ga_opt, err_ga] = ga(h, 3*n+1, ga_opts); Caused by: Failure in user-supplied fitness function evaluation. GA cannot continue.
Error using edit (line 66) Undefined function or variable 'x'.

Categorías

Más información sobre Nonlinear Optimization en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by