Ligand binding to a linear lattice composed of N sites, under general conditions of cooperativity and number of sites covered upon binding, m, is approached in terms of the theory of contracted partition functions. The partition function of the system obeys a recursion relation leading to a generating function that provides an exact analytical solution for any case of interest. Site-specific properties of the lattice are derived from simple transformations of the analytical expressions. The McGhee-von Hippel model is obtained as a special case in the limit N --> infinity. The derivation is straightforward and involves no combinatorial arguments. Partition functions and site-specific properties are also derived for the case of non-cooperative binding to a two-dimensional torus of length N, containing s sites in its section for a total of sN sites. The torus provides a relevant model for ligand binding to double-stranded DNA (s = 2) or protein helices (s = 3,4). It is proved that non-cooperative binding to the two-dimensional torus can mimic cooperative binding to a one-dimensional linear lattice when m = s. The dimensional embedding of the lattice and the geometry of interaction of its sites play a crucial role in defining the binding properties of the system accessible to experimental measurements. Hence, caution must be exercised in the interpretation of Scatchard plots in terms of the one-dimensional McGhee-von Hippel model, especially when m less than or equal to 4 and the geometry of the system is clearly two-dimensional.