$$ n_{i} = \left\{\begin{array}{l}1\\0\end{array}\right. $$
$$ {\cal H} = \displaystyle\sum_{i}\varepsilon_{i} n_{i} + \sum_{\langle i, j\rangle}U_{ij} n_{i} n_{j} + \cdots $$