While the example below is developed for the one-dimensional case, many of the arguments, and almost all of the notation, generalizes easily to any number of dimensions. Some of the formalism is also broad enough to handle related models, such as the XY model, the Heisenberg model and the N-vector model.