Mode-Selective Resets for Encrypted Dynamic Controllers

An encrypted controller runs on a cloud server that never sees plaintext. It receives encrypted sensor readings, updates an encrypted internal state, and returns an encrypted command. The schemes that allow this are homomorphic encryption (arithmetic carried out directly on ciphertexts). Each ciphertext carries a small random error, called noise, that grows with every multiplication. Once the noise passes a fixed threshold, decryption fails. A dynamic controller multiplies its state by a matrix at every sampling step, so its noise grows without bound. The usual zero-communication fix is to wipe the whole controller state to zero every $T$ steps. This bounds the noise, but at each reset the controller loses all of its memory, and closed-loop performance suffers.

This note proposes resetting only part of the state, one dynamical mode at a time. Control theory treats the coordinates of a controller's state as a free bookkeeping choice, because any similarity transform $x' = Tx$ yields the same input-output behavior. Encryption breaks that freedom. Resetting part of the state bounds noise only if the reset coordinates are dynamically decoupled from the rest. Otherwise noise leaks back into them from the coordinates that were not reset. The proposal is to realize the controller in block-decoupled modal coordinates and reset or refresh each mode on its own schedule. Fast-decaying modes would be reset often at almost no performance cost. Only slow or unstable modes would need expensive refreshing. Stability across every admissible reset schedule would be certified with a single common Lyapunov function, which becomes a polynomial certificate when the plant is nonlinear.

Core Claim

Two linear-plant studies analyze full-state periodic resets with quadratic Lyapunov inequalities. Secure and Private Implementation of Dynamic Controllers Using Semi-Homomorphic Encryption designs Paillier-based resetting controllers this way. Comparison and performance analysis of dynamic encrypted control approaches compares resets, FIR truncation, bootstrapping and integer reformulation under CKKS on a batch reactor. On that benchmark the nominal $\ell_2$-gain bound is 1.8030, and full resets cost 1.8869 to 1.9508. These two papers motivate the work: they show that resets work but are lossy.

We claim that most of this loss comes from throwing away modes that did not need to be thrown away. Consider a controller in real Jordan form, $x_{k+1} = \mathrm{blkdiag}(A_1,\dots,A_p)\,x_k + B y_k$, where $y_k$ is the freshly encrypted measurement. In this realization the noise depth of block $j$ equals exactly the number of steps since block $j$ was last reset. In a dense realization, resetting any subset of coordinates leaves noise depth unbounded. So the realization becomes a cryptographic design variable even though it is invisible to the transfer function.

The stability certificate must not depend on that same choice. An Improved Stability Condition for Kalman Filtering with Bounded Markovian Packet Losses shows that norm-based stability tests can flip from 0.73 (stable) to 1.52 (unstable) under a mere change of coordinates. We therefore use only certificates whose Lyapunov matrix or polynomial is free, so that the realization changes the implementation and never the verdict.

Research Program

The first piece is realization design. Starting from a given controller (an $\mathcal{H}_\infty$ design for the reactor and an observer-based design for the pendulum), we compute its real Jordan form. We borrow this transform from Bounded Verification with On-the-Fly Discrepancy Computation, which uses it to stop reach sets from inflating on rotational modes; we reuse it for a different purpose. Within each block we choose a diagonal scaling that keeps entries representable at the fixed-point scale. Each block is then assigned to one of three treatments:

  • Periodic zeroing (cheap): the block's state is wiped to zero on its own schedule.
  • Bootstrapping (costly): the block's ciphertext is refreshed by homomorphically evaluating decryption, which injects a bounded approximation error, as modeled in Comparison and performance analysis of dynamic encrypted control approaches.
  • Integer reformulation: reserved for blocks with $|\lambda| \ge 1$, where zeroing would be destructive.

The second piece is schedule-robust certification. Resetting block set $S$ at step $k$ applies a jump map $J_S$ that zeroes those blocks. Schedules are constrained by a per-block maximum interval (the noise budget) and a minimum interval. At runtime, latency jitter and bootstrapping fallbacks shift resets within these windows, so the closed loop is a switched system over a dwell-constrained set of jump patterns.

For linear plants we search for a common quadratic Lyapunov function with an $\ell_2$-gain bound over all admissible patterns. We use the dwell-time-dependent piecewise-quadratic form of Stability of switched linear systems under dwell time switching with piece wise quadratic functions. When that fails, we escalate to homogeneous sum-of-squares (SOS) polynomial certificates, which are polynomials provably nonnegative because they can be written as sums of squared polynomials. Converse results on existence of sum of squares Lyapunov functions guarantees such certificates exist at some degree for switched linear systems that are stable under arbitrary switching. Sum of Squares Certificates for Stability of Planar, Homogeneous, and Switched Systems supplies the top-homogeneous-component reduction we use to keep the semidefinite programs small.

