GithubHelp home page GithubHelp logo

yepengding / kiwami Goto Github PK

View Code? Open in Web Editor NEW
2.0 2.0 0.0 93 KB

A generic bounded model checker.

License: MIT License

Java 100.00%
bounded-model-checking ctl kripke-structure ltl minimization model-checking modeling-language formal-methods

kiwami's Introduction

Kiwami

A generic bounded model checker.

Kiwami accepts a Kripke structure, a temporal property, and a bound as inputs and either produces a counterexample violating the property or a satisfaction claim under the bound.

It encodes the given structure and property into SMT formulas backed by a solver.

Feature

  • Modeling language
  • In-memory structure / property specification
  • Structure checking
  • Termination / Maximal step calculation
  • Structure minimization
  • Encode Kripke structure
  • Generate SMT-LIB programs
  • LTL model checking
  • CTL model checking
  • Property simplification
  • Z3 Theorem Prover backend

The current version uses the existential model checking technique to check properties by searching a witness trace satisfying their negation release positive normal form.

Example

Extension

  • .lts: model program
  • .smt2: generated SMT program
  • .out: solver output

Input & Output

Input: MutualExclusion.lts

model MutualExclusion {
    s0: {}
    s1: {critical0}
    s2: {critical1}
    s3: {critical0, critical1}

    init = s0

    s0 -> s1
    s1 -> s0
    s0 -> s2
    s2 -> s0

    ltl G !(critical0 and critical1)
}

Output:

Unsatisfied under bound 2:
□(¬((critical0) ∧ (critical1)))
with a counterexample:
s0 ()
s2 (critical1)
s3 (critical1, critical0)

Test Cases

It is recommended to experience the in-development version by running test cases in LTLCheckerTest. LTLCheckerTest accepts a sample structure and LTL property, automatically generates, executes an SMT-LIB program by Z3 Theorem Solver, and parses the output.

Build

Environment

  • Java 17
  • Maven 3.6+
  • Z3 Theorem Prover 4+

Maven

mvn clean compile assembly:single

References

  • Biere, A., Cimatti, A., Clarke, E. M., Strichman, O., & Zhu, Y. (2003). Bounded model checking.
  • Clarke, E., Biere, A., Raimi, R., & Zhu, Y. (2001). Bounded model checking using satisfiability solving. Formal methods in system design, 19(1), 7-34.
  • Z3 Theorem Prover

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.