Use Case
The tariff cost calculator makes certain assumptions involving the consumer's consumption in order to relax the inherently nonconvex tariff structures into a convex form. This enables us to quickly solve an optimization problem with the tariffs in CVXPY (and usually reaches an identical solution to the nonconvex formulation).
Solution
Since Pyomo supports nonconvex programs, we can create a version of the tariff cost calculator that uses the true form of the tariffs.
This would be especially helpful for users who want to interact directly with Pyomo model objects because the objective function could then be set as the true electricity costs instead of the convex relaxation.
Alternatives
A user needs to compute the cost again in numpy after the optimization model has solved in order to get the true cost since the model objects contain convex relaxations (and are therefore not the true electricity bill).
Use Case
The tariff cost calculator makes certain assumptions involving the consumer's consumption in order to relax the inherently nonconvex tariff structures into a convex form. This enables us to quickly solve an optimization problem with the tariffs in CVXPY (and usually reaches an identical solution to the nonconvex formulation).
Solution
Since Pyomo supports nonconvex programs, we can create a version of the tariff cost calculator that uses the true form of the tariffs.
This would be especially helpful for users who want to interact directly with Pyomo model objects because the objective function could then be set as the true electricity costs instead of the convex relaxation.
Alternatives
A user needs to compute the cost again in
numpyafter the optimization model has solved in order to get the true cost since the model objects contain convex relaxations (and are therefore not the true electricity bill).