-
Notifications
You must be signed in to change notification settings - Fork 41
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
Sectors improvements #97
Conversation
I can agree with most of these changes, but we might want to think about projective representations a bit more carefully. Strictly speaking, Zn and U1 don't have (nontrivial) projective representations. Furthermore, projective representations, when they exist, are necessarily higherdimensional. For the case of U1 specifically, it should always be possible to shift the fractional charge to an integer charge, although I can see why this can sometimes be "convenient". True projective representations exist for O2 = CU1, but there only half-integer charges make sense. For convenience, I've also allowed half-integer U1 irreps, but I think already that one has some flaws. The problems start with the categorical interpretation as the set of (representatives of) isomorphism classes of simple objects, and thus in particular, with iterating over all of them. For U1, I iterate over both the integer and half-(odd)-integer values, but that might not be what is intended. For the PU1Irrep implementation here, you iterate over integer differences with respect to the starting charge, but that means that if the initial charge is fractional, the set over which you iterate does not contain the zero charge, and so it does not represent the simple objects of a tensor category (as there needs to be a unit object). Let's discuss this at the office. |
* `FermionParity` -> `fℤ₂` * `FermionNumber` -> `fU₁` * `FermionSpin`` -> `fSU₂`
This might need some more theoretical foundation, which we can add at a later point
This keeps `FermionParity` as the default representation for fermionic charges. While not (yet) removing `fℤ₂` from the library in order to not break existing code, the idea is that `fℤ₂` has more of an interpretation as category, and the sectors should really be thought of as objects in this category. This is similar to how `ℤ₂` is the group, and the sectors are `ℤ₂Irrep`. However, `fℤ₂` is not a group, and thus labeling the sectors as irrep is not entirely correct. Possibly, we can think of adding categories and objects at some point, but this is outside of the scope of this pr
I have removed the |
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## master #97 +/- ##
==========================================
+ Coverage 81.34% 81.37% +0.02%
==========================================
Files 42 42
Lines 5549 5562 +13
==========================================
+ Hits 4514 4526 +12
- Misses 1035 1036 +1 ☔ View full report in Codecov by Sentry. |
Looks good to me, so I have merged. |
Adds some small quality of life improvements:
ProductSector
s can now usegetindex
to access the component sectors, anditerate
to allow easy destructuring. This removes the need for knowing the internal structure/fieldnames of these objects.U1
, by usingPU1
/PU1Irrep
. This is useful in the context of quantum systems that useU1
in relation to particle number conservation, and allows fractional occupation numbers.Some remarks/questions:
PU1Irrep
iterates through its values by only taking charges that are an integer value away from the starting point, which defaults to 0, thus only giving integer values. It is possible to iterate through all rational numbers in a somewhat reasonable fashion, but this is not compatible with ordering them based on their magnitude. I don't see a very elegant solution to this, and will just assume that iterating through all values ofPU1Irrep
is not something that is used. The only other solution I can think of consists of defining a "rescaled/shifted U1", which would just take two parametric values to denote the shift and scale, which corresponds to what numerators and denominators are allowed. This would then be mostly equivalent to regular U1. While this might be somewhat reasonable from the physics point of view, I am hesitant to implement this as shifting the unit feels weird in the context of group theory.U1Irrep
allows half-integer charges, which would technically fall under the projective representations. We could remove this, but that would constitute a (unnecessary?) breaking change.