The third piece is the nonlinear regime. For the cart-pendulum we keep a polynomial model of the plant and the encrypted linear controller. We certify a region of attraction and a practical-stability ball, treating quantization and bootstrapping error as bounded disturbances. SOS here is necessary rather than optional, because a quadratic function cannot describe a nonlinear region of attraction. The closed loop has about eight states, which with a degree-4 certificate gives a Gram basis of 45 monomials, within solver reach. Lemma 3.12 of the Ahmadi–Parrilo paper shows that SOS derivative conditions behave differently for nonlinear dynamics. This constrains our design: we impose positivity of $V$ and decrease of $V$ separately, rather than inferring one from the other.

This differs from the closest work in specific ways. Toward nonlinear dynamic control over encrypted data for infinite time horizon also uses a coordinate change, the observable canonical form. It uses it to make the controller non-recursive, and that requires the actuator to decrypt and re-encrypt at every step. We keep the recursion and keep the plant passive. The integer reformulation in Schlor and Allgöwer re-parameterizes the matrices but resets or refreshes the whole state. FHECAP: An Encrypted Control System with Piecewise Continuous Actuation handles actuator nonlinearities without Lyapunov certificates. We handle nonlinear plant dynamics and certify them.

Baselines

The naive reference is the encrypted controller with no noise management. Secure and Private Implementation of Dynamic Controllers Using Semi-Homomorphic Encryption reports that it overflows within 1.2 s at a 10 ms sampling period with a 2048-bit space. We reproduce this failure time in our CKKS setting to calibrate the noise budget.

The strongest existing reset method is full periodic resetting with an optimized period and a quadratic certificate, as in Schlor and Allgöwer. Its reported certified $\ell_2$-gain bounds on the batch reactor at $h = 0.1$ range from 1.8869 to 1.9508.

The strongest overall competitor on that benchmark is FIR truncation, with a reported bound of 1.8819. Bootstrapping the full state is reported at 2.0332, and exact state re-encryption, which needs a plant round trip, at the nominal 1.8030.

To keep the comparison fair, all methods use:

  • the same discretized reactor;
  • the same $\mathcal{H}_\infty$ controller;
  • the same CKKS parameter set and multiplicative-depth budget per step;
  • the same LMI or SOS solver;
  • the same search budget over periods or window lengths.

We first reproduce the reported numbers. Beating the existing methods means a certified bound below 1.8819 at equal or lower per-step depth and ciphertext memory, or matching 1.8819 with strictly less memory than FIR.

Two ablations isolate the key ingredient:

  • Dense-realization staggered resets. Applying staggered partial resets in the original dense realization tests whether decoupled coordinates are what bound the noise.
  • Single-period modal resets. Using the modal realization but resetting every block on one common period tests whether gains come from the coordinates or from the per-mode schedules.

For the pendulum, no reported encrypted nonlinear result was found on Lacuna. The reference points are full resets certified by local quadratic LMIs, as in Implementing homomorphic encryption based secure feedback control on a linearized model, and the plaintext geometric PID of Robust and Exponential Stabilization of a Cart-Pendulum System via Geometric PID Control. The latter reports an attraction region of almost a half-circle in angle.

Why not just…?

Why not just use the FIR approximation, which already beats resets? This is the real threat. On the reactor, FIR's 1.8819 is better than every reset configuration reported. FIR becomes expensive when the controller has slowly decaying modes, because the window length then grows and so does the number of stored encrypted measurement vectors. Mode-selective resets treat this as a per-mode choice and pay memory only for slow modes. We will sweep controller pole damping on both benchmarks and report certified gain against ciphertext memory for FIR and for our method. If FIR dominates across the whole sweep, we will report that as the finding.

Why not just lift the system over one reset period and check the spectral radius, instead of a common Lyapunov function? For a fixed, exactly periodic schedule on a linear plant, lifting is exact, and we will use it as the reference certificate. It says nothing once resets jitter within their admissible windows, and it does not extend to nonlinear regions of attraction. We will run randomized admissible schedules and report cases where the lifted certificate for the nominal period holds but the realized closed loop violates its bound. Whatever the outcome, we will also report how much tighter the lifted bound is than the schedule-robust one.

Why not just bootstrap the whole state and avoid resets entirely? The reported bound of 2.0332 is the worst of all the options in Comparison and performance analysis of dynamic encrypted control approaches. Bootstrapping is also the dominant cost in deep homomorphic computation according to Karthik Nandakumar et al.. Our method bootstraps only the blocks that cannot be zeroed. We will measure per-step latency and certified gain against full bootstrapping.

Proposed Experiments

The first decisive check is mechanistic: run partial resets in a dense realization and in a modal realization of the same controller, and track the measured noise level of each ciphertext over 10,000 steps. Our account predicts bounded noise only in the modal case. If the dense realization also stays bounded, the core claim is wrong.

The second check is the reactor comparison against 1.8030, 1.8819 and 1.8869–1.9508, using the matched settings above. We report certified and simulated $\ell_2$-gains, depth per step, and ciphertext count.

The third check is schedule robustness: inject random reset delays within the admissible windows and verify that the common certificate holds in every run.

The fourth check is nonlinear. On the polynomial cart-pendulum, compare the certified region of attraction under mode-selective resets with the region under full resets, each certified at degree 2 and degree 4. This shows whether the polynomial certificate, rather than the resetting strategy, accounts for any gain. We also report how far the encrypted trajectories deviate from the plaintext ones.