rmjarvis / TreeCorr

Code for efficiently computing 2-point and 3-point correlation functions. For documentation, go to
http://rmjarvis.github.io/TreeCorr/
Other
99 stars 37 forks source link

Add spin-3 and spin-4 correlations. #160

Closed rmjarvis closed 1 year ago

rmjarvis commented 1 year ago

@gbernstein wants the ability to do spin-4 two-point correlations for BFD shear measurements (to handle the 2x2 R matrix properly). So this PR adds that capability to TreeCorr. Since I now have spin-0, 1, 2, and 4, I decided not to omit 3, so that's here too.

The TreeCorr API using single letters for each field type, so I decided to go with T for spin-3 (short for trefoil) and Q for spin-4 (short for quatrefoil, a word that I hadn't realized I didn't know how to spell properly until looking it up). Those seemed like the most salient things that have the right spin properties in each case (ornamental shapes with 3 or 4 lobes respectively).

As for V (spin-1, cf. #158), I didn't do any cross-spin combinations. So you currently cannot do VQ or TG, etc. Just NT, KT, TT, NQ, KT, QQ. If anyone has an application where they want cross-spin types, it's not hard to add, but I didn't want to implement things that no one would use.