Skip to content

Commit

Permalink
minor fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
jebej committed Oct 30, 2023
1 parent 960dbaf commit 6b4b933
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/library/states.jl
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Returns a dense vector.
```jldoctest
julia> coherent(6,0.4+1im)
6-d Ket{Vector{ComplexF64}, 1} with dimensions 6
0.60∠68°|1⟩ + 0.56∠-0°|0⟩ + 0.46∠136°|2⟩ + 0.29∠-155°|3⟩ + 0.15∠-87°|4⟩ +…
0.60∠68°|1⟩ + 0.56∠0°|0⟩ + 0.46∠136°|2⟩ + 0.29∠-155°|3⟩ + 0.15∠-87°|4⟩ +…
```
"""
function coherent(N::Integer, α::Number, analytic::Bool=false)
Expand Down
2 changes: 1 addition & 1 deletion src/math/superops.jl
Original file line number Diff line number Diff line change
Expand Up @@ -122,4 +122,4 @@ function check_choi(C::Operator{T,D}) where {T,D}
return prod(i->dm[i],1:D÷2)
end

_half_dims(dm::Dims{D}) where{D} = ntuple(i->dm[i],D÷2)
_half_dims(dm::Dims{D}) where {D} = ntuple(i->dm[i],D÷2)
2 changes: 1 addition & 1 deletion src/misc/utils.jl
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ function expim!(R::Matrix, dv::AbstractVector, dl::AbstractVector, B=similar(R))
B[i,j] = a * DU[i,j]
end
end
return mul!(R, B, adjoint(DU))
mul!(R, B, adjoint(DU))
return R
end

Expand Down
2 changes: 1 addition & 1 deletion test/twoqubit.jl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Two-qubit stabilizer states from Table II in
# Garcia et al. Efficient Inner-product Algorithm for Stabilizer States.
# arXiv:1210.6646 (2012)
TWOQUBIT = Ket.(normalize!.(Vector{Complex{Float64}}[
TWOQUBIT = Ket.(normalize!.(Vector{ComplexF64}[
# Separable states
[0,0,1,0],[0,0,0,1],[0,0,1,1],[0,0,1,-1],[0,0,1,1im],[0,0,1,-1im],
[1,0,-1,0],[0,1,0,-1],[1,1,-1,-1],[1,-1,-1,1],[1,1im,-1,-1im],[1,-1im,-1,1im],
Expand Down

0 comments on commit 6b4b933

Please sign in to comment.