 In this case the partition function can be represented as a determinant of a matrix (whose dimension is equal to the size of the lattice), but in other cases the enumeration of formula_18 does not come out in such a simple closed form.Clearly, the largest formula_18 is given by "free" boundary conditions (no constraint at all on the configurations on the boundary), but the same formula_18 occurs, in the thermodynamic limit, for periodic boundary conditions, as used originally to derive formula_49.The number of states of an ice type model on the internal edges of a finite simply connected union of squares of a lattice is equal to one third of the number of ways to 3-color the squares, with no two adjacent squares having the same color.