-
Notifications
You must be signed in to change notification settings - Fork 26
Add correlator for InfinitePEPO (mixed state) #274
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
lkdvos
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks good to me!
I do think I slightly disgree with putting the logic for the correlators in the contractions folder. If possible, I think I would put only the contractions there, while keeping the actual correlator logic in a separate file.
|
I can move the redefinition |
lkdvos
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think my original motivation for the contractions folder was to have a place to put an implementation for some of the contractions that clutter up the main logic of the algorithms. So in some sense, I would have put only the @tensor calls in there, and the generated functions.
I do think the algorithms/correlators.jl file made sense, so I would rather keep that logic there if you don't mind.
I additionally had a look in a bit more detail about the transfer logic, and I think it would make more sense to follow the previous/other strategies a bit closer, rather than using _transfer_left directly.
|
Your PR no longer requires formatting changes. Thank you for your contribution! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have moved correlator_horizontal, correlator_vertical and the extension of MPSKit.correlator back to src/algorithms/correlators.jl.
To really using the V * T syntax, I need some help in figuring out the fermion twists to be added to the planar transfer_left.
|
Okay, to move forward with this. While it does kind of stall progress here, I think it's not too much of a detour to properly address the transfer function confusion between MPS and CTMRG environments here. I would suggest to
I can give this a go tomorrow morning. Having originally introduced the As a side note, having to think about all of this again made me realize that probably our correlation length implementation is most likely just wrong for fermionic systems. We currently compute a transfer matrix spectrum using (in the end) |
|
I suggest the slightly more verbose names |
|
I don't think this is linked to CTM though, I would argue that actually there might even be a case to be made for just using |
|
I had a go at the edge transfer matrices like I said. I think I changed all the relevant bits, and also updated the correlation length implementation in the process so that should now work for symmetries with non-trivial twists. Some things I'm not entirely sure about:
|
|
There are problems when the physical space is a dual space. I'll try to solve them later. |
|
@lkdvos I'm now sure that either using Random
using TensorKit
using PEPSKit
Random.seed!(0)
V1 = Vect[FermionParity](0 => 2, 1 => 2)
V = V1' ⊗ V1' ⊗ V1
# create a positive operator
ρ = randn(V → V)
ρ = ρ * ρ'
A = id(V)
PEPSKit.trmul(A, ρ) / PEPSKit.str(ρ) # not equal to 1 |
|
Yeah, these functions don't actually do anything particularly smart, I think they really just build the |
leburgel
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added some commentary on things that I think should be reviewed again, other than those this seems good to go for me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks good to me, I'm fine with the names, I dont think there are that many better options and I also don't think it matters too much. I have some final small comments, but otherwise should be good to merge for me
This PR generalizes
correlatorto calculate correlation functions ⟨O(i, j)⟩ between two sites (i, j) in the same row/column in a 1-layer InfinitePEPO ρ (mixed state). Only tr(ρO) is implemented. ⟨ρ|O|ρ⟩ is not intended to be treated here.To do: