You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Firstly thank you for making such a useful extension to OSQP.
I think the readme is slightly misleading on the final line where it says
minimize 0.5 x' P x + q' x
subject to l <= A x <= u
x[i] in Z for i in i_idx
i_l[i] <= x[i] <= i_u[i] for i in i_idx
In this expression i could take values from 0 to n-1 where n is the total number of variables - these are the possible values of the entries in i_idx. However i_l and i_u will only have len(i_idx) <= n elements.
I believe it should more accurately say something like (in python pseudocode at least)
i_l[j] <= x[i] <= i_u[j] for j, i in enumerate(i_idx)
I hope that makes sense :)
The text was updated successfully, but these errors were encountered:
You are correct. Here is what I'm understood (after I use the code):
x: is all the variable i_idx: contains index where x is strictly integer x[i] in Z for i in i_idx: strictly integer variable i_l[i] <= x[i] <= i_u[i] for i in i_idx: is lower and upper bounds of the strictly integer variable
Thus:
len(i_l) == len(i_u) == len(i_idx)
Making i_l[j] <= x[i] <= i_u[j] for j, i in enumerate(i_idx) is more correct
Firstly thank you for making such a useful extension to OSQP.
I think the readme is slightly misleading on the final line where it says
In this expression
i
could take values from 0 ton-1
wheren
is the total number of variables - these are the possible values of the entries ini_idx
. Howeveri_l
andi_u
will only havelen(i_idx) <= n
elements.I believe it should more accurately say something like (in python pseudocode at least)
I hope that makes sense :)
The text was updated successfully, but these errors were encountered: