You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+6Lines changed: 6 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,11 @@
1
1
# News
2
2
3
+
## v0.4.0 - 2024-11-26
4
+
5
+
- Add `OperatorBasis` and `SuperOperatorBasis` along with correspond `fullbasis` function to obtain these from corresponding instances of these objects.
6
+
- Change type parameters for `StateVector`, `AbstractKet``AbstractBra``AbstractOperator``AbstractSuperOperator` to elimitate datatype parameter and enforce them carrying their respective `Basis`, `OperatorBasis`, or `SuperOperatorBasis`.
7
+
8
+
3
9
## v0.3.6 - 2024-09-08
4
10
5
11
- Add `coherentstate`, `thermalstate`, `displace`, `squeeze`, `wigner`, previously from QuantumOptics.
Copy file name to clipboardExpand all lines: src/identityoperator.jl
+5-3Lines changed: 5 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -11,15 +11,17 @@ type which has to a subtype of [`AbstractOperator`](@ref) as well as the number
11
11
to be used in the identity matrix.
12
12
"""
13
13
identityoperator(::Type{T}, ::Type{S}, b1::Basis, b2::Basis) where {T<:AbstractOperator,S} =throw(ArgumentError("Identity operator not defined for operator type $T."))
14
+
identityoperator(::Type{T}, ::Type{S}, b::OperatorBasis) where {T<:AbstractOperator,S} =identityoperator(T,S,b.left,b.right)
14
15
identityoperator(::Type{T}, ::Type{S}, b::Basis) where {T<:AbstractOperator,S} =identityoperator(T,S,b,b)
15
-
identityoperator(::Type{T}, bases::Basis...) where T<:AbstractOperator=identityoperator(T,eltype(T),bases...)
16
+
identityoperator(::Type{T}, b::OperatorBasis) where {T<:AbstractOperator} =identityoperator(T,eltype(T),b)
17
+
identityoperator(::Type{T}, bases::Basis...) where {T<:AbstractOperator} =identityoperator(T,eltype(T),bases...)
exp(op::AbstractOperator) =throw(ArgumentError("exp() is not defined for this type of operator: $(typeof(op)).\nTry to convert to dense operator first with dense()."))
0 commit comments