Decision Optimization

Decision Optimization

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


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
  • 1.  How to reduce the computing time?

    Posted 05/04/16 10:28 PM

    Originally posted by: DeyeTao


    I wrote a model which is a little complex. It  has about x*k*580 variables where x presents the traffic number which I hope it can vary from 1 to 10 more or less, and k denotes the number of paths which can equal to 2 or 3.

    The problem is that when I choose k=2 and x =4, the ILP model can be optimized while when I increase the x or k, the answer cannot be found in reasonable time.

    The model cannot be changed but I think I can change some constraint forms.

    So I wonder what is the relation between elapsed time of ILP model and the variables or number of constraints? In which way I can simplify my codes?Or how to set certain parameters to solve the problems efficiently?


    #CPOptimizer
    #DecisionOptimization


  • 2.  Re: How to reduce the computing time?

    Posted 05/06/16 04:58 AM

    Originally posted by: Petr Vilím


    Hello,

    since you mention ILP it seems to me that you're probably using CPLEX engine and not CP Optimizer. In that case please post your question on the CPLEX forum.

    You also didn't describe your model very well. What is the model about? What constraint forms you can change? Could you give use the model? I'm afraid that without details we cannot help you.

    Best regards, Petr


    #CPOptimizer
    #DecisionOptimization


  • 3.  Re: How to reduce the computing time?

    Posted 05/06/16 08:27 AM

    Originally posted by: DeyeTao


    Thank you  very much.

    You are just right. I used the CPLEX to solve the ILP problem. I am sorry to post my question on the wrong forum.

    But I wanna to further describe my model. It aims to solve the routing and spectrum allocation problem in a network. Given a network graph with N nodes and E edges, as well as some traffic demand with respective bandwidth demand and certain destination. Now we need to compute the path to the destination node and allocate the spectrum to each path to satisfy the requirement. Of course, my model includes some more complex conditions, but the crucial point is that I wrote above. So on each link, we should allocate some spectrum for each traffic, which should subject to spectrum continuity meaning spectrum allocated continuous,  for example 1..3. To compute the path from source node to destination node, the nodes should subject to flow constraint meaning for each node, the input flow must equal to the output flow except for the source node and destination node. There are also some other constraints and I just not list each of them here.

    I do not know whether I describe the question well. I wonder whether the running time of the software is relative to the number of variables and number of constraints? And if I use more constraints to limit the variables, the time would be decreased or increased? I mean which is better, the constraints is strict or loose?

    Thank you very much again! 


    #CPOptimizer
    #DecisionOptimization


  • 4.  Re: How to reduce the computing time?

    Posted 05/06/16 09:45 AM

    Originally posted by: Petr Vilím


    Hello,

    it is much more clear now, but please post your question to CPLEX forum. CPLEX experts are monitoring that forum and they could help you much better than me.

    Just one comment which applies to both CPLEX and CP Optimizer (and in fact to any other similar software). We are dealing with NP problems, so the only guarantee we can make is exponential time. The software though uses a number of clever tricks to get that time down, and so in many practical cases the solve time is much better (especially if you're not looking for truly optimal solution).

    Sometimes a large problem with many variables and my constraints is solved quickly, while another small problem with few variables and few constraints is not solved at all. So there is no clear answer to your question. Sometimes fewer variables lead to faster solve, sometimes the opposite. The same with number of constraint, or "strict" versus "loose" (whatever you really meant by that).

    With practice and expertise you can learn when it is better to model the problem this way, and when the other way. And still it is often not clear what is the best way and one needs to experiment and compare the models to find it out.

    Best regards, Petr


    #CPOptimizer
    #DecisionOptimization


  • 5.  Re: How to reduce the computing time?

    Posted 05/07/16 07:27 AM

    Originally posted by: DeyeTao


    Thank you very much! My English skill is not good ~ but I am so happy you can get my point and give the answer~


    #CPOptimizer
    #DecisionOptimization