Continuous-Time Piecewise-Linear Recurrent Neural Networks

Alena Brändle, Lukas Eisenmann, Florian Götz, Daniel Durstewitz

The Challenge of Dynamical Systems Reconstruction

Dynamical Systems Reconstruction (DSR) aims to build generative models that recover the underlying rules—or "climate statistics"—of a system from observed time series. Historically, Piecewise-Linear Recurrent Neural Networks (PLRNNs) have been a popular choice for this task. Because they rely on ReLU activations, their state space is divided into distinct linear regions, making them highly interpretable and mathematically tractable.

However, standard PLRNNs are discrete-time maps. This presents a fundamental mismatch with reality: most physical and biological processes are continuous, and real-world data (like medical records or climate sensor readings) often arrives at irregular intervals. While Neural ODEs offer a continuous-time alternative, they are notoriously slow to train due to their reliance on expensive numerical solvers (like Runge-Kutta) and often act as opaque "black boxes" that lack the interpretability required in scientific and medical domains.

Introducing Continuous-Time PLRNNs (cPLRNNs)

To bridge this gap, researchers have developed the continuous-time PLRNN (cPLRNN). The core innovation lies in how the model solves the underlying differential equations by exploiting its own piecewise-linear structure.

Instead of using a numerical solver to incrementally guess the next state, the cPLRNN leverages the fact that dynamics within any single ReLU-defined region are purely linear. The model uses an exact analytical solution (a sum of exponentials) for that specific region. The trajectory only changes its governing rules when it hits a boundary—a hyperplane defined by the ReLU functions. The algorithm calculates the exact "switching time" when the trajectory crosses into a new region, effectively jumping from boundary to boundary and bypassing traditional numerical integration entirely.

Training and Topological Analysis

Training a model with discrete boundary crossings requires a clever approach to gradient descent. The authors utilize the Implicit Function Theorem to differentiate through these switching times, allowing the model to learn from data without ever needing a standard ODE solver.

Furthermore, the cPLRNN retains the interpretability of its discrete predecessors. The researchers adapted an algorithm called SCYFI to semi-analytically find equilibria (fixed points) and limit cycles (oscillations). This allows researchers to peer inside the trained model and understand its mechanical workings, a significant advantage over standard Neural ODEs.

Experimental Validation and Key Results

The cPLRNN was evaluated across a diverse set of benchmarks, including the chaotic Lorenz-63 system, a Leaky Integrate-and-Fire (LIF) neuron, real-world cortical neuron recordings, and irregularly sampled PhysioNet heartbeat data.

  • Training Speed and Efficiency: cPLRNNs trained several times faster than Neural ODEs using RK4 or Tsit5 solvers, achieving comparable or superior reconstruction quality at a fraction of the computational cost.
  • Handling Irregular Data: On the LIF neuron task, when only 10% of the data points were available, discrete-time PLRNNs failed completely. In contrast, cPLRNNs maintained high accuracy.
  • Mastering Discontinuities: Systems with "hard" events, like a neuron firing and resetting, typically confound ODE solvers. cPLRNNs handle these naturally by treating the events as boundary crossings.
  • Out-of-Domain Generalization: The model successfully identified fixed points in the Lorenz system despite being trained only on trajectories from the chaotic attractor, demonstrating that it truly captured the underlying physics.
  • Real-World Forecasting: On the PhysioNet heartbeat data, cPLRNNs significantly outperformed discrete-time models in forecasting accuracy.

Limitations and Future Directions

While highly effective, the cPLRNN framework has a few limitations. Optimization can occasionally fail due to ill-conditioned matrices during the eigen-decomposition step, though the authors suggest perturbation methods to mitigate this issue.

Additionally, while the model scales linearly with the number of dimensions, the root-finding process must restart at every boundary crossing. For models with a massive number of ReLU units, this could eventually become a computational bottleneck. Finally, the current mathematical framework focuses on shallow RNNs; extending it to deep architectures remains a complex challenge for future research.

Summary updated

BibTeX
@inproceedings{brandle2026continuous,
  author = {Alena Brändle and Lukas Eisenmann and Florian Götz and Daniel Durstewitz},
  title = {{Continuous-Time Piecewise-Linear Recurrent Neural Networks}},
  booktitle = {International Conference on Machine Learning},
  year = {2026},
  url = {https://openreview.net/forum?id=JuaulCZ7gE},
}
Figure