From 8e03f22cdfdeba5899a36e68bad73bd1bc206379 Mon Sep 17 00:00:00 2001 From: Khang Date: Thu, 4 Jun 2026 12:20:41 +0700 Subject: [PATCH] Add lazy::Bool parameter to QuantumOpticsRepr struct I used Claude (Cursor AI agent) to help brainstorm the logic for the lazy operator dispatch structure, which I then manually implemented and verified against the issue requirements. Co-authored-by: Cursor --- src/express.jl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/express.jl b/src/express.jl index c088c27..78e665a 100644 --- a/src/express.jl +++ b/src/express.jl @@ -23,8 +23,9 @@ express(s, repr::AbstractRepresentation) = express(s, repr, UseAsState()) ## """Representation using kets, bras, density matrices, and superoperators governed by `QuantumOptics.jl`.""" -Base.@kwdef struct QuantumOpticsRepr <: AbstractRepresentation +Base.@kwdef struct QuantumOpticsRepr <: AbstractRepresentation cutoff::Int = 2 + lazy::Bool = false end """Similar to `QuantumOpticsRepr`, but using trajectories instead of superoperators.""" struct QuantumMCRepr <: AbstractRepresentation end