A central feature of the microwave background fluctuations are randomly placed spots with an apparent size ~1 degree across. These are produced by sound waves that travel through the hot ionized gas in the universe at a known speed (the speed of light divided by the square root of 3) for a known length of time (380,000 years). By using the relation: distance = rate * time, we can infer the distance the sound travels, and thus the actual size of a typical hot (compressed) or cold (rarefacted) spot. By comparing the apparent size of the spots to their known actual size, we can measure a combination of the distance to the last scattering surface and the curvature of the light path between us and this surface, which depends on the geometry of the universe. Then If we independently know the Hubble constant, we can determine the distance to the last scattering surface and thus use the spot size to determine the geometry uniquely.
The figure below illustrates this situation with two possible outcomes. The red lines indicate straight light paths to us from opposite sides of a typical hot spot in the CMB, as would be the case in a “flat” universe; the gray lines indicate corresponding curved light paths as they would appear in a universe with “negative curvature”. By measuring the apparent (angular) size of these spots we can infer which sets of lines the light followed to reach us. We use the location of the main peak in the temperature spectrum to determine the average apparent spot size: in a flat universe the main peak occurs at l~220, while a negatively curved or “open” universe has a peak farther to the right, and vice versa for a closed universe.