Show / Hide Table of Contents

    Class GurobiDllWrapper

    The gurobi dll wrapper.

    Inheritance
    System.Object
    GurobiDllWrapper
    Inherited Members
    System.Object.ToString()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    Namespace: OPTANO.Modeling.Optimization.Solver.Gurobi652
    Assembly: Optimization.Solver.Gurobi652.dll
    Syntax
    public class GurobiDllWrapper

    Methods

    GRBaddconstrs(IntPtr, Int32, Int32, Int32[], Int32[], Double[], Char[], Double[], String[])

    The gr baddconstrs.

    Declaration
    public static int GRBaddconstrs(IntPtr model, int numconstrs, int nz, int[] Cbeg, int[] Cind, double[] Cval, char[] sense, double[] rhs, string[] Cname)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.Int32 numconstrs

    The numconstrs.

    System.Int32 nz

    The nz.

    System.Int32[] Cbeg

    The cbeg.

    System.Int32[] Cind

    The cind.

    System.Double[] Cval

    The cval.

    System.Char[] sense

    The sense.

    System.Double[] rhs

    The rhs.

    System.String[] Cname

    The cname.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBaddrangeconstrs(IntPtr, Int32, Int32, Int32[], Int32[], Double[], Double[], Double[], String[])

    The gr baddrangeconstrs.

    Declaration
    public static int GRBaddrangeconstrs(IntPtr model, int numconstrs, int nz, int[] Cbeg, int[] Cind, double[] Cval, double[] lhs, double[] rhs, string[] Cname)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.Int32 numconstrs

    The numconstrs.

    System.Int32 nz

    The nz.

    System.Int32[] Cbeg

    The cbeg.

    System.Int32[] Cind

    The cind.

    System.Double[] Cval

    The cval.

    System.Double[] lhs

    The lhs.

    System.Double[] rhs

    The rhs.

    System.String[] Cname

    The cname.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBaddsos(IntPtr, Int32, Int32, Int32[], Int32[], Int32[], Double[])

    The gr baddsos.

    Declaration
    public static int GRBaddsos(IntPtr model, int numsos, int nummembers, int[] SOStype, int[] SOSbeg, int[] SOSind, double[] SOSweight)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.Int32 numsos

    The numsos.

    System.Int32 nummembers

    The nummembers.

    System.Int32[] SOStype

    The so stype.

    System.Int32[] SOSbeg

    The so sbeg.

    System.Int32[] SOSind

    The so sind.

    System.Double[] SOSweight

    The so sweight.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBaddvar(IntPtr, Int32, Int32[], Double[], Double, Double, Double, Char, String)

    The gr baddvar.

    Declaration
    public static int GRBaddvar(IntPtr model, int nz, int[] Vind, double[] Vval, double obj, double lb, double ub, char vtype, string Rname)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.Int32 nz

    The nz.

    System.Int32[] Vind

    The vind.

    System.Double[] Vval

    The vval.

    System.Double obj

    The obj.

    System.Double lb

    The lb.

    System.Double ub

    The ub.

    System.Char vtype

    The vtype.

    System.String Rname

    The rname.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBaddvars(IntPtr, Int32, Int32, Int32[], Int32[], Double[], Double[], Double[], Double[], Char[], String[])

    The gr baddvars.

    Declaration
    public static int GRBaddvars(IntPtr model, int numvars, int nz, int[] Vbeg, int[] Vind, double[] Vval, double[] obj, double[] lb, double[] ub, char[] Vtype, string[] Vname)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.Int32 numvars

    The numvars.

    System.Int32 nz

    The nz.

    System.Int32[] Vbeg

    The vbeg.

    System.Int32[] Vind

    The vind.

    System.Double[] Vval

    The vval.

    System.Double[] obj

    The obj.

    System.Double[] lb

    The lb.

    System.Double[] ub

    The ub.

    System.Char[] Vtype

    The vtype.

    System.String[] Vname

    The vname.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBclean2(ref Int32, Int32[], Double[])

    Normalizes a linear expression.

    Declaration
    public static int GRBclean2(ref int len, int[] ind, double[] val)
    Parameters
    Type Name Description
    System.Int32 len

    The number of Terms in the linear expression that should be cleaned. (I.e. ind.Length) ref updates the len to the resulting number of Terms in the expression. Educated guess: ind and val will be filled from position 0 to len-1.

    System.Int32[] ind

    The variable in every Term. Needs to be in the same order as val.

    System.Double[] val

    The factor for every Term. Needs to be in the same order as ind.

    Returns
    Type Description
    System.Int32

    The error code. 0, if no error occurred.

    GRBdelq(IntPtr)

    The gr bdelq.

    Declaration
    public static int GRBdelq(IntPtr model)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBfreemodel(IntPtr)

    The gr bfreemodel.

    Declaration
    public static int GRBfreemodel(IntPtr model)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBgetdblattr(IntPtr, String, out Double)

    The gr bgetdblattr.

    Declaration
    public static int GRBgetdblattr(IntPtr model, string attrname, out double value)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.String attrname

    The attrname.

    System.Double value

    The value.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBgetdblattrelement(IntPtr, String, Int32, out Double)

    The gr bgetdblattrelement.

    Declaration
    public static int GRBgetdblattrelement(IntPtr model, string attrname, int element, out double value)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.String attrname

    The attrname.

    System.Int32 element

    The element.

    System.Double value

    The value.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBgetenv(IntPtr)

    The gr bgetenv.

    Declaration
    public static IntPtr GRBgetenv(IntPtr model)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    Returns
    Type Description
    System.IntPtr

    The System.IntPtr.

    GRBgetintattr(IntPtr, String, out Int32)

    The gr bgetintattr.

    Declaration
    public static int GRBgetintattr(IntPtr model, string attrname, out int value)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.String attrname

    The attrname.

    System.Int32 value

    The value.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBgetstrattr(IntPtr, String, out IntPtr)

    The gr bgetstrattr.

    Declaration
    public static int GRBgetstrattr(IntPtr model, string attrname, out IntPtr value)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.String attrname

    The attrname.

    System.IntPtr value

    The value.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBgetstrattrelement(IntPtr, String, Int32, out IntPtr)

    The gr bgetstrattrelement.

    Declaration
    public static int GRBgetstrattrelement(IntPtr model, string attrname, int element, out IntPtr value)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.String attrname

    The attrname.

    System.Int32 element

    The element.

    System.IntPtr value

    The value.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBloadenv(out IntPtr, String)

    The gr bloadenv.

    Declaration
    public static int GRBloadenv(out IntPtr env, string logfilename)
    Parameters
    Type Name Description
    System.IntPtr env

    The env.

    System.String logfilename

    The logfilename.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBnewmodel(IntPtr, out IntPtr, String, Int32, Double[], Double[], Double[], Char[], String[])

    The gr bnewmodel.

    Declaration
    public static int GRBnewmodel(IntPtr env, out IntPtr model, string Pname, int numvars, double[] obj, double[] lb, double[] ub, char[] vtype, string[] varnames)
    Parameters
    Type Name Description
    System.IntPtr env

    The env.

    System.IntPtr model

    The model.

    System.String Pname

    The pname.

    System.Int32 numvars

    The numvars.

    System.Double[] obj

    The obj.

    System.Double[] lb

    The lb.

    System.Double[] ub

    The ub.

    System.Char[] vtype

    The vtype.

    System.String[] varnames

    The varnames.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBoptimize(IntPtr)

    The gr boptimize.

    Declaration
    public static int GRBoptimize(IntPtr model)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBpresolvemodel(IntPtr)

    The gr bpresolvemodel.

    Declaration
    public static IntPtr GRBpresolvemodel(IntPtr model)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    Returns
    Type Description
    System.IntPtr

    The System.IntPtr.

    GRBsetdblattr(IntPtr, String, Double)

    The gr bsetdblattr.

    Declaration
    public static int GRBsetdblattr(IntPtr model, string attrname, double value)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.String attrname

    The attrname.

    System.Double value

    The value.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBsetdblattrelement(IntPtr, String, Int32, Double)

    The gr bsetdblattrelement.

    Declaration
    public static int GRBsetdblattrelement(IntPtr model, string attrname, int element, double newvalue)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.String attrname

    The attrname.

    System.Int32 element

    The element.

    System.Double newvalue

    The newvalue.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBsetdblattrlist(IntPtr, String, Int32, Int32[], Double[])

    The gr bsetdblattrlist.

    Declaration
    public static int GRBsetdblattrlist(IntPtr model, string attrname, int len, int[] ind, double[] newvalues)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.String attrname

    The attrname.

    System.Int32 len

    The len.

    System.Int32[] ind

    The ind.

    System.Double[] newvalues

    The newvalues.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBsetintattr(IntPtr, String, Int32)

    The gr bsetintattr.

    Declaration
    public static int GRBsetintattr(IntPtr model, string attrname, int newvalue)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.String attrname

    The attrname.

    System.Int32 newvalue

    The newvalue.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBsetintattrelement(IntPtr, String, Int32, Int32)

    The gr bsetintattrelement.

    Declaration
    public static int GRBsetintattrelement(IntPtr model, string attrname, int element, int newvalue)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.String attrname

    The attrname.

    System.Int32 element

    The element.

    System.Int32 newvalue

    The newvalue.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBsetintparam(IntPtr, String, Int32)

    The gr bsetintparam.

    Declaration
    public static int GRBsetintparam(IntPtr model, string paramname, int newvalue)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.String paramname

    The paramname.

    System.Int32 newvalue

    The newvalue.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBterminate(IntPtr)

    The gr bterminate.

    Declaration
    public static void GRBterminate(IntPtr model)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    GRBupdatemodel(IntPtr)

    The gr bupdatemodel.

    Declaration
    public static int GRBupdatemodel(IntPtr model)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    GRBwrite(IntPtr, String)

    The gr bwrite.

    Declaration
    public static int GRBwrite(IntPtr model, string filename)
    Parameters
    Type Name Description
    System.IntPtr model

    The model.

    System.String filename

    The filename.

    Returns
    Type Description
    System.Int32

    The System.Int32.

    Extension Methods

    ReflectionHelper.GetFieldValue(Object, String)
    ReflectionHelper.SetFieldValue(Object, String, Object)
    ExtensionMethods.Clone<T>(T)
    ExtensionMethods.ThrowIfArgumentIsNull<T>(T, String)
    Back to top Copyright © OPTANO GmbH generated with DocFX
    Privacy Policy | Impressum – Legal Notice