Documentation

The H-cat encoding and the simulations

How the H-cat encoding works, what the component simulations cover, and how each tool works. No Dyber hardware exists.

Overview

The H-cat is a hybrid continuous-variable / discrete-variable (CV-DV) qubit encoding for photonic quantum computing (Lee et al., PRX Quantum 5, 030322, 2024). Each qubit pairs a cat state with a single photon: |0_L> = |+>|C_alpha^+> and |1_L> = |->|C_(i alpha)^+>. Both logical states carry an even cat.

The cat's photon-number parity is a loss flag, not the logical value: one lost photon flips it and is flagged, so a decoder can treat that loss as an erasure. Two lost photons leave parity even and are a silent logical error. Flags exist only where photons are detected; in the paper's design every fusion detects all of its outputs.

Pipeline

The five stages of the paper's design, with what the repo simulated:

StageFunctionStatus
1. SqueezeGenerate squeezed vacuumSimulated from 0.5 to 8 dB; usable small cats at 3.5 to 8 dB (component simulation)
2. SubtractPhoton subtraction (PNR tap)Small-cat fidelity above 0.99 in simulation
3. BreedGrow cats by beamsplitter interference and heraldingNeeds amplitude about 2.5 to 2.9, far beyond the cats simulated
4. FuseDestructive hybrid Bell measurement, all outputs detectedWhere the loss flags come from
5. CorrectTopological code with erasure-aware decodingSDK numbers are model values (assumed loss heralds), not a hardware operating point

Cat states

A cat state is |cat+> = N(|alpha> + |-alpha>), an even superposition of two coherent states in phase space. Subtracting one photon from squeezed vacuum gives a small odd cat; the component simulations reach high fidelity for small cats (amplitude around 1) at 3.5 to 8 dB squeezing. The H-cat encoding needs even cats of amplitude about 2.5 to 2.9, far beyond what was simulated.

The Wigner function of a cat state shows characteristic interference fringes at the origin, with two Gaussian blobs at +/- alpha. In the H-cat encoding, parity is a loss flag, not the logical value: Z_L is read from the single photon, and X_L from the photon's H/V outcome times the cat photon count mod 4.

Breeding

Cat breeding entangles two small cats into a larger cat via beamsplitter interference and heralded detection. The protocol is probabilistic but heralded: failure is flagged and the state is discarded; a heralded success can still carry errors from loss.

The repo has not simulated cats at the amplitude and quality the H-cat encoding needs (amplitude about 2.5 to 2.9).

Fusion

In the paper's design, fusion is a destructive hybrid Bell measurement: the cat modes are interfered and counted on photon-number-resolving detectors, and the single photons are measured on their own detectors, with every output detected. Those detections are what produce the loss flags.

Loss and error model

Photon loss is the dominant error channel. One lost photon flips the cat's parity and is flagged when the cat is detected. Two lost photons leave parity even and are a silent logical error. The SDK's resource model splits loss into erasure and silent Pauli with a Poisson closed form times correction factors computed in simulation; that split is a model assumption, not a measured rate.

The SDK's resource model uses a loss threshold of 0.79 percent per cycle by default (0.898 percent without the silent-Pauli correction). Model value: abstract circuit model with assumed loss heralds. Not a hardware operating point.

Fault tolerance

Dyber's research surface-code runs use stim and PyMatching (an erasure-aware decoder) in an abstract circuit model with assumed loss heralds: fusion erasure and Pauli, measurement error, preparation error and idle loss. The SDK's resource model uses a fit to those runs. That model gives a loss threshold of 0.79 to 0.898 percent per cycle. Model value: abstract circuit model with assumed loss heralds. Not a hardware operating point. The optional qLDPC setting divides hardware modes by an assumed factor of 10 (illustrative).

Photonic devices

Dyber's design studies assumed silicon nitride (SiN) integrated photonics. Components studied in simulation:

  • Microring resonators for squeezing and filtering
  • Waveguide beamsplitters for interference
  • Grating couplers for fiber I/O
  • Photon-number-resolving detectors, such as transition-edge sensors (TES)

Device simulations use Meep (FDTD) for ring resonances and MPB (eigenmode) for waveguide dispersion. TES detectors operate at millikelvin temperatures in a dilution refrigerator.

Resource model

The resource model (v2) converts a target logical error rate into model resource counts: code distance, cats per logical qubit and hardware modes. It is the engine behind the Resource Analyzer. The distance comes from the fit Lambda = (p_th / gamma)^1.61 with p_th = 0.79 percent (default) or 0.898 percent (uncorrected), and cats per logical = 2d^2 - 1. The loss-to-error split is the Poisson closed form times correction factors computed in simulation. Model values: abstract circuit model with assumed loss heralds. Not a hardware operating point.

Inputs: target error rate, physical loss per cycle (gamma), cat amplitude (alpha) and outer code. Output: illustrative model resource counts, not a bill of materials.

With the default 0.5 percent loss per cycle and a 1e-9 target, the analyzer returns distance 53 and 5,617 cats per logical; at or above the model threshold it reports that no fault-tolerant distance exists in the model. Model values: abstract circuit model with assumed loss heralds. Not a hardware operating point.

Simulations

The repo's simulations use:

  • QuTiP: cat state generation, loss channels, photon-number parity (the loss flag)
  • Strawberry Fields: independent cross-check of small-cat fidelity
  • stim + pymatching: surface-code runs in an abstract circuit model with assumed loss heralds (model values)
  • Meep: SiN ring resonator FDTD simulations
  • MPB: waveguide eigenmode dispersion

Component-level results from the repo's simulations (they check pieces of the code, not the machine):

  • Two independent codebases (QuTiP and Strawberry Fields) agree on small-cat fidelity to about 4e-5.
  • Master-equation (mesolve) evolution agrees with the closed-form loss channel to 1e-9.
  • A pytest regression suite in the research repo pins the simulation outputs against stored values.