Helly everyone,
I have looked for a solution on Matlab central but I did not find anyone.
I would like to use the function fmincon in order to minimize a non linear function.
My problem is that the coefficients in the A matrix are dependent on x. I have a lookup table in 3D in Excel to get the coefficients of A. The values, also depending on x, of the function f have to be read also in a lookup table in the Excel file.
Is it possible to use the function fmincon in this case? If yes, could you give me an idea of how can I do it please?
I hope that I made myself clear and thanks you in advance for the help.
Thanks you,

 Akzeptierte Antwort

Sean de Wolski
Sean de Wolski am 9 Sep. 2013

0 Stimmen

Hi Chamun,
Since A depends on the current value of x, these will be non-linear constraints. You will have to use the nonlcon option to fmincon

3 Kommentare

Chamun
Chamun am 9 Sep. 2013
Hi Sean de Wolski,
thanks you for your answer. I still have to try to implement it but I think it will work. I did not think to use this option before.
Matt J
Matt J am 9 Sep. 2013
I have a lookup table in 3D in Excel to get the coefficients of A.
Additionally, you will need to interpolate your look-up table at the current x using a twice differentiable interpolant (e.g., 'spline') so that A(x) is a twice-differentiable function of x. You must not use a discrete, x-dependent index to look up data in the table.
Sean de Wolski
Sean de Wolski am 9 Sep. 2013
@Matt, Chamun,
It might make more sense to use patternsearch then.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by