Originally posted by: ZacS
Hi there,
I am a total beginner to CPLEX studio and will appreciate some help :) Currently trying to use it to solve an LP problem, and I'm having difficulties defining parameters when there are multiple indexes.
For example, if I have 5 scenarios (q=1,2,3,4,5), and probabilities for each of these scenarios, I will simply write:
range q=1..5;
float prob[q]=...;
and perform a connection to an excel sheet with a column for q values (1,2,3,4,5) and a column for probability values.
The above example is where I have parameters of the form X_i. However, I am not sure how I can do the same for parameters of the form X_ij.
For example, if in addition to q, I have another index j with values 1,2 or 3, so in my excel file, I will have a column for q, a column for j and a column for probability. Now I am trying to define parameters to get values for
prob_qj i.e. q_11, q_12, q_13, q_21, q_22 etc.
range q=1..5;
range i=1..7;
float prob[q][i]=...;???
I am not sure how I can proceed above, and will appreciate if anyone has any suggestions. Thank you!
Regards,
Zac
#DecisionOptimization#OPLusingCPLEXOptimizer