A Python toolkit for computing multimode optical squeezing from normalized Joint Spectral Amplitudes (JSAs) using Schmidt-mode decomposition.
The package provides numerical tools for:
- Joint spectral amplitude (JSA) normalization
- Joint spectral intensity (JSI) normalization
- Schmidt-mode decomposition
- Multimode squeezing calculations
- Quadrature variance evaluation
- Local-oscillator modal overlap
- Squeezing versus local-oscillator wavelength
- Spectral squeezing density calculations
- Degenerate and nondegenerate squeezing configurations
The framework is intended for integrated quantum photonics, spontaneous four-wave mixing (SFWM), spontaneous parametric down-conversion (SPDC), and multimode quantum optics.
Clone the repository and install it in editable mode:
pip install -e .Editable mode is useful during development because changes made inside src/squeezing_jsa/ are immediately reflected when the package is imported.
Main dependencies:
- numpy
- scipy
- matplotlib
- jupyter
Given a normalized Joint Spectral Amplitude
the Schmidt decomposition is written as
The Schmidt coefficients satisfy
when the JSA is normalized according to
The modal squeezing parameters are defined as
where (G) is an effective nonlinear gain parameter.
The toolkit also implements local-oscillator-dependent quadrature variances and normalized spectral squeezing quantities based on multimode homodyne detection theory.
Additional theoretical details are provided in:
docs/basic_theory.pdf
docs/equations.tex
src/squeezing_jsa/
__init__.py
jsa.py
schmidt.py
squeezing.py
lo_squeezing.py
homodyne.py
plots.py
The public API is exposed through squeezing_jsa/__init__.py. Therefore, user-facing scripts can import the main functions directly from squeezing_jsa.
from squeezing_jsa import (
normalized_jsa,
normalized_jsi_from_jsa,
)from squeezing_jsa import schmidt_decompositionfrom squeezing_jsa import (
squeezing_parameters,
squeezing_db,
)from squeezing_jsa import (
wavelength_to_omega,
omega_to_wavelength,
variance_eq83,
variance_to_shot_noise_units,
variance_to_db,
interpolate_modes_at_omega,
overlaps_with_lo,
squeezing_vs_wavelength_delta_lo,
gaussian_lo_spectrum,
gaussian_lo_overlaps,
squeezing_vs_wavelength_gaussian_lo,
squeezing_spectral_density_eq83,
squeezing_spectral_density_vs_wavelength_eq83,
)from squeezing_jsa import (
schmidt_decomposition,
squeezing_parameters,
)
sch = schmidt_decomposition(F, dws, dwi, nmodes=20)
lambdas = sch["lambdas"]
r = squeezing_parameters(
lambdas,
gain=0.5,
)Here, F is a normalized or normalizable JSA sampled on a two-dimensional frequency grid, and dws, dwi are the frequency steps along the signal and idler axes.
The repository includes example scripts demonstrating different physical and numerical configurations.
example_squeezing_synthetic_jsa.py
This example demonstrates:
- Synthetic Gaussian-sinc JSA generation
- Schmidt decomposition
- Modal squeezing parameters
- Gaussian local-oscillator overlaps
- Squeezing versus LO wavelength
- Spectral squeezing density using the multimode quadrature variance formalism
example_jsa_from_dispersion.py
This example demonstrates:
- JSA construction from polynomial dispersion coefficients
- Phase-matching calculations
- Degenerate and nondegenerate pump configurations
- Delta-k scans
- Normalized JSI visualization
example_jsa_from_table.py
This example demonstrates:
- JSA construction from polynomial table given by the user
- The data for
$\lambda$ and k must be placed in a file under examples/data - Phase-matching calculations
- Degenerate and nondegenerate pump configurations
- Delta-k scans
- Normalized JSI visualization
example_degenerate_pumps_non_degenerate_squeezing.py
This example demonstrates:
- Two-mode squeezing calculations
- Companion local-oscillator wavelength from energy conservation
- Vacuum-normalized quadrature variances
- Squeezing versus swept LO wavelength
After installing the package in editable mode, the examples can be run from the repository root:
python example_squeezing_synthetic_jsa.py
python example_jsa_from_coefficients.py
python example_degenerate_pumps_non_degenerate_squeezing.pyA compact theoretical note is included in:
docs/basic_theory.pdf
The corresponding LaTeX source is available in:
docs/equations.tex
The note summarizes the normalized JSA convention, Schmidt-mode decomposition, modal squeezing parameters, vacuum normalization, degenerate-pump case, and local-oscillator-dependent squeezing expressions used in the toolkit.
A compact description of how to use different models of dispersion is included in:
docs/dispersion_models.md
MIT License
The author acknowledges scientific discussions and prior methodological exchanges with members of the Quantum Optics and Nonlinear Interactions Laboratory (LINOC in Spanish) group at CICESE, including Karina Garay Palmett, Nayeli Casillas Rodríguez and Ferney Castro Simanca, related to numerical modeling and dispersion-engineering techniques in nonlinear integrated photonics.
Special thanks to CF-2023-G-687 SECIHTI Mexico (formerly CONAHCYT) Project
If you use this software in academic work, please cite:
Francisco Dominguez-Serna,
Multimode Squeezing Toolkit (2026).
DOI: pending.