+1 vote
asked by (1.1k points)
retagged by

I know that ITensor has support for spin-1/2 and spin-1 sites, but is there a way for one to construct sites of higher spins (3/2, 2, 5/2, etc.)? I don't think I will be interested in using these immediately, but I may find them helpful in the near future, so I was curious.

I know that there is the whole business of angular momentum addition (e.g. 1/2 x 1/2 x 1/2 = 1/2 + 1/2 + 3/2), as explained in sources like https://ocw.mit.edu/courses/physics/8-05-quantum-physics-ii-fall-2013/lecture-notes/MIT8_05F13_Chap_10.pdf. So one can create something mathematically equivalent to a higher spin site by stitching together many spin-1/2 or spin-1 sites, but then this forces us to somehow project out the extra unwanted parts. Is this possible in general in ITensor, and if so, is there a recommended principled way of doing this?

In terms of longer-term plans for ITensor, is there a plan to ever add support for any higher spin sites (even if it's just a little higher, like 3/2 or 2)? I can totally understand if the answer is no, since I'm guessing people don't find too much use for spin sites other than 1/2 and 1, but I am interested. Along these lines, is there anything fundamental that would prevent the developers of this code from implementing support for a spin site of arbitrarily high spin (or at least up to some higher limit, like 5 or 10 or something), where the user could specify the spin that they want for that site?

commented by (70.1k points)
Hi Sujay, we'll answer your question soon, but before that are you primarily asking about the C++ or Julia version of ITensor?

By the way, we do already have support for S=2 and a "custom spin" site type that can do any spin (currently offering only Sz, S+, S- operators). I can explain more in a detailed answer but wanted to ask about the language first.
commented by (1.1k points)
Hi Miles,

This is primarily about the Julia version of the code.

Thanks,
Sujay
commented by (70.1k points)
Thanks, ok so good news there: we have expressly designed the Julia version to be very easy to extend to new site types (new physical degrees of freedom). What I'll do is post an official answer later below once we have documented this system better on the ITensor website. But for now the short answer is that if you look at the files for the S=1/2 case:
https://github.com/ITensor/ITensors.jl/blob/master/src/physics/site_types/spinhalf.jl
and S=1 case:
https://github.com/ITensor/ITensors.jl/blob/master/src/physics/site_types/spinone.jl

All you have to do is make a similar file and include it into your own code with the proper definitions for the spin type you want.

But we'll post a detailed tutorial on the website later, probably using S=3/2 as the example, and explaining in more detail what each part of the code in those files does. If you do try it yourself right away, feel free to post some questions about things you encounter and we'll be happy to answer.

Circling back to the original question, there are essentially always more types of sites that people ask about than we can really add, so our goal is to make it easy to add custom site types yourself. Sort of the "teach a man to fish" approach.

Miles

1 Answer

0 votes
answered by (70.1k points)

Hi Sujay,
Thanks for the question. This is something we are hoping to make easier in the Julia version of ITensor compared to the C++ version, where it was possible to make custom site types / physical degrees of freedom.

I have just created a comprehensive example and discussion on the ITensor website here:
http://itensor.org/docs.cgi?vers=julia&page=formulas/site_type
using the case of S=3/2 as the example.

Please let me know if this covers your question, if the code works for you, or if you have any questions about the writeup there.

I should post another example about how to mix different site types together, but basically it's as simple as making an array of indices where every other Index object carries a different tag corresponding to the types you want. So like alternating between "S=1/2" and "S=3/2" tags for example, with the indices also having the appropriate dimensions of 2 and 4 respectively.

Best regards,
Miles

Welcome to ITensor Support Q&A, where you can ask questions and receive answers from other members of the community.

Formatting Tips:
  • To format code, indent by four spaces
  • To format inline LaTeX, surround it by @@ on both sides
  • To format LaTeX on its own line, surround it by $$ above and below
  • For LaTeX, it may be necessary to backslash-escape underscore characters to obtain proper formatting. So for example writing \sum\_i to represent a sum over i.
If you cannot register due to firewall issues (e.g. you cannot see the capcha box) please email Miles Stoudenmire to ask for an account.

To report ITensor bugs, please use the issue tracker.

Categories

...