Skip to content

Commit f5ede79

Browse files
committed
Merge branch 'main' into code-quality-Julia-1
2 parents 603bbc8 + 300fd5d commit f5ede79

34 files changed

+1113
-631
lines changed

.github/workflows/CleanPreviewDoc.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ on:
44
pull_request:
55
types: [closed]
66

7+
permissions:
8+
contents: write
9+
deployments: write
10+
711
jobs:
812
cleanup-preview-doc:
913
runs-on: ubuntu-latest
@@ -23,4 +27,5 @@ jobs:
2327
git push --force origin gh-pages-new:gh-pages
2428
fi
2529
env:
30+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2631
PRNUM: ${{ github.event.number }}

.github/workflows/SpellCheck.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ jobs:
1010
- name: Checkout Actions Repository
1111
uses: actions/checkout@v4
1212
- name: Check spelling
13-
uses: crate-ci/[email protected].5
13+
uses: crate-ci/[email protected].7

CHANGELOG.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,23 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased](https://github.com/qutip/QuantumToolbox.jl/tree/main)
99

10+
- Support for single `AbstractQuantumObject` in `sc_ops` for faster specific method in `ssesolve` and `smesolve`. ([#408])
11+
- Change save callbacks from `PresetTimeCallback` to `FunctionCallingCallback`. ([#410])
12+
- Align `eigenstates` and `eigenenergies` to QuTiP. ([#411])
13+
14+
## [v0.27.0]
15+
Release date: 2025-02-14
16+
1017
- Rename `sparse_to_dense` as `to_dense` and `dense_to_sparse` as `to_sparse`. ([#392])
1118
- Fix erroneous definition of the stochastic term in `smesolve`. ([#393])
1219
- Change name of `MultiSiteOperator` to `multisite_operator`. ([#394])
1320
- Fix `smesolve` for specifying initial state as density matrix. ([#395])
21+
- Add more generic solver for `steadystate_floquet` to allow more linear solvers. ([#396])
1422
- Fix time evolution output when using `saveat` keyword argument. ([#398])
23+
- Align some attributes of `mcsolve`, `ssesolve` and `smesolve` results with `QuTiP`. ([#402])
24+
- Improve ensemble generation of `ssesolve` and change parameters handling on stochastic processes. ([#403])
25+
- Set default trajectories to 500 and rename the keyword argument `ensemble_method` to `ensemblealg`. ([#405])
26+
- Introduce measurement on `ssesolve` and `smesolve`. ([#404])
1527

1628
## [v0.26.0]
1729
Release date: 2025-02-09
@@ -89,6 +101,7 @@ Release date: 2024-11-13
89101
[v0.25.1]: https://github.com/qutip/QuantumToolbox.jl/releases/tag/v0.25.1
90102
[v0.25.2]: https://github.com/qutip/QuantumToolbox.jl/releases/tag/v0.25.2
91103
[v0.26.0]: https://github.com/qutip/QuantumToolbox.jl/releases/tag/v0.26.0
104+
[v0.27.0]: https://github.com/qutip/QuantumToolbox.jl/releases/tag/v0.27.0
92105
[#86]: https://github.com/qutip/QuantumToolbox.jl/issues/86
93106
[#139]: https://github.com/qutip/QuantumToolbox.jl/issues/139
94107
[#271]: https://github.com/qutip/QuantumToolbox.jl/issues/271
@@ -125,4 +138,12 @@ Release date: 2024-11-13
125138
[#393]: https://github.com/qutip/QuantumToolbox.jl/issues/393
126139
[#394]: https://github.com/qutip/QuantumToolbox.jl/issues/394
127140
[#395]: https://github.com/qutip/QuantumToolbox.jl/issues/395
141+
[#396]: https://github.com/qutip/QuantumToolbox.jl/issues/396
128142
[#398]: https://github.com/qutip/QuantumToolbox.jl/issues/398
143+
[#402]: https://github.com/qutip/QuantumToolbox.jl/issues/402
144+
[#403]: https://github.com/qutip/QuantumToolbox.jl/issues/403
145+
[#404]: https://github.com/qutip/QuantumToolbox.jl/issues/404
146+
[#405]: https://github.com/qutip/QuantumToolbox.jl/issues/405
147+
[#408]: https://github.com/qutip/QuantumToolbox.jl/issues/408
148+
[#410]: https://github.com/qutip/QuantumToolbox.jl/issues/410
149+
[#411]: https://github.com/qutip/QuantumToolbox.jl/issues/411

Project.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name = "QuantumToolbox"
22
uuid = "6c2fb7c5-b903-41d2-bc5e-5a7c320b9fab"
33
authors = ["Alberto Mercurio", "Yi-Te Huang"]
4-
version = "0.26.0"
4+
version = "0.27.0"
55

66
[deps]
77
ArrayInterface = "4fba245c-0d91-5ea0-9b3e-6abc04ee57a9"
@@ -51,7 +51,7 @@ Graphs = "1.7"
5151
IncompleteLU = "0.2"
5252
KernelAbstractions = "0.9.2"
5353
LinearAlgebra = "1"
54-
LinearSolve = "2"
54+
LinearSolve = "2, 3"
5555
OrdinaryDiffEqCore = "1"
5656
OrdinaryDiffEqTsit5 = "1"
5757
Pkg = "1"

benchmarks/eigenvalues.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@ function benchmark_eigenvalues!(SUITE)
1616
L = liouvillian(H, c_ops)
1717

1818
SUITE["Eigenvalues"]["eigenstates"]["dense"] = @benchmarkable eigenstates($L)
19-
SUITE["Eigenvalues"]["eigenstates"]["sparse"] = @benchmarkable eigenstates($L, sparse = true, sigma = 0.01, k = 5)
19+
SUITE["Eigenvalues"]["eigenstates"]["sparse"] =
20+
@benchmarkable eigenstates($L, sparse = true, sigma = 0.01, eigvals = 5)
2021

2122
return nothing
2223
end

benchmarks/timeevolution.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ function benchmark_timeevolution!(SUITE)
5050
ntraj = 100,
5151
e_ops = $e_ops,
5252
progress_bar = Val(false),
53-
ensemble_method = EnsembleSerial(),
53+
ensemblealg = EnsembleSerial(),
5454
)
5555
SUITE["Time Evolution"]["time-independent"]["mcsolve"]["Multithreaded"] = @benchmarkable mcsolve(
5656
$H,
@@ -60,7 +60,7 @@ function benchmark_timeevolution!(SUITE)
6060
ntraj = 100,
6161
e_ops = $e_ops,
6262
progress_bar = Val(false),
63-
ensemble_method = EnsembleThreads(),
63+
ensemblealg = EnsembleThreads(),
6464
)
6565

6666
return nothing

docs/make.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ const PAGES = [
3434
"Home" => "index.md",
3535
"Getting Started" => [
3636
"Brief Example" => "getting_started/brief_example.md",
37-
"Key differences from QuTiP" => "getting_started/qutip_differences.md",
37+
# "Key differences from QuTiP" => "getting_started/qutip_differences.md",
3838
"The Importance of Type-Stability" => "getting_started/type_stability.md",
3939
"Example: Create QuantumToolbox.jl Logo" => "getting_started/logo.md",
4040
# "Cite QuantumToolbox.jl" => "getting_started/cite.md",
@@ -51,7 +51,7 @@ const PAGES = [
5151
"Time Evolution Solutions" => "users_guide/time_evolution/solution.md",
5252
"Schrödinger Equation Solver" => "users_guide/time_evolution/sesolve.md",
5353
"Lindblad Master Equation Solver" => "users_guide/time_evolution/mesolve.md",
54-
"Monte-Carlo Solver" => "users_guide/time_evolution/mcsolve.md",
54+
"Monte Carlo Solver" => "users_guide/time_evolution/mcsolve.md",
5555
"Stochastic Solver" => "users_guide/time_evolution/stochastic.md",
5656
"Solving Problems with Time-dependent Hamiltonians" => "users_guide/time_evolution/time_dependent.md",
5757
],

docs/src/resources/api.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,11 +212,12 @@ liouvillian_generalized
212212

213213
```@docs
214214
steadystate
215-
steadystate_floquet
215+
steadystate_fourier
216216
SteadyStateDirectSolver
217217
SteadyStateEigenSolver
218218
SteadyStateLinearSolver
219219
SteadyStateODESolver
220+
SSFloquetEffectiveLiouvillian
220221
```
221222

222223
### [Dynamical Shifted Fock method](@id doc-API:Dynamical-Shifted-Fock-method)

docs/src/users_guide/cluster.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ e_ops = [Sx, Sy, Sz]
112112

113113
tlist = range(0, 10, 100)
114114

115-
sol_mc = mcsolve(H, ψ0, tlist, c_ops, e_ops=e_ops, ntraj=5000, ensemble_method=EnsembleSplitThreads())
115+
sol_mc = mcsolve(H, ψ0, tlist, c_ops, e_ops=e_ops, ntraj=5000, ensemblealg=EnsembleSplitThreads())
116116

117117
##
118118

@@ -131,7 +131,7 @@ println("Hello! You have $(nworkers()) workers with $(remotecall_fetch(Threads.n
131131

132132
command, we test that the distributed network is correctly initialized. The `remotecall_fetch(Threads.nthreads, 2)` command returns the number of threads of the worker with ID `2`.
133133

134-
We then write the main part of the script, where we define the lattice through the [`Lattice`](@ref) function. We set the parameters and define the Hamiltonian and collapse operators with the [`DissipativeIsing`](@ref) function. We also define the expectation operators `e_ops` and the initial state `ψ0`. Finally, we perform the Monte Carlo quantum trajectories with the [`mcsolve`](@ref) function. The `ensemble_method=EnsembleSplitThreads()` argument is used to parallelize the Monte Carlo quantum trajectories, by splitting the ensemble of trajectories among the workers. For a more detailed explanation of the different ensemble methods, you can check the [official documentation](https://docs.sciml.ai/DiffEqDocs/stable/features/ensemble/) of the [**DifferentialEquations.jl**](https://github.com/SciML/DifferentialEquations.jl/) package. Finally, the `rmprocs(workers())` command is used to remove the workers after the computation is finished.
134+
We then write the main part of the script, where we define the lattice through the [`Lattice`](@ref) function. We set the parameters and define the Hamiltonian and collapse operators with the [`DissipativeIsing`](@ref) function. We also define the expectation operators `e_ops` and the initial state `ψ0`. Finally, we perform the Monte Carlo quantum trajectories with the [`mcsolve`](@ref) function. The `ensemblealg=EnsembleSplitThreads()` argument is used to parallelize the Monte Carlo quantum trajectories, by splitting the ensemble of trajectories among the workers. For a more detailed explanation of the different ensemble methods, you can check the [official documentation](https://docs.sciml.ai/DiffEqDocs/stable/features/ensemble/) of the [**DifferentialEquations.jl**](https://github.com/SciML/DifferentialEquations.jl/) package. Finally, the `rmprocs(workers())` command is used to remove the workers after the computation is finished.
135135

136136
The output of the script will be printed in the `output.out` file, which contains an output similar to the following:
137137

docs/src/users_guide/steadystate.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,4 +121,4 @@ fig
121121

122122
## Calculate steady state for periodically driven systems
123123

124-
See the docstring of [`steadystate_floquet`](@ref) for more details.
124+
See the docstring of [`steadystate_fourier`](@ref) for more details.

0 commit comments

Comments
 (0)