19 releases (5 breaking)

0.7.5 Feb 17, 2023
0.6.3 Dec 12, 2022
0.6.2 Nov 28, 2022

#1125 in Math

Download history 44/week @ 2024-07-07 269/week @ 2024-07-28 194/week @ 2024-09-29

194 downloads per month

LGPL-3.0-only

265KB
7K SLoC

Install

  1. Install Rust: Rust
  2. Install clang:
     xxx@XXX:~$ sudo apt install clang
    
  3. Install SMT-Language:
     xxx@XXX:~$ cargo install smt-lang
    

Run SMT-language

xxx@XXX:~$ smt-lang --file problem_file.sl

Example

Problem

let b: Bool
let i: 1..100
let r: Real

constraint C1 = (
    i >= 10
)
constraint C2 = (
    r <= 20.0 and b
)

Solve

xxx@XXX:~$ smt-lang --file example.sl

Solution

let b: Bool = true
let i: 1..100 = 10
let r: Real = 20

Options

Verbose

  • --verbose 0 : display nothing except the result
  • --verbose 1 : display analysis result
  • --verbose 2 : display loaded problem
  • --verbose 3 : display SMT problem and SMT model if a solution is found

Syntax

Dependencies

~28–43MB
~736K SLoC