|
|
dlinear
0.0.1
Delta-complete SMT solver for linear programming
|
dlinear comes with a shared C++ library that can be used to interact with the solver programmatically.
See the Installation page for instructions on how to install the library.
When including the shared library in a project, you can include the main dlinear header
and link the library with the flags -ldlinear. Add the -lgmp flag if your project needs to manipulate rational numbers.
Finally, the executable can be run with
The following example demonstrates how to use the library to check the satisfiability of a problem in SMT2 format:
The example can be compiled with
and run with
-lgmp flagIf compiling the example results in an error similar to
it is probably because you are either missing the -lgmp flag or the library is not installed on your system.
fmt of spdlog library versionIf compiling the example results in an error similar to
or
it is probably because the version of the fmt and spdlog libraries respectively are not compatible with the one used in dlinear. If you can't update the installed ones, it should be sufficient to download the header files from the fmt or spdlog repositories and include them in the project.
For example, the project structure could look like this:
and the compilation command would look like this:
SPDLOG_FMT_EXTERNAL or SPDLOG_COMPILED_LIB macrosIf compiling the example results in an error similar to
it is probably because the SPDLOG_FMT_EXTERNAL or SPDLOG_COMPILED_LIB macros are missing. Make sure to define them before including the dlinear header or in the compilation command.