Originally posted by: Perth2
I am using CPLEX to construct an IloLPMatrix object in Java in a column generation setting. Firstly, I am initializing all rows one by one. Each row is created by first creating an IloLinearNumExpr with the cplex.linearNumExpr() call, then creating a range based on this IloLinearNumExpr with a call to e. g. cplex.addEq(iloNumExpr, value, name). The resulting range is then added to my IloLpMatrix object by a call to lpMatrix.addRow(range). I have about 70.000 of rows, and depending on the hardware, the initial construction takes up to several minutes. This seems to me to be a very long time. Running a performance profiler, I can see that ilog.cplex.Cplex.CPXGetRows[native] is where much of the time is spent. Is there an explanation to this? Is there a way to construct/populate the IloLPMatrix object that circumvents the (as it looks) repeated calls to CPXGetRows? Or is it something else that is causing the calls to CPXGetRows?
#CPLEXOptimizers#DecisionOptimization