Thanks to visit codestin.com
Credit goes to github.com

Skip to content

nanli42/MIP_in_NMPC

Repository files navigation

MIP-based method for overtaking maneuvers

Statement of purpose

Code for MIP (Mixed-Integer Programming)-based method for autonomous vehicles racing problem in head-to-head competition mode. Vehicle model: F1tenth race car. Base framework: a time-optimal NMPC framework, generated by ACADO Toolkit.

Dependencies

Eigen (used for linear algebra: matrices, vectors, etc)

Json (used for loading track information and other parameters)

MPCC (some pieces of code are borrowed for Spline fitting of track, related code copied in the folder "external")

ACADO (used for dynamicly linearizing and evaluating MPC problem, generated files and original source file are included in the folder "external")

qpOASES (used as QP solver, source codes are included in the folder "external")

GUROBI (used as a MIQP solver for MIP method, header file is included in the folder "external")

matplotlibcpp (used for plotting, header file is included in the folder "external")

Usage

We specify the prediction horizon length as arg1 and track as arg2, then we use a script for code generation:

# code generation and compilation
cd [this project]
mkdir build
cd build
cmake ..
bash ../config_param.sh arg1 arg2

# enter cmd line interface to test a specific scenario
./main

# or directly provide arguments in one cmd: 
# ./main s0 s0_LV total_steps ey0 epsi0 vx0 vy0 w0 d0 delta0 data_logging_file
./main 0. 0.1 146 0 0 1. 0 0 0 0 path_to_data_logging_file

# or execute batch tasks
bash ../exe_batch_N15_track1.sh

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages