Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions highs/interfaces/Highs/Enums/BasisStatus.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
namespace Highs.Enums;

/// <summary>
/// This defines the status of a variable (or slack variable for a constraint) in a basis
/// </summary>
public enum BasisStatus
{
/// <summary>
/// The variable is nonbasic at its lower bound (or fixed value)
/// </summary>
Lower = 0,
/// <summary>
/// The variable is basic
/// </summary>
Basic,
/// <summary>
/// he variable is at its upper bound
/// </summary>
Upper,
/// <summary>
/// A free variable is nonbasic and set to zero
/// </summary>
Zero,
/// <summary>
/// The variable is nonbasic
/// </summary>
Nonbasic
}
16 changes: 16 additions & 0 deletions highs/interfaces/Highs/Enums/HessianFormat.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
namespace Highs.Enums;

/// <summary>
/// The format in which the Hessian is stored
/// </summary>
public enum HessianFormat
{
/// <summary>
/// Store the Hessian in triangular format
/// </summary>
Triangular = 1,
/// <summary>
/// Store the Hessian in square format
/// </summary>
Square
}
20 changes: 20 additions & 0 deletions highs/interfaces/Highs/Enums/HighsStatus.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
namespace Highs.Enums;

/// <summary>
/// This is (part of) the return value of most HiGHS methods
/// </summary>
public enum HighsStatus
{
/// <summary>
/// The method has exposed an error
/// </summary>
Error = -1,
/// <summary>
/// The method has completed successfully
/// </summary>
Ok,
/// <summary>
/// The method has recovered from an unusual event, or has terminated due to reaching a time or iteration limit
/// </summary>
Warning
}
16 changes: 16 additions & 0 deletions highs/interfaces/Highs/Enums/MatrixFormat.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
namespace Highs.Enums;

/// <summary>
/// This defines the format of a HighsSparseMatrix
/// </summary>
public enum MatrixFormat
{
/// <summary>
/// The matrix is stored column-wise
/// </summary>
ColumnWise = 1,
/// <summary>
/// The matrix is stored row-wise
/// </summary>
RowWise
}
75 changes: 75 additions & 0 deletions highs/interfaces/Highs/Enums/ModelStatus.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
namespace Highs.Enums;

/// <summary>
/// This defines the status of the model after a call to run
/// </summary>
public enum ModelStatus
{
/// <summary>
/// The model status has not been set
/// </summary>
Notset = 0,
LoadError,
/// <summary>
/// There is an error in the model
/// </summary>
ModelError,
PresolveError,
/// <summary>
/// There has been an error when solving the model
/// </summary>
SolveError,
PostsolveError,
/// <summary>
/// The model is empty
/// </summary>
ModelEmpty,
/// <summary>
/// The model has been solved to optimality
/// </summary>
Optimal,
/// <summary>
/// The model is infeasible
/// </summary>
Infeasible,
/// <summary>
/// The model is unbounded or infeasible
/// </summary>
UnboundedOrInfeasible,
/// <summary>
/// The model is unbounded
/// </summary>
Unbounded,
/// <summary>
/// The bound on the model objective value has been reached
/// </summary>
ObjectiveBound,
/// <summary>
/// The target value for the model objective has been reached
/// </summary>
ObjectiveTarget,
/// <summary>
/// The run time limit has been reached
/// </summary>
TimeLimit,
/// <summary>
/// The iteration limit has been reached
/// </summary>
IterationLimit,
/// <summary>
/// The model status is unknown
/// </summary>
Unknown,
/// <summary>
/// The MIP solver has reached the limit on the number of LPs solved
/// </summary>
SolutionLimit,
/// <summary>
/// The solver has been interrupted by the user
/// </summary>
Interrupt,
/// <summary>
/// The solver has been unable to allocate sufficient memory
/// </summary>
MemoryLimit
}
16 changes: 16 additions & 0 deletions highs/interfaces/Highs/Enums/ObjectiveSense.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
namespace Highs.Enums;

/// <summary>
/// This defines optimization sense of a HighsLp
/// </summary>
public enum ObjectiveSense
{
/// <summary>
/// The objective is to be minimized
/// </summary>
Minimize = 1,
/// <summary>
/// The objective is to be maximized
/// </summary>
Maximize = -1
}
28 changes: 28 additions & 0 deletions highs/interfaces/Highs/Enums/VariableType.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
namespace Highs.Enums;

/// <summary>
/// This defines the feasible values of a variable within a model
/// </summary>
public enum VariableType
{
/// <summary>
/// The variable can take continuous values between its bounds
/// </summary>
Continuous = 0,
/// <summary>
/// The variable must take integer values between its bounds
/// </summary>
Integer,
/// <summary>
/// The variable must be zero or take continuous values between its bounds
/// </summary>
SemiContinuous,
/// <summary>
/// The variable must be zero or take integer values between its bounds
/// </summary>
SemiInteger,
/// <summary>
/// The variable must take implicit integer values between its bounds
/// </summary>
ImplicitInteger,
}
9 changes: 9 additions & 0 deletions highs/interfaces/Highs/Highs.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net9.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>

</Project>
25 changes: 25 additions & 0 deletions highs/interfaces/Highs/Highs.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.14.36811.4 d17.14
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Highs", "Highs.csproj", "{5BEA6A69-23A3-426C-A849-3B9A9A8D518A}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{5BEA6A69-23A3-426C-A849-3B9A9A8D518A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{5BEA6A69-23A3-426C-A849-3B9A9A8D518A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{5BEA6A69-23A3-426C-A849-3B9A9A8D518A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{5BEA6A69-23A3-426C-A849-3B9A9A8D518A}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {F1C5253E-03B0-407C-B6C6-27C74E5FDF9F}
EndGlobalSection
EndGlobal
Loading
Loading