Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LINCOA doesn't adhere to upper and lower bounds #178

Open
asenzz opened this issue Mar 23, 2024 · 8 comments
Open

LINCOA doesn't adhere to upper and lower bounds #178

asenzz opened this issue Mar 23, 2024 · 8 comments

Comments

@asenzz
Copy link

asenzz commented Mar 23, 2024

I noticed running LINCOA will make it regularly underrun set lower bound for a parameter, and cause my program to stop. Is LINCOA supposed to be bounds checked? If not, can you add the feature of bounds for LINCOA?

@zaikunzhang
Copy link
Member

zaikunzhang commented Mar 23, 2024

Hi,

See #42

In brief, this is known. It is not a bug. It is how Powell designed LINCOA and COBYLA. We optimization people call them "infeasible algorithms", which means that they are allowed to visit infeasible points, although they are supposed to achieve feasibility asymptotically. Such algorithms are common and non-strange.

Nevertheless, as mentioned in #42, I do understand that bound constraints are often inviolable. Therefore, I plan to improve the algorithms to ensure they always respect bounds. However, I do not think I will have time for that within a few months.

cause my program to stop.

Which interface are you using? The MATLAB interface should be able to continue the optimization even if the evaluation of the objective/constraint function fails.

Thanks.

Zaikun

@asenzz
Copy link
Author

asenzz commented Mar 23, 2024 via email

@zaikunzhang
Copy link
Member

zaikunzhang commented Mar 23, 2024

I fully understand the situation. This is a known issue. Although this is not a bug, it will be fixed when I have time. See below (again).

In brief, this is known. It is not a bug. It is how Powell designed LINCOA and COBYLA. We optimization people call them "infeasible algorithms", which means that they are allowed to visit infeasible points, although they are supposed to achieve feasibility asymptotically. Such algorithms are common and non-strange.

Nevertheless, as mentioned in #42, I do understand that bound constraints are often inviolable. Therefore, I plan to improve the algorithms to ensure they always respect bounds. However, I do not think I will have time for that within a few months.

In addition, may I know whether you are using LINCOA through any interface?

Which interface are you using? The MATLAB interface should be able to continue the optimization even if the evaluation of the objective/constraint function fails.

Thanks.

@asenzz
Copy link
Author

asenzz commented Mar 23, 2024

That would be great, thanks. I use PrimaC - the C interface to the Fortran library in a multithreaded C++ project (G++ 13).

@zaikunzhang
Copy link
Member

Thank you for the information.

@mcmillab
Copy link

mcmillab commented Jun 17, 2024

I have the same problem. I use LINCOA in C# via CSNumerics.

Even for trivial X values, it seems to fail sometimes.

For example if I have these As and Bs:

LINCOAs: A and B are:
1 . . . 1
. 1 . . 1
. . 1 . 1
. . . 1 1
-1 . . . 1
. -1 . . 1
. . -1 . 1
. . . -1 1
1 1 1 1 .
-1 -1 -1 -1 .

it tells me "LINCOA has made the initial X feasible by increasing part(s) of B."
when x=0,0,0,0 is a feasible solution.
It then returns an infeasible solution.

Is there an easy fix here?

@zaikunzhang
Copy link
Member

zaikunzhang commented Jun 17, 2024

Hi @mcmillab ,

Thank you for your message. Could you provide a minimal working example?

I use LINCOA in C# via CSNumerics.

We don't provide PRIMA in C#. If it is not an interface provided by us, I am afraid that there is not much we can help with.

Thank you.

Zaikun

@asenzz
Copy link
Author

asenzz commented Jun 17, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants