where v = tanh ⁡ ⁡ K and w = tanh ⁡ ⁡ L . Since there are N horizontal and vertical edges, there are a total of 2 2 N terms in the expansion. Every term corresponds to a configuration of lines of the lattice, by associating a line connecting i and j if the term v σ σ i σ σ j (or w σ σ i σ σ j ) is chosen in the product. Summing over the configurations, using