Multiplication of multiple variables

Comments

1 comment

  • Tobias Achterberg

    Gurobi only supports products of pairs of variables, not triples. To overcome this issue, you need to introduce auxiliary variables and build the more complex expression using those. For example, in order to model

    y = x1*x2*x3

    you could write

    z12 = x1*x2
    y = z12*x3

    For binary variables, this should just work out of the box. For non-binary variables, this is only supported since Gurobi 9.0, and only if you set the "NonConvex" parameter to 2.

    Regards,

    Tobias

     

    0
    Comment actions Permalink

Please sign in to leave a comment.

Powered by Zendesk