By representing the states of the atomic f shell as the result of coupling four similar but independent quasiparticles, the Coulomb energy matrix can be calculated by extending standard angular-momentum theory from SO(3) to SO(7), where SO(7) is the special orthogonal group of transformations among the seven orbital states of an f electron. Both S (the total spin) and N (the number of f electrons) are good quantum numbers, and the coupled quasiparticle states can be put into a one-to-one correspondence with the classic states of Racah (1942). Each quasiparticle spans the elementary spinor (1/21/21/2) of SO(7). Only one of the four quasiparticle operators changes sign under the spin-quasispin interchange, and this is reflected in the properties of Racah's operators e2 and e3, the second of which decomposes into symmetric and antisymmetric parts. The selection rule Delta S=0 often reappears as a property of 9-W symbols, the analogues in SO(7) of the familiar 9-j symbols of SO(3). Several examples are worked out to illustrate the method.