I am trying to get an array of constraints, but I keep getting different kinds of errors, and I don't know what I'm doing wrong.
data array is 77x9 (integer values)
foods is a column vector of size 77x1, a variable of array type
lower is a column vector of 9x1, an integer vector
I should have 9 constraints
Here is what I have,
model2 = Model()
@variable(model2, foods[i=1:77] >= 0) # Quantity of food
for i ∈ 1:9
for j ∈ 1:77
@constraint(model2, c2[i], sum(data[j][i]*foods[j])<=lower[i])
end
end