Decision Optimization

Decision Optimization

Delivers prescriptive analytics capabilities and decision intelligence to improve decision-making.


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
  • 1.  No solution with piecewise linear function

    Posted 09/27/15 02:23 AM

    Originally posted by: ZhangShixuan


    Hi,

    I ran into a problem modelling with Cplex 12.6.1, using concert technology with VS2010. I was modelling a network which cplex failed to optimize, so I started debugging by deleting all the constraints and adding them again one by one to make sure every of them works well. Everything was good until I added a constraint with IloPiecewise function:

    model.add(IloPiecewiseLinear(I[i][j], -IloInfinity, ILog.PointArray, ILog.ValueArray, IloInfinity) == 
                      2 * IloPiecewiseLinear(q[i][j], -IloInfinity, qLog.PointArray, qLog.ValueArray, IloInfinity) -
                      IloPiecewiseLinear(p_t[i][p_out[j]], -IloInfinity, ptLog.PointArray, ptLog.ValueArray, IloInfinity) + 
                      IloLog(ConstI[j]));
    

    where i, j are simply the array indices and the variables I, q, p_t are already bound by their range constraints. ILog, qLog and ptLog are the classes providing the necessary points and values for these piecewise linear functions. The error message said that 'no solution exists' and the status was also 'infeasible'. Moreover, there was a warning "Bound infeasibility column: p_t[0](1)" (a variable on the rhs of this piecewise linear constraint). However, if I use the interactive optimizer with .sav file, I got the solution successfully as I had expected because those variables were actually not bound by any other constraint than this one and the range.

    Therefore, I am now extremely puzzled by the different results brought by the C++ api and interactive optimizer. I would appreciate it very much if anyone could give some idea of this problem. Thanks a lot!


    #CPLEXOptimizers
    #DecisionOptimization


  • 2.  Re: No solution with piecewise linear function

    Posted 10/15/15 09:01 AM

    This indeed looks odd. Could you export your model to XML (see here) and attach that XML file here?


    #CPLEXOptimizers
    #DecisionOptimization


  • 3.  Re: No solution with piecewise linear function

    Posted 10/15/15 09:54 AM

    Originally posted by: ZhangShixuan


    Thank you very much for your attention. But I'm sorry that since this problem happened so long ago, I already did modification to my program structure to circumvent this problem, which was adding artificial variables for errors into the constraints. So I guess now I could not give you the exact model in which this problem took place.
     


    #CPLEXOptimizers
    #DecisionOptimization


  • 4.  Re: No solution with piecewise linear function

    Posted 10/19/15 01:16 AM

    OK, no problem. Glad you found a way to work around the problem.


    #CPLEXOptimizers
    #DecisionOptimization