Hi, I’m new with GAMS and I’m struggling with a very simple problem.
I wish to define the product between a matrix(k,m) and a vector(k), e.g.:
A = [0.082 0.036 ; 0.036 0.127] and v = [1 ; 0]
Multiplying Av I expect to obtain the first column of A, so: x = Av = [0.082; 0.036]
If I try:
x(k) = sum(m,A(k,m)*v(k))
My result is a single element that is the sum of the two elements I expect to be in the column, hence 0.118.
If I try with the product (x(k) = prod(…)), my result is a single element that is the product of the two elements I expect to be in the column, hence 0.003.
What am I doing wrong? Thanks a lot to anyone will help.