ExamplesΒΆ
Here we show a range of examples utilizing PathSim to simulate different dynamical systems and how to implement them step by step, starting from the system definition.
There is an even more comprehensive collection of example dynamical system simulations availabe in the GitHub repository.
Note
Examples are available as interactive Jupyter notebooks that can be downloaded and executed directly.
Fundamental SystemsΒΆ
Basic examples demonstrating core PathSim concepts with linear and nonlinear systems.
First-order linear feedback system demonstrating basic block connections and simulation setup.
Damped spring-mass-damper system with second-order dynamics and exponential decay.
Nonlinear mathematical pendulum demonstrating the sine nonlinearity and oscillatory behavior.
Self-oscillating system with nonlinear damping, demonstrating limit cycle behavior.
Chaotic system demonstrating sensitive dependence on initial conditions and strange attractors.
Event-Driven SystemsΒΆ
Hybrid dynamical systems with discrete events and zero-crossing detection.
Classic hybrid system with zero-crossing events for bounce detection and velocity reversal.
Nonlinear pendulum with ground collisions, featuring automatic differentiation through events.
Advanced event handling with multiple events, conditional logic, and dynamic event switching.
Temperature control system with hysteresis and on-off switching events.
Friction model with stick-slip transitions demonstrating state-dependent switching.
Control SystemsΒΆ
Feedback control examples including PID controllers and cascade architectures.
Classical PID feedback control demonstrating proportional, integral, and derivative actions.
Two-loop cascade control architecture with nested PID controllers and subsystems.
Signal Processing & CommunicationsΒΆ
Examples demonstrating frequency domain analysis, filters, and signal processing systems.
Frequency-modulated continuous-wave radar system with mixing and frequency analysis.
Frequency domain analysis using the Spectrum block to recover filter frequency responses.
Linear system representation using poles and residues with complex conjugate dynamics.
Electronics & Circuit SystemsΒΆ
Analog and mixed-signal circuit simulations including ADCs, nonlinear components and RF networks.
Nonlinear diode characteristics with implicit solver for stiff circuit dynamics.
Oversampling analog-to-digital converter with noise shaping and quantization.
Successive approximation register ADC with binary search and comparator logic.
RF network with spectrum analysis. Enabled by Scikit-rf integration.
Advanced TopicsΒΆ
Complex systems featuring algebraic loops, subsystems, chemical processes, automatic differentiation, and FMU co-simulation.
Implicit system with algebraic constraints requiring iterative solvers.
Chemical reaction kinetics with temperature-dependent rates and nonlinear dynamics.
Hierarchical modeling with nested subsystems for modular system design.
Sensitivity analysis and uncertainty quantification using forward-mode automatic differentiation.
Integration of Functional Mock-up Units (FMU) as PathSim blocks using FMI standard.