Groups keyboard shortcuts have been updated
Dismiss
See shortcuts

appsi_highs fails with quadratic objective

28 views
Skip to first unread message

mikkel.a...@gmail.com

unread,
Oct 22, 2024, 9:20:29 AM10/22/24
to Pyomo Forum
Hi.

I'm trying to run my large scale energy system model (1.5 mill rows x 1 mill cols) with a quadratic objective function (and linear constraints ...'QCP') using appsi_highs solver interface. My modified model will run very well with QCP (running twice as fast and producing more reliable results) using the Pyomo/GAMS interface. 

However, appsi_highs seems to fail for me with QCP (it runs fine with LP). The error message with QCP is:

"DegreeError: Highs interface does not support expressions of degree None"

Am I just unlucky that QCP is not (yet) implemented in appsi_highs or HiGHS itself?
Or did I make a mistake, or is there some sort of way that I can make appsi_highs run my QCP model?
I've pasted in below a simplified code example that reproduces the problem.

I'll be grateful for any help or hints or direction to people who might be able to help me ... or just a confirmation that QCP is indeed not an option with HiGHS + Pyomo.

Thanks + cheers, 
Mikkel

Versions:
HiGHS: 1.7.2
Pyomo: 6.8.0
Python: 3.11.0

import pyomo.environ as pyo

model.PRODUC = pyo.Var(domain=pyo.NonNegativeReals)
model.DEMAND = pyo.Var(domain=pyo.NonNegativeReals)

model.OBJ = pyo.Objective(expr = 500*model.PRODUC - 2000*model.DEMAND - 100*model.DEMAND*model.DEMAND)
model.BAL = pyo.Constraint(expr = model.PRODUC == model.DEMAND)
model.MAX = pyo.Constraint(expr = model.DEMAND <= 200)

opt = pyo.SolverFactory('appsi_highs')
opt.solve(model)



Reply all
Reply to author
Forward
0 new messages