필터 지우기
필터 지우기

the initial point is local minima for fmincon.

조회 수: 43 (최근 30일)
Muhammad Zeeshan Babar
Muhammad Zeeshan Babar 2017년 8월 3일
댓글: Torsten 2017년 8월 4일
I am trying to solve a minimization problem using fmincon but the solver doesn't perform any optimization and gice this message. I have tried with all possible values of the initial condition, but the answer remain same. Please help me.
Iter F-count f(x) Feasibility Steplength step optimality \\
0 41 7.501427e-02 0.000e+00 0.000e+00
Initial point is a local minimum that satisfies the constraints.
Optimization completed because at the initial point, the objective function is non-decreasing in feasible directions to within the selected value of the optimality tolerance, and constraints are satisfied to within the selected value of the constraint tolerance.
  댓글 수: 3
Muhammad Zeeshan Babar
Muhammad Zeeshan Babar 2017년 8월 3일
편집: Muhammad Zeeshan Babar 2017년 8월 3일
The code is given below. where the cost function involves only the minimization of trace of P_est. The control horizon length is N = 30 and the simulations are performed for k=currentInstant=100 samples.
Please explain your above answer according to this code.
%%%%%%%Initial values for the control inputs %%%%%%%%%%%%%%%%%
a = +25;
b = -25;
u0 = a + (b-a)*rand(1, MPC.horizon);
%%%%%%%%%%%%%Bound on control inputs %%%%%%%%%%%%%%%%%
minu = -50*ones(1, MPC.horizon);
maxu = +50*ones(1, MPC.horizon);
%%%%%%%%%%%%fmincon function %%%%%%%%%%%%%%%%%
A = []; % linear inequalities A*x < B
B = [];
Aeq = []; % linear equalities Aeq*x = Beq
Beq = [];
nonlcon = []; % nonlinear inequalties or equalties
fun = @(u)costFunction(x, u, currentInstant, MPC,r_x1, para, P_est,alpha); %function handle
[uopt(:,i), Jopt(i), exitfl(i), outp{i}] = fmincon(fun, u0, A, B, Aeq, Beq, minu, maxu, nonlcon, options);
Torsten
Torsten 2017년 8월 4일
Without seeing "costFunction", nothing can be said.
Best wishes
Torsten.

댓글을 달려면 로그인하십시오.

답변 (2개)

Sidafa
Sidafa 2017년 8월 3일
It looks as though fmincon has converged from the output. The objective function, as pointed out from the previous answer, may be constant or is solved at the initial guess.

Julie Kraus
Julie Kraus 2017년 8월 3일
Fmincon only finds a local minimum, if your start point is at a local minimum in all feasible directions it has found a local minimum.
You may have better luck with the global search, it will choose a bunch of different start points, which can yield a better solution.

카테고리

Help CenterFile Exchange에서 Linear Least Squares에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by