Set fermion sign in new operation - #135
Open
marcusr2ML wants to merge 1 commit into
Open
Conversation
This flag was missing, so spinless fermions were getting very wrong results.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fermion flag was missing, so spinless fermions were getting very wrong results.
As a follow up to this, more unit tests might be necessary for dmrg.
Summary
In making a tutorial for spinless fermions I saw that hardcore bosons performed as expected, while bonfied spinless fermions did not. This remained true for a lattice with a single site.
Diging into this it was revealed the Hamiltonian was not Hermitian. Changing this flag resulted in the results to converge to the known answer for the GS energy of a free chain.
I tested the lattice and Hamiltonian by:
i.) Running dmrg on the lattice with hardcore bosons (correct result)
ii.) Running ED with the lattice and spinless fermions (correct result)
iii.) Running dmrg with the lattice and spinless fermions (incorrect result)
iv.) After updating the flag, iii worked fine
Testing
Using the attached .md file (the spinless fermion tutorial of interest), test this issue on the old vs new code. The .md file for the tutorial is attached here where the lattice and parameters are defined. It might be a good idea to build your own lattice and Hamiltonian to check against what I did.
dmrg09.md
Type of change
Testing
For simulation code changes
Checklist
-Wall -Wextra)Related issues