Skip to content

Commit

Permalink
Merge pull request qutip#150 from ytdHuang/dev/Qobj
Browse files Browse the repository at this point in the history
Re-organize source code for `Qobj`
  • Loading branch information
ytdHuang authored May 30, 2024
2 parents 07475a7 + 21f57de commit 1fdc207
Show file tree
Hide file tree
Showing 14 changed files with 1,487 additions and 1,412 deletions.
122 changes: 66 additions & 56 deletions docs/src/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ CurrentModule = QuantumToolbox
Pages = ["api.md"]
```

## [Quantum object functions](@id doc-API:Quantum-object-functions)
## [Quantum object (Qobj) and type](@id doc-API:Quantum-object-and-type)

```@docs
BraQuantumObject
Expand All @@ -27,74 +27,81 @@ SuperOperatorQuantumObject
SuperOperator
QuantumObject
Qobj
ket2dm
size
eltype
length
isbra
isket
isoper
isoperbra
isoperket
issuper
size
eltype
length
```

## [Qobj arithmetic and attributes](@id doc-API:Qobj-arithmetic-and-attributes)

```@docs
sqrtm
sinm
cosm
LinearAlgebra.tr
LinearAlgebra.svdvals
LinearAlgebra.norm
LinearAlgebra.kron
tensor
ptrace
tidyup
tidyup!
get_data
get_coherence
partial_transpose
```

## [General functions](@id doc-API:General-functions)
## [Qobj eigenvalues and eigenvectors](@id doc-API:Qobj-eigenvalues-and-eigenvectors)

```@docs
row_major_reshape
meshgrid
EigsolveResult
eigenenergies
eigenstates
LinearAlgebra.eigen
LinearAlgebra.eigvals
eigsolve
eigsolve_al
```

## [Qobj manipulation](@id doc-API:Qobj-manipulation)

```@docs
ket2dm
expect
LinearAlgebra.kron
tensor
sparse_to_dense
dense_to_sparse
tidyup
tidyup!
gaussian
ptrace
partial_transpose
negativity
entropy_vn
entanglement
expect
fidelity
wigner
get_coherence
n_th
tracedist
get_data
mat2vec
vec2mat
mat2vec
```

## [Quantum states, operators and super-operators](@id doc-API:Quantum-states-operators-and-super-operators)
## [Generate states and operators](@id doc-API:Generate-states-and-operators)

```@docs
spre
spost
sprepost
lindblad_dissipator
destroy
create
fock
basis
coherent
rand_dm
sigmap
sigmam
sigmax
sigmay
sigmaz
destroy
create
eye
qeye
fock
basis
coherent
rand_dm
projection
sinm
cosm
spre
spost
sprepost
lindblad_dissipator
```

## [Time evolution](@id doc-API:Time-evolution)
Expand Down Expand Up @@ -126,32 +133,35 @@ correlation_2op_1t
spectrum
```

## [Eigenvalues and eigenvectors](@id doc-API:Eigenvalues-and-eigenvectors)
## [Metrics](@id doc-API:Metrics)

```@docs
EigsolveResult
eigenenergies
eigenstates
LinearAlgebra.eigen
LinearAlgebra.eigvals
eigsolve
eigsolve_al
entropy_vn
entanglement
tracedist
fidelity
```

## [Low Rank internal APIs](@id doc-API:Low-Rank-internal-APIs)
## [Miscellaneous](@id doc-API:Miscellaneous)

```@docs
_calculate_expectation!
_adjM_condition_variational
_adjM_affect!
_adjM_condition_ratio
_pinv!
dBdz!
wigner
negativity
```

## [Miscellaneous](@id doc-API:Miscellaneous)
## [Utility functions](@id doc-API:Utility-functions)

```@docs
QuantumToolbox.versioninfo
QuantumToolbox.about
gaussian
n_th
row_major_reshape
meshgrid
_calculate_expectation!
_adjM_condition_variational
_adjM_affect!
_adjM_condition_ratio
_pinv!
dBdz!
```
22 changes: 17 additions & 5 deletions src/QuantumToolbox.jl
Original file line number Diff line number Diff line change
Expand Up @@ -36,24 +36,36 @@ import SpecialFunctions: loggamma
# to achieve better performances for more massive parallelizations
BLAS.set_num_threads(1)

# Utility
include("utilities.jl")
include("versioninfo.jl")
include("quantum_object.jl")
include("quantum_operators.jl")
include("general_functions.jl")
include("progress_bar.jl")

# Quantum Object
include("qobj/quantum_object.jl")
include("qobj/boolean_functions.jl")
include("qobj/arithmetic_and_attributes.jl")
include("qobj/eigsolve.jl")
include("qobj/functions.jl")
include("qobj/states.jl")
include("qobj/operators.jl")

# time evolution
include("time_evolution/time_evolution.jl")
include("time_evolution/mesolve.jl")
include("time_evolution/lr_mesolve.jl")
include("time_evolution/sesolve.jl")
include("time_evolution/mcsolve.jl")
include("time_evolution/time_evolution_dynamical.jl")

# Others
include("permutation.jl")
include("correlations.jl")
include("wigner.jl")
include("spin_lattice.jl")
include("arnoldi.jl")
include("eigsolve.jl")
include("metrics.jl")
include("negativity.jl")
include("progress_bar.jl")
include("steadystate.jl")

end
Loading

0 comments on commit 1fdc207

Please sign in to comment.