Hello,
Working with the Hubbard class, I'm trying to compute the double occupancy
$$
d=\sum{i=1}^{L} \langle n{i \uparrow} n_{i \downarrow} \rangle .
$$
Browsing through the documentation, I found two possible syntaxes for defining the corresponding operator at site i, namely:
ITensor dop1 = sites.op("Nupdn",i);
ITensor dop2 = sites.op("Nup*Ndn",i);
and both give the correct result.
However, after reading the documentation page about local measurements (http://itensor.org/docs.cgi?page=formulas/measure_mps) it is very tempting to try to define the double occupancy operator as:
ITensor dop3 = sites.op("Nup",i)*sites.op("Ndn",i);
This syntax, however, raises a "Mismatched IQIndex arrows" error.
Any thoughts about this?