MATLAB: Find the minimum the function using GA

genetic algorithmoptimization

f(x,y) = (x-1)*sin(y)

Best Answer

  • One problem that I see: your 2 unknowns must be passed to obj as a single argument
    obj=@(x) (x(1)-1).*sin(x(2))