Creating the environment

Creating the environment

The first executable statement in our example obtains a Gurobi environment (using the GRBEnv() constructor):

  GRBEnv env = GRBEnv();
Later calls to create an optimization model will always require an environment, so environment creation is typically the first step in a Gurobi application.