Hi all!
I try to figure out how can I implement the following usecase:
Imagine, I have a simple model(just to explain). Smth like:
int a http://1..2 = 2,2;
int d http://1..2 = ...;
dvar int+ x1;
dvar int+ x2;
minimize x1+x2;
subject to{
a[1]*x1>=d[1];
a[2]*x2>=d[2];
}
And now I want to test my model for randomly generated data d has the same value all the time.
What is the easiest way to do that? Looks like the simple usecase, but I stuck here...
Actually, I generate the data in MATLAB, may I somehow implement the described above case using API for example? My real model is huge and I cannot easily find the needed data piece in the A matrix.
Thank you in advance for the help!
Topic

Re: How to restart the model with different data?
20130116T22:03:11ZThis is the accepted answer. This is the accepted answer.There are a bunch of ways to do this, but the easiest one might be a script in Matlab that calls ILOG using the oplrun command.
Something like:
 Generate the parameters
 Write a .Dat file
 Move the .Dat file into the OPL folder (use the "dos" command in Matlab)
 Execute the model (use the oplrun command)
Repeat
Use Google and the IlOG manual for the syntaxes. If something isn't clear, let me know. 
Re: How to restart the model with different data?
20130116T22:11:42ZThis is the accepted answer. This is the accepted answer.Your other post specifically mentioned .lp files. Another way to do this is to use ILOG to get a single .lp file, then use the Matlab API.
The API will create a cplex object "my_model" (you give the name, that is just an example), with the A matrix stored in my_model.A.
You can change it with simple matlab commands like my_model.A(4,10) = 1.32. Then resolve.
As for your model being huge and not being able to find what you need in the A matrix, are you searching using matlab or you just can't find it with your eyes? Use Matlab tools like find, min, max, or whatever else you need. But if you can't find what you need in the A matrix, Cplex / ILOG can't do that for you. It just solves what you give it. You have to manage the problem somehow. 
Re: How to restart the model with different data?
20130117T06:58:52ZThis is the accepted answer. This is the accepted answer.Is this the same as this question?