Originally posted by: iturkmen
Hi,
My code includes these :
strcat(infile, "/mydata.txt");
sscanf(Line, "%s %d,%d,%d,%d %s %lf",&Y1, &V1, &I1, &J1, &T1, &N2,&Val);
It doesn't work because I don't know how to code this situation.
My decision variables are listed below.
y(1,1,6,185) = 0.196002
y(1,1,9,3047) = 0.242096
y(1,1,10,2761) = 0.334921
I 'd like to have a matrix or arrays like this, I am not sure that I can do this.
M=[1, y, 1, 1, 6, 185, 0.196002 ;
2, y, 1, 1, 9, 3047, 0.242096;
3, y, 1, 1 ,10, 2761, 0.334921]
Actually I want to store string y as a decision variable name,and i,j,k,t as indices and decision variable value. When I store these data in arrays, I will rank them according to the decision variable values. Lastly, I will add the highest decision variable as additional constraint to my original model.
Thanks for your help.
#CPLEXOptimizers#DecisionOptimization