How do you add a piecewise linear constraint to a model in Pyomo?
from pyomo.environ import Piecewise
model.f = Var()
model.x_pts = [0, 1, 2]
model.f_pts = [0, 1, 4]
model.constraint = Piecewise(model.x, model.f, pw_pts=model.x_pts, f_rule=model.f_pts)