The simulation study benchmark to support the research work Modularized Control Synthesis for Complex Signal Temporal Logic Specifications.
This benchmark considers a mobile robot required to perform a monitoring task in a rectangular space SAFETY sized
- Starting from position
$(0,5)$ , the robot should frequently visit TARGET every$5$ steps or fewer until$k=40$ . - From
$k=15$ to$k=45$ , once the robot leaves HOME, it should get back to HOME within$5$ time steps. - After
$k = 20$ and before$k = 45$ , it should stay in CHANGER continuously for at least$3$ time steps to charge. - The robot should always stay in the SAFETY region.
This benchmark aims at splitting the overall specification in time, generating local specifications with separate time intervals
The following figure shows the trajectories of the agent in different stages.
Operating system
- Windows (compatible in general, succeed on 11)
- Linux (compatible in general, succeed on 20.04)
- MacOS (compatible in general, succeed on 13.4.1)
Python Environment
- Python
3.11
- Required Packages:
numpy
,treelib
,matplotlib
.
Required Libraries
gurobipy
solver (license required, see How to Get a Gurobi License)stlpy
toolbox (see Documentation or GitHub repository)
-
Install conda following this instruction;
-
Open the conda shell, and create an independent project environment;
conda create --name modustl python=3.11
- In the same shell, activate the created environment
conda activate modustl
- In the same shell, within the
modustl
environment, install the dependencies one by one
conda install -c anaconda numpy
conda install -c conda-forge treelib
conda install -c conda-forge matplotlib
- In the same shell, within the
modustl
environment, install the libraries
python -m pip install gurobipy
pip install stlpy
- Last but not least, activate the
gurobi
license (See How To). Note that this project is compatible withgurobi
Released version11.0.1
. Keep yourgurobi
updated in case of incompatibility.
- Run the main script
main.py
; - Plotted figures automatically saved in the root folder.
This project is with a BSD-3 license, refer to LICENSE
for details.