quchip.engine.field_statistics

Stationary output statistics and their propagation through resolved wiring.

Functions

block_diagonal(blocks, xp)

Assemble per-output IQ blocks, keeping the leading batch axes.

canonical(values, template, *, tag)

Keep the resolved operator's physical basis for a regression source.

complex_covariance(values, xp)

Convert E[z_i z_j*] to the covariance of (Re z_i, Im z_i).

field_sources(engine, rho, xp)

Return centered L, output regression sources, and direct thermal noise.

field_transfer(upper, lower, xp)

Convert a matrix of field transfers to interleaved IQ coordinates.

normal_spectrum(iq, xp)

Recover the upper-sideband normal spectrum from a single-output IQ block.

propagate_noise(fields, scattering, graph, ...)

Apply one physical source/transfer owner to the spectrum of either stationary solver.

proper_spectrum(upper, lower, xp)

Convert normal upper/lower cross-spectra to normally ordered IQ spectra.

quadrature_spectrum(engine, rho, backend, ...)

Return the normally ordered IQ cross-spectrum.

quadrature_transfer(upper, lower, xp)

Convert complex upper/lower sideband transmission to an IQ transfer.

quchip.engine.field_statistics.canonical(values, template, *, tag)[source]

Keep the resolved operator’s physical basis for a regression source.

quchip.engine.field_statistics.field_sources(engine, rho, xp)[source]

Return centered L, output regression sources, and direct thermal noise.

With K=S†L, source i is (L_i-<L_i>)rho + sum_j S_ij n_j [K_j,rho]. The input-system correlations are necessary because, at thermal equilibrium, a matched cavity’s output stays thermal. Without them, the fluorescence would add the same incoming bath a second time.

quchip.engine.field_statistics.quadrature_spectrum(engine, rho, backend, prepared, labels, frequencies)[source]

Return the normally ordered IQ cross-spectrum.

The coordinates are (I_0,Q_0,I_1,Q_1,…), with b=I+iQ. The detector vacuum is intentionally absent. The excess spectrum includes anomalous correlations, so it can have negative eigenvalues for squeezed fields.

quchip.engine.field_statistics.complex_covariance(values, xp)[source]

Convert E[z_i z_j*] to the covariance of (Re z_i, Im z_i).

quchip.engine.field_statistics.normal_spectrum(iq, xp)[source]

Recover the upper-sideband normal spectrum from a single-output IQ block.

quchip.engine.field_statistics.quadrature_transfer(upper, lower, xp)[source]

Convert complex upper/lower sideband transmission to an IQ transfer.

quchip.engine.field_statistics.block_diagonal(blocks, xp)[source]

Assemble per-output IQ blocks, keeping the leading batch axes.

quchip.engine.field_statistics.proper_spectrum(upper, lower, xp)[source]

Convert normal upper/lower cross-spectra to normally ordered IQ spectra.

quchip.engine.field_statistics.field_transfer(upper, lower, xp)[source]

Convert a matrix of field transfers to interleaved IQ coordinates.

quchip.engine.field_statistics.propagate_noise(fields, scattering, graph, excess, labels, frequency, offsets, xp, *, include_inputs=True)[source]

Apply one physical source/transfer owner to the spectrum of either stationary solver.