I want to enforce linear envelopes on the cosine function in PowerModelsAnnex. I implement the following code for doing that.
for (bp, buspair) in ref[:buspairs]
@constraint(model, cs[bp]>= linear_envelopes1 [k]*td[bp]+ linear_envelopes2 [k])
I get the following error. Can you please let me know how I can fix this. Thanks in advance!
ERROR: LoadError: The operators <=, >=, and == can only be used to specify scalar constraints. If you are trying to add a vectorized constraint, use the element-wise dot comparison operators (.<=, .>=, or .==) instead