ahmad alanaqreh

First Question
First Comment
  • Total activity 41
  • Last activity
  • Member since
  • Following 0 users
  • Followed by 0 users
  • Votes 7
  • Subscriptions 11

Posts

Recent activity by ahmad alanaqreh Recent activity Votes
  • The bounds of the variables

    Answered

    I have a model where I define three variables as follows : alpha[a] = model.addVar(lb=-GRB.INFINITY, name="alpha%d" % a)beta[i, j] = model.addVar(lb=-GRB.INFINITY, ub=0, name="beta%d,%d," % (i, j))...

  • change the coefficient of the variables in the objective function

    Not planned

    I have a model that I am solving with callback, I need to change the coefficients of the variables in the objective function from time to time, I have seen the Model.chgCoeff() to change the coeffi...

  • Improve performance of constraint-adding in Gurobi Python

    Completed

    In the model I am working on I have to add constraints, the constraints based on the edges of a graph, I have the decision variable  x = {}for (i, j) in E: x[i, j] = model.addVar(vtype=GRB.BINAR...

  • Sort Decision variables' value in Gurobi Python

    Answered

    I have a decision variables list as follows : vars=[ <gurobi.Var x1,5,>, <gurobi.Var x5,1,>, <gurobi.Var x1,22,>, <gurobi.Var x22,1,>] if I want to sort the elements based on the indices of each va...

  • callback with variables based on the edges of a graph

    Answered

    Hi  I have a callback to solve a graph problem, the variable in my model is x[i,j] where (i,j) is an edge in the input graph, now the edges of the graph are defined as follow: E = gp.tuplelist([(2,...

  • infeasible model om gurobi python while it is feasible on AMPL

    Not planned

    I have the following model and if I try to optimize it on python by using gurobi solver it is infeasible while the model is feasible and the output is -2 on AMPL by using gurobi solver !!  \ LP for...

  • how to get the variable values by indices

    Answered

    I have a list containing the values of the variable as follows: [<gurobi.Var x1,2,>, <gurobi.Var x2,1,>, <gurobi.Var x10,16,>, <gurobi.Var x16,10,>, <gurobi.Var x18,24,>, <gurobi.Var x24,18,>] wher...

  • get the variable value from list

    Answered

    I am using call back to solve an LP , when the where value is simplex I am saving the values of a variable  in a list called "variables"  and send it to a function as follows: if where == GRB.Callb...

  • FarkasDual and FarkasProof

    Answered

    I am trying to apply benders decomposition for a specific problem, I have to add a cut constraint in each iteration, if the subproblem feasible I am adding an optimality cut by using Pi values of t...

  • difference between python gurobi and AMPL gurobi

    Answered

    I have a minimization model as follow :   \ LP format - for model browsing. Use MPS format to capture full model detail.Minimize Z + 0 y6 + 0 y17 + 0 y25 + 0 y32 + 0 y37Subject To cut1: - Z - y1 -...