MPQuadraticObjective

Visto 102 veces
Saltar al primer mensaje no leído

Emmanuel Seve

no leída,
17 ene 2022, 5:14:5917/1/22
a or-tools-discuss
Hi all,

I'm searching an example in Java with a quadratic objective function.
I didn't found one so far. 

I'm using the MP-solver with the SAT backend.

I wonder if the quadradic objetcive works with the SAT backend since there 
is only integer variables ? I have the possibility to use the GLOP backend (so with only double variable) if needed.

Emmanuel

Laurent Perron

no leída,
17 ene 2022, 5:28:0917/1/22
a or-tools-discuss
Glop is a linear simplex solver. So no quadratic.
SAT supports quadratic objective, but only discrete variables, but not through the proto API :-(
Laurent Perron | Operations Research | lpe...@google.com | (33) 1 42 68 53 00



--
You received this message because you are subscribed to the Google Groups "or-tools-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to or-tools-discu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/or-tools-discuss/1d5c27de-ec4b-4577-9650-2e7b5ab95b53n%40googlegroups.com.

Emmanuel Seve

no leída,
17 ene 2022, 5:44:2417/1/22
a or-tools-discuss
Encore merci Laurent pour cette réponse super rapide

So what is the solution to use MPQuadraticObjective defined here :


?

Laurent Perron

no leída,
18 ene 2022, 1:50:0518/1/22
a or-tools...@googlegroups.com
option 1: Fill the proto manually. Solve with MPSolver::SolveWithProto(model_request, &response).
It only works with SCIP and Gurobi.

option 2: use the CP-SAT API directly with the AddMultiplicationEquality() method.

Laurent Perron | Operations Research | lpe...@google.com | (33) 1 42 68 53 00


Responder a todos
Responder al autor
Reenviar
0 mensajes nuevos