This document is made for anyone who wants to learn constraint programming using using Mini-CP as a support.

This tutorial will continuously evolve. Don’t hesitate to give us feedback or suggestion for improvement. You are also welcome to report any mistake or bug.

What is Mini-CP

The success the MiniSAT solver has largely contributed to the dissemination of (CDCL) SAT solvers. The MiniSAT solver has a neat and minimalist architecture that is well documented. We believe the CP community is currently missing such a solver that would permit new-comers to demystify the internals of CP technology. We introduce Mini-CP a white-box bottom-up teaching framework for CP implemented in Java. Mini-CP is voluntarily missing many features that you would find in a commercial or complete open-source solver. The implementation, although inspired by state-of-the-art solvers is not focused on efficiency but rather on readability to convey the concepts as clearly as possible. Mini-CP is small and well tested.


The Javadoc API.

Install Mini-CP

Mini-CP source-code is available from bitbucket.

Using an IDE

We recommend using IntelliJ or Eclipse.

From IntelliJ you can simply import the project.

Open > (select pom.xml in the minicp directory and open as new project)

From Eclipse you can simply import the project.

Import > Maven > Existing Maven Projects (select minicp directory)

From the command line

Using maven command line you can do you can do:

$mvn compile # compile all the project
$mvn test    # run all the test suite

Some other useful commands

$mvn checkstyle:checktyle   # generates a report in target/site/checkstyle.html
$mvn findbugs:gui           # opens a gui with potential source of bugs in your code
$mvn jacoco:report          # creates a cover report in target/site/jacoco/index.html
$mvn javadoc:javadoc        # creates javadoc in target/site/apidocs/index.html

Getting Help with Mini-CP

You’ll get greatest chance of getting answers to your questions using the Mini-CP usergroup.

Who uses Mini-CP

If you use it for teaching or for research, please let-us know and we will add you in this list.

  • UCLouvain, INGI2365 Teacher: Pierre Schaus.
  • ACP, Summer School 2017, Porquerolles, France, Teacher: Pierre Schaus.
  • Université de Nice Master in CS Teacher: Arnaud Malapert and Marie Pelleau

Citing Mini-CP

If you use find Mini-CP useful for your research or teaching you can cite:

  author = "{Laurent Michel, Pierre Schaus, Pascal Van Hentenryck}",
  title = "{MiniCP}: A Lightweight Solver for Constraint Programming",
  year = {2018},
  note = {Available from \texttt{}},