Files
ortools-clone/examples/dotnet
2022-01-10 21:24:54 +01:00
..
2022-01-10 21:24:54 +01:00
2021-08-23 13:59:18 +02:00
2021-04-02 10:08:51 +02:00
2021-04-02 10:08:51 +02:00
2021-04-02 10:08:51 +02:00
2021-04-02 10:08:51 +02:00
2021-04-02 10:08:51 +02:00
2021-04-02 10:08:51 +02:00
2021-04-02 16:05:40 +02:00
2022-01-10 21:24:54 +01:00
2021-04-02 10:08:51 +02:00
2021-05-20 17:54:57 +02:00
2022-01-10 21:24:54 +01:00
2021-05-21 09:22:41 +02:00
2021-12-10 16:25:09 +01:00
2022-01-10 21:24:54 +01:00
2022-01-10 21:24:54 +01:00

.NetCoreApp examples

The following examples showcase how to use OrTools.
The project solution has examples for both C# and F#.

We recommend that all projects you create target net6.0, as this allows you to compile for various frameworks and keep up-to-date with the latest frameworks.

Wherever you have or-tools installed, be sure to PackageReference the Google.OrTools from the project file.

Execution

Running the examples will involve building them, then running them.
You can run the following command:

dotnet build <example>.csproj
dotnet run --no-build --project <example>.csproj

Note on Google.OrTools.FSharp

This part describes how to use Google.OrTools.FSharp nuget package in F#.

SolverOptions and lpSolve

This function and parameter object are a wrapper around the standard Google.OrTools functions.
It is designed to enter the Linear/Integer program as matrices and vectors.

Two input formats are allowed:

  • Canonical Form;
  • Standard Form.

ALL Matrices & Vectors are entered as columns

Execution

Running the examples will involve building them, then running them.
You can run the following command:

dotnet build <example>.fsproj
dotnet run --no-build --project <example>.fsproj