Originally posted by: John Cui
>What do each of these function do?
cplexlink122 will call CPLEX to solve your problem.
Cplex.subasgn will be called when you set some fields to Cplex.Model,
Cplex.subsref will be called when you want to get some fields of Cplex.Model.
>Do any of these functions call each other?
NO.
>Are these functions called each time I change of the parameters on a Cplex() pointer? (i.e. c = Cplex, c.Model.a(1) = 1)
cplex.subasgn will be called.
>c = Cplex()
>Model = struct()
>%specify Model.obj, Model.A, Model.lhs, Model.rhs, Model.ub, Model. lb, in MATLAB
>c.Model = Model
>Would the code above be functional?
Sure, it works.
You can construct the Model structure without Cplex, then set Cplex.Model by Model structure. It is faster.
But the fastest way is use toolbox functions instead of Cplex class. You can take a look cplexmilpex.m example.
John Cui
#CPLEXOptimizers#DecisionOptimization