The Solver Option Object

The SolverOption object is an element of the SolverOptions collection and contains all the information stored about each solver option for the solver.

Properties for the SolverOption Object

Changed

True if the option has been changed. (Boolean Property - ReadOnly)

DefaultValue

The default value for the solver option. (Variant Property - Read Only)

MaxValue

The maximum value for the solver option. (Variant Property - Read Only)

MinValue

The minimum value for the solver option. (Variant Property - Read Only)

Name

The name of the solver option. (String Property - Read Only)

Type

The type of the option. (Enumerated Property - Read Only)

Value

The current value of the solver option. (Variant Property - Read/Write)

CSharp Example:


     OptiMax MPL;
     Solver cpxSolver;

     MPL = new OptiMax();

     cpxSolver = MPL.Solvers.Add("CPLEX");
     cpxSolver.Options["IterationLimit"].Value = 1000
     foreach(SolverOption solvopt in cpxSolver.Options)
        Console.WriteLine("CPXOPT:" + solvopt.Name + ":" +
                          " val=" + solvopt.Value +
                          " def=" + solvopt.DefaultValue +
                          " max=" + solvopt.MaxValue +
                          " min=" + solvopt.MinValue);


      

Methods for the SolverOption Object

SetToDefault

Sets the solver option to its default value, returns True if value changed. (Method)


Back To Top | Maximal Home Page | Table of Contents | Previous Page | Next Page