-
Notifications
You must be signed in to change notification settings - Fork 31
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
Can this library solve any convex-concave problem? #77
Comments
Yes, the paper is at https://web.stanford.edu/~boyd/papers/dccp.html.
On Mar 24, 2022, at 2:45 AM, Ming Zhu ***@***.***> wrote:
Good work.
Can this library solve any convex-concave problem? For example, there are non-convex constraints:
(x + y)^2 -x^2 - y^2 - (x^2 + y^2) ^ (3/2) <= 0
-x^2 - y^2 + 100 <= 0
Yes, of course. Just read the documentation.
Is obtained solution globally optimal?
Ans no, of course not. Again, please read the documentation and the paper.
Is there any paper to describe the algorithm/method?
See above.
…
Thank you very much.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.
|
Hi @zhumingpassional, for the specific constraints that you mentioned, DCCP can handle them as long as you write them as |
Thanks for your reply and valuable suggestions. Can CVXPYgen generate C code for embedded applications when using cvxpy and dccp? Is the generated C code faster than the python code? |
Hi @zhumingpassional, thanks for the questions, but DCCP currently does not work with CVXPYgen. |
Will CVXPYgen support DCCP in the near future? I really hope it can. Thanks. |
I use DCCP to solve a convex-concave problem, whose constraint is: However, if I revise the constraint as Does this library only support the power function where the parameter should be integer? I am not sure.
If I used the second model so that it works. Sometimes, DCCP cannot obtain a solution. Is it because it cannot obtain a feasible solution using the method in your paper? If I use other methods to get an initial solution, does DCCP provide the interface to support it? Hope to get your reply. Thanks very much. |
Read the documentation, which is very clear about what expressions and constraints are accepted. It is easy to handle yours, by simply rewriting it in the correct form.
… On Apr 1, 2022, at 12:14 AM, Ming Zhu ***@***.***> wrote:
I use DCCP to solve a convex-concave problem, whose constraint is:
(x + y)^2 <= x^2 + y^2 + (x^2 + y^2) ^ (3/2) # I used cvxpy.power(, 3/2)
It does not work. It raise errors:
" cvxpy.error.DCPError: Problem does not follow DCP rules. Specifically:
The following constraints are not DCP:
0.0 <= power(var4[0], 2.0) + power(var5[0], 2.0) , because the following subexpressions are not:
|-- 0.0 <= power(var4[0], 2.0) + power(var5[0], 2.0)"
However, if I revise the constraint as
(x + y)^2 <= x^2 + y^2 + (x^2 + y^2) ^ (2), # I used cvxpy.power(, 2)
It works.
Does this library only support the power function where the parameter should be integer? I am not sure.
Hope to get your reply. Thanks very much.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you were mentioned.
|
@zhumingpassional For the first question, the following code should work.
For the second question, yes, you can initialize the variables by setting their values before calling DCCP to solve, and then DCCP will use the initialization that you provide. The code is simply like the following.
|
@stephenpboyd @xinyueshen Thank you very much for your valuable reply. Excellent work! I will read the document carefully. |
Good work.
Can this library solve any convex-concave problem? For example, there are non-convex constraints:
(x + y)^2 -x^2 - y^2 - (x^2 + y^2) ^ (3/2) <= 0, where (x + y)^2 is convex, and -x^2 - y^2 - (x^2 + y^2) ^ (3/2) is concave
-x^2 - y^2 + 100 <= 0
Is obtained solution globally optimal?
Is there any paper to describe the algorithm/method?
Thank you very much.
The text was updated successfully, but these errors were encountered: