Is pulp.lpDot(a,n) not equivalent to pulp.lpSum([a[i] * n[i] for i in range(N)])?
Is pulp.lpDot(a,n) not equivalent to pulp.lpSum([a[i] * n[i] for i in range(N)])? Question: I have a decision variable vector n, and a is a constant vector. What confuses me is why lpDot(a,n) is not equivalent to lpSum([a[i] * n[i] for i in range(N)]) in a constraint? Here is the code: import pulp import numpy as …