Decision Optimization

Decision Optimization

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


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
  • 1.  Worst Fit

    Posted 02/23/14 02:33 PM

    Originally posted by: Kaouthar


    Hi, I'm still a beginner in Cplex, that's why I need your help to solve my problem.

    In fact, I have requests that will be assigned to resources with different abilities. Each request must be assigned to the resource with the largest spare capacity.

    I started with the following model that allocates requests to any resource and I thought later to use a boolean variable that will decide what is the resource that has the largest capacity.
    But frankly, I have not arrived to a solution.

    Thnaks in advance.

    /*Model*/

    maximize Accept_rate ;

    subject to {
         
          forall (i in TaskIds)
         sum (k in RequestSite[i],j in RequestMachine[k][i]) x[k][j][i] <= 1;
         
         
          forall(k in  SiteIds ){
        forall(j in  RsrcIds[k])
            sum(t  in Requests)
               t.dmds*x[k][j][t.id-1]<=Capacity[k][j];}
                 
               forall(k in  SiteIds){
        forall(j in  RsrcIds[k])
            sum(t  in Requests)
               t.bw*x[k][j][t.id-1]<=BW[k][j];}
               
           
    }

    Where Accept rateis the amount of the accepted request and X[k][j][i]  is a boolean variable that take 1 if the request i is assigned to the resource j in the site k.

    BW and Capacity are respectively the bandwidth and the capacity of each resource.

    t.dmds and t.bw are respectively are respectively the bandwidth and the capacity of each request.


    #CPLEXOptimizers
    #DecisionOptimization