Research-focused implementation of nonlinear control systems featuring backstepping, sliding mode control, and feedback linearization methods.
WARNING: This software is for research and educational purposes only. Do not use on real hardware without expert review and proper safety measures. This implementation lacks safety-critical features required for real-world deployment.
- Multiple Control Methods: Backstepping, Sliding Mode Control, Feedback Linearization
- Comprehensive Evaluation: RMSE, settling time, control effort, stability analysis
- Interactive Demos: Streamlit-based visualization and parameter tuning
- Modern Architecture: Type hints, comprehensive testing, CI/CD pipeline
- Research Ready: Deterministic seeding, reproducible results, detailed metrics
# Clone the repository
git clone https://github.com/kryptologyst/Nonlinear-Control-Systems.git
cd Nonlinear-Control-Systems
# Install dependencies
pip install -e .
# For development
pip install -e ".[dev]"from src.controllers import BacksteppingController
from src.simulation import NonlinearSystemSimulator
from src.evaluation import ControlEvaluator
# Create controller
controller = BacksteppingController(
desired_position=1.0,
desired_velocity=0.0,
alpha=2.0,
beta=1.5
)
# Run simulation
simulator = NonlinearSystemSimulator()
results = simulator.run(controller, duration=10.0, dt=0.01)
# Evaluate performance
evaluator = ControlEvaluator()
metrics = evaluator.evaluate(results)
print(f"RMSE: {metrics.rmse:.4f}")
print(f"Settling Time: {metrics.settling_time:.2f}s")streamlit run demo/app.pysrc/
├── controllers/ # Control algorithms
│ ├── backstepping.py # Backstepping control
│ ├── sliding_mode.py # Sliding mode control
│ └── feedback_linearization.py
├── systems/ # System dynamics
│ ├── nonlinear.py # Nonlinear system models
│ └── benchmarks.py # Benchmark systems
├── simulation/ # Simulation framework
│ ├── simulator.py # Main simulator
│ └── integrators.py # Numerical integration
├── evaluation/ # Performance evaluation
│ ├── metrics.py # Control metrics
│ └── evaluator.py # Evaluation framework
└── utils/ # Utilities
├── seeding.py # Deterministic seeding
└── visualization.py # Plotting utilities
config/ # Configuration files
├── controllers.yaml # Controller parameters
└── systems.yaml # System parameters
tests/ # Unit tests
demo/ # Interactive demos
assets/ # Generated plots and videos
Recursive design method for nonlinear systems with strict feedback form.
Robust control method using discontinuous control laws.
Transforms nonlinear systems to linear systems through coordinate transformations.
- Tracking Performance: RMSE, MAE, maximum error
- Transient Response: Settling time, overshoot, rise time
- Control Effort: Total control energy, control smoothness
- Stability: Lyapunov analysis, stability margins
The project uses Hydra for configuration management. Key parameters can be adjusted in config/:
# config/controllers.yaml
backstepping:
alpha: 2.0
beta: 1.5
sliding_mode:
lambda: 1.0
eta: 0.5pytest tests/black src/ tests/
ruff check src/ tests/mypy src/- All simulations run in software only
- No real-time constraints or hardware interfaces
- Control gains are tuned for simulation stability
- Emergency stop mechanisms are not implemented
- Fork the repository
- Create a feature branch
- Add tests for new functionality
- Ensure all tests pass
- Submit a pull request
MIT License - see LICENSE file for details.
If you use this code in your research, please cite:
@software{nonlinear_control_systems,
title={Nonlinear Control Systems: A Modern Implementation},
author={Kryptologyst},
year={2026},
url={https://github.com/kryptologyst/Nonlinear-Control-Systems}
}