Skip to main content

Python Library for exact simulations of waveguide QED using MPS.

Project description

QwaveMPS logo

QwaveMPS

build Codecov Documentation Status PyPI version Python Version License

Matrix-product-state simulations of non-Markovian waveguide QED

QwaveMPS is an open-source Python package that calculates light-matter interactions in waveguide QED systems using Matrix Product States, allowing one to study delayed feedback effects in the non-Markovian regime.

QwaveMPS is an open-source Python library for simulating one-dimensional quantum many-body systems using Matrix Product States (MPS). Designed for researchers and students, it provides a user-friendly interface for constructing, evolving, and analyzing quantum states and operators, facilitating studies in quantum physics and quantum information. This approach enables efficient, scalable simulations by focusing computational resources on the most relevant parts of the quantum system. Thus, one can study delayed feedback effects in the non-Markovian regime at a highly reduced computational cost compared to full Hilbert space approaches, making it practical to model open waveguide QED systems.

Features

  • Nonlinear non-Markovian waveguide-QED problems: Solve problems involving multiphoton and multiatom systems with time-delayed feedback.
  • Matrix product states (MPS): Based on MPS theory for efficient numerical exact results that do not rely on Monte Carlo simulations.
  • Open-source Python package: Python library with minimal dependencies on external packages.
  • User-friendly framework: Designed to be accessible for researchers and students.
  • Comprehensive Resources: Documentation and examples provided to support learning and usage.

Installation

This package can be installed using the following command:

pip install QwaveMPS

Usage

The following diagram summarizes the QwaveMPS framework, showing the main input and output parameters. For detailed usage information, see our documentation.

Diagram of the code workflow

Documentation

Read the full documentation at https://qwavemps.readthedocs.io

Simple example: Population dynamics of a TLS in an infinite waveguide

Import the necessary packages:

import numpy as np
import QwaveMPS as qmps

Define the simulation parameters:

delta_t = 0.05 # Time step of the simulation
tmax = 8 # Maximum simulation time
tlist=np.arange(0,tmax+delta_t,delta_t)
d_t_l=2 #Size of right-channel time bin (choose 2 for 1 photon per bin)
d_t_r=2 #Size of left-channel time bin 
d_t_total=np.array([d_t_l,d_t_r])

d_sys1=2 # tls bin dimension
d_sys_total=np.array([d_sys1]) #total system bin

gamma_l,gamma_r=qmps.coupling('symmetrical',gamma=1)
input_params = qmps.parameters.InputParams(
    delta_t=0.05, 
    tmax = 8,
    d_sys_total=d_sys_total,
    d_t_total=d_t_total,
    gamma_l=gamma_l,
    gamma_r=gamma_r,  
    bond_max=4 # Maximum bond dimension, truncates entanglement information
)

Choose the initial state:

sys_initial_state=qmps.states.tls_excited() #TLS initially excited
wg_initial_state = qmps.states.vacuum(tmax,input_params) #waveguide in vacuum

Choose the Hamiltonian:

ham = qmps.hamiltonian_1tls(input_params)

Calculate time evolution of the system:

bins = qmps.t_evol_mar(hm,sys_initial_state,wg_initial_state,input_params)

Choose operators to calculate population dynamics:

tls_pop_op = qmps.tls_pop()
flux_op_l = qmps.b_pop_l(input_params)
flux_op_r = qmps.b_pop_r(input_params)
flux_ops = [flux_op_l, flux_op_r]

Calculate population dynamics with operators or lists of operators:

tls_pop = qmps.single_time_expectation(bins.system_states, tls_pop_op)
photon_fluxes = qmps.single_time_expectation(bins.output_field_states, flux_ops)

Plot of population dynamics:

state Image

Check the full example for more details

License

QwaveMPS is distributed under the GNU GPLv3. See LICENSE for more information.

Citing QwaveMPS

If you use QwaveMPS in your research, please consider citing our paper: arXiv

Contact

For questions or support, open an issue or email qwavemps@gmail.com.

If you encounter a bug or have a feature request, please open an issue on the issue tracker to report it.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

qwavemps-1.0.1.tar.gz (959.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

qwavemps-1.0.1-py3-none-any.whl (39.8 kB view details)

Uploaded Python 3

File details

Details for the file qwavemps-1.0.1.tar.gz.

File metadata

  • Download URL: qwavemps-1.0.1.tar.gz
  • Upload date:
  • Size: 959.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for qwavemps-1.0.1.tar.gz
Algorithm Hash digest
SHA256 1d567aa67c3f3cba2be2e96cbc4fc90b52b1388084989494b339f23b50d6bc98
MD5 fa29e8a47f96b7b82229cfba0c2d8799
BLAKE2b-256 dbec699f3d6b63ebc7b563060c67be866e10967685049adc8526de2f8ec84486

See more details on using hashes here.

File details

Details for the file qwavemps-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: qwavemps-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 39.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for qwavemps-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 20909fb8c1c590f8045f2ed9c1ed95021aa9f7e56de555d7a8c30eb7de3860c5
MD5 2ed526ac57f674d4576edc6accb6e724
BLAKE2b-256 290fab0a12007c28cb2b7fcbe15c17c1c3dd6d2c1e77bc3bf8fb0f16654e63bd

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page