Skip to content

Commit

Permalink
Update bosefs.jl
Browse files Browse the repository at this point in the history
  • Loading branch information
Skuwar1 authored Jun 10, 2024
1 parent eb3b300 commit 5574a18
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions src/BitStringAddresses/bosefs.jl
Original file line number Diff line number Diff line change
Expand Up @@ -328,15 +328,12 @@ function hopnextneighbour(b::BoseFS{N,M,A}, chosen) where {N,M,A<:BitString}
end
return BoseFS{N,M,A}(new_address), prod
end

function hopnextneighbour(b::SingleComponentFockAddress, i)
src = find_occupied_mode(b, (i + 1) >>> 0x1)
dst = find_mode(b, mod1(src.mode + ifelse(isodd(i), 1, -1), num_modes(b)))

new_b, val = excitation(b, (dst,), (src,))
return new_b, val
end

"""
new_address, product = hopnextneighbour(add, chosen, Val(pitwisted), Val(hard-wall))
Expand Down Expand Up @@ -364,10 +361,8 @@ julia> hopnextneighbour(BoseFS(1, 0, 1), 3, Val(false),Val(true))
(BoseFS{2,3}(2, 0, 0), 0.0)
```
"""

function hopnextneighbour(b::SingleComponentFockAddress, i, ::Val{PITWISTED}, ::Val{HARDWALL}) where {PITWISTED, HARDWALL}
new_b,val=hopnextneighbour(b, i)

if (find_occupied_mode(b,1).mode==1 && i==2) ||
(find_occupied_mode(b,num_occupied_modes(b)).mode == num_modes(b) && i == (2*num_occupied_modes(b)-1))
if PITWISTED
Expand All @@ -382,10 +377,6 @@ function hopnextneighbour(b::SingleComponentFockAddress, i, ::Val{PITWISTED}, ::
end
end





"""
bose_hubbard_interaction(address)
Expand Down

0 comments on commit 5574a18

Please sign in to comment.