# Contour-reduced parametric SSM

- ID: 1838
- Canonical URL: https://synthcore.org/idea/1838/contour-reduced-parametric-ssm
- API JSON: https://synthcore.org/api/idea/1838.json
- API Markdown: https://synthcore.org/api/idea/1838.md
- Verification status: unverified
- Source: [arXiv:2608.05363](https://arxiv.org/abs/2608.05363)
- Category: architecture
- Solves: speedup, memory, stability
- ML areas: ssm, inference-speedup, world-model
- Math tags: numerical-analysis, linear-algebra, approximation-theory, dynamical-systems
- Ratings: usefulness 6/10; difficulty 6/10; novelty 7/10

## Idea description

Replace repeated full-dimensional matrix-exponential or ODE solves in a conditioned continuous-time state-space layer with contour quadrature evaluated in a projection basis. The same reduced basis and contour nodes can serve many conditioning vectors, while shifted reduced resolvents provide a stable and differentiable approximation over a prescribed time window.

## Mathematical statement

The paper starts from the descriptor system $$E(\mu)\dot{x}(t,\mu)=A(\mu)x(t,\mu)+B(\mu)u(t),\qquad y(t,\mu)=C(\mu)x(t,\mu)+D(\mu)u(t),$$ where \(E(\mu)\) is invertible, \(x\in\mathbb{R}^{n}\) is the state, \(u\in\mathbb{R}^{m}\) is the input, \(y\in\mathbb{R}^{p}\) is the output, and \(\mu\) is a parameter vector. In the Laplace domain, the state is represented with the resolvent \((sE(\mu)-A(\mu))^{-1}\). The inverse Laplace integral is approximated by quadrature nodes \(z_j=z_\Gamma(s_j)\) and weights \(w_j\), where the paper's contour has an elliptic middle segment \(z(s)=A_1\cos s+\mathrm{i}A_2\sin s+A_3\), joined to two rays. Here \(A_1,A_2,A_3\) define the ellipse, \(\mathrm{i}\) is the imaginary unit, \(s_j\) are quadrature abscissas, and \(w_j\) include the contour derivative and quadrature weights. Projection matrices \(V,W\in\mathbb{R}^{n\times r}\), with \(W^TV=I_r\), define \(E_r=W^TEV\), \(A_r(\mu)=W^TA(\mu)V\), \(B_r(\mu)=W^TB(\mu)\), and \(C_r(\mu)=C(\mu)V\). The expensive full resolvent is replaced by the reduced resolvent \((z_jE_r-A_r(\mu))^{-1}\), where \(r\ll n\).

## Key formulas

- $$E(\mu)\dot{x}(t,\mu)=A(\mu)x(t,\mu)+B(\mu)u(t),\qquad y(t,\mu)=C(\mu)x(t,\mu)+D(\mu)u(t).$$
- $$z_\Gamma(s)=\begin{cases}\ell_1(s),&s\leq-\frac{\pi}{2},\\ z(s),&-\frac{\pi}{2}\leq s\leq\frac{\pi}{2},\\ \ell_2(s),&s\geq\frac{\pi}{2},\end{cases}\qquad z(s)=A_1\cos s+\mathrm{i}A_2\sin s+A_3,$$
- $$\widehat{y}(t,\mu)=D(\mu)u(t)+\sum_{j=1}^{N}w_j e^{z_jt}C_r(\mu)\bigl(z_jE_r-A_r(\mu)\bigr)^{-1}\left[E_rx_{0,r}+B_r(\mu)U(z_j)\right],\qquad x_{0,r}=W^Tx_0.$$

## Implementation notes

Integrate this at the forward pass of a continuous-time SSM or latent world-model layer, replacing the operation that computes the hidden state with a matrix exponential or adaptive ODE solver. Let the conditioning vector \(\mu\) be a task embedding or per-example control vector, and parameterize \(A(\mu)=A_0+\sum_k\mu_kA_k\), with analogous parameterizations for \(B\) and \(C\). Choose a time window \(t\in[T,\Lambda T]\) and construct \(N\) contour nodes \(z_j=z_\Gamma(s_j)\) and weights \(w_j\) from the displayed elliptic contour. Build a projection basis \(V\) offline from Krylov or Arnoldi vectors generated by shifted systems \((z_jE-A(\mu_q))^{-1}B(\mu_q)\) and \((z_jE-A(\mu_q))^{-1}Ex_0\) for sampled conditioning vectors \(\mu_q\). Use \(W=V\) for a Galerkin implementation, or compute a biorthogonal \(W\) satisfying \(W^TV=I_r\). At runtime form \(E_r\), \(A_r(\mu)\), \(B_r(\mu)\), and \(C_r(\mu)\). For each contour node, solve the small dense system \((z_jE_r-A_r(\mu))q_j=E_rx_{0,r}+B_r(\mu)U(z_j)\), then accumulate \(\widehat{y}(t,\mu)=D(\mu)u(t)+\sum_jw_je^{z_jt}C_rq_j\). Cache nodes, weights, and any factorization shared across examples; automatic differentiation can backpropagate through the reduced solves. Estimate the basis empirically with greedy residual maximization over sampled \(\mu\), using residual \(\|(z_jE-A(\mu))Vq_j-[Ex_0+B(\mu)U(z_j)]\|\). First test a 256-dimensional conditioned SSM with a 16-dimensional parameter vector on synthetic damped linear trajectories and sequential MNIST. Compare against exact matrix exponentials and a fourth-order adaptive ODE solver, sweeping \(r\in\{8,16,32,64\}\) and \(N\in\{16,32,64\}\). Success requires matched output error below \(10^{-4}\), lower memory and latency, and at least 2x lower solve cost at \(r=32\) without worse validation loss.

## Disclaimer

AI-generated research hypothesis, automatically tested. Not peer-reviewed.
