Only a small fraction of galaxies actually have two spiral arms! Even if we ignore the entire class of galaxies dubbed “ellipticals”, which have no spiral arms at all, there are a ton of spiral galaxies with a number of arms not equalling two.
Spiral galaxies are one half of the larger galaxy population; the overall population is generally divided into spirals and ellipticals. Spirals are also known as “late type” galaxies, and ellipticals as “early type” galaxies. This, along with many other unfortunate naming conventions in astronomy, is for historical reasons. Edwin Hubble was one of the first people to try to classify galaxies by any method, and he developed a system that we’ve since dubbed the “tuning fork diagram”, which puts the smooth, featureless ellipticals one one side, and spirals on the other side. The two tines of the tuning fork are for those galaxies with bars, versus those galaxies without. In a footnote of a paper in 1926, he assigns the elliptical galaxies the moniker “early” and spirals the term “late”, as a way of marking a progression from simple to complex structures.
As we have since learned, early-type galaxies are actually the oldest galaxies in existence at any point in time, and are thought to be created through the destruction of numerous late-types, so this ‘early’ and ‘late’ naming system is very precisely backwards. (But professional astronomers still use it.)
Looking at the spiral galaxies, a few things will pop out; the first being this large division between bars and no bars. All the barred galaxies on this diagram are drawn with only two arms, but this isn’t always the case. Our own galaxy, the Milky Way, has a central bar, and well more than two spiral arms. In fact, if you look at our best maps of the Milky Way, not only do we have more than two spiral arms, but we also have these smaller branches (sometimes labeled “spurs” between the galaxies, as the arms themselves fork and divide. It’s within one of these little offshoots that our solar system resides, about two thirds of the way out from the center of the galaxy.
The Milky Way is hard to look at, since we’re embedded within it, but galaxies which are close to us are easier to observe. So Andromeda, a galaxy which is slightly larger than our galaxy, and very nearby, ought to be easier to observe. Andromeda also doesn’t appear to have strong spiral arms; it shows dark dust lanes, but not the prototypical idea of strong arms, winding around a bright nucleus.
If we look back to our Hubble diagram, on the top left, there’s a kind of many-armed sea-star looking galaxy; this is actually a remarkably common style of galaxy, and the non-barred counterpart to our own galaxy.
There is a fun class of galaxy which is (really, in all seriousness) technically called “flocculent spirals”. These galaxies are defined by a total lack of strong arms; they have tufts and wispy bits, but nothing so dramatic as a spiral arm. (Flocculent, in case you are curious, is defined to mean “wool-like”, which is a rather pleasing mental image for describing the disk of a galaxy.)
After all this, I’d forgive you for thinking that this distinct spiral arm thing is complete gibberish, but there are still plenty of galaxies out there with strong, definite spiral arms, with very little filling in the gaps between those arms. These galaxies have the delightful name of “grand design spirals.” Grand design spirals (which make up only about 10% of galaxies) tend to have 2 or 4 strong spiral arms, and they’re often extremely photogenic and pleasingly symmetric objects in the sky. But the method of forming and maintaining those arms has been remarkably hard to explain.
The problem with explaining spiral arms lies fundamentally in that the components of a galaxy rotate at different speeds; the inner part of the galaxy rotates faster than the outer parts. So the easiest explanation — that the arms are actually just areas of the galaxy that are physically more dense, and a fixed association — doesn’t work. The problem is easily demonstrated with some string (or a cable you don’t care about), by winding it up around your finger. If the arms are a physical thing, like the cable, the inner part of the galaxy will rotate many more times than the outer part will, so the spiral arm will end up “tightly wound”. The cable/string wound around your finger doesn’t look so much like a spiral arm as it does a series of circles, and so tightly wound that you wouldn’t be able to distinguish the spaces between the arms.
So any solution to this problem has to mean that the spiral arms can’t be a physical thing. So far the best explanation is called Density Wave Theory, which is effectively what happens if you have a traffic jam going in circles. The wave is a compression of the material that already exists in the galaxy, but stars aren’t fixed to a location “inside” or “outside” of the spiral arm. Like cars passing through a traffic jam, while the stars are within the arm, they’re in a very tightly packed region of space (and therefore quite bright), but they’re not stuck there forever, and eventually they will pass onwards, as the density wave moves past them.
There’s one other reason you can see galaxies with two spiral arms, and it’s a reason close to my science heart. Interactions between galaxies can cause the galaxy to be strongly distorted, due to intense gravitational tides. Like the tides on Earth, this stretches out the galaxy, and pulls material out into two “arms”.
Unlike the quieter grand design spirals, these are not formed by density waves but by gravity, and so these arms are dubbed “tidal arms”. These tidal arms are often quite dramatic, stretching across many hundreds of thousands of light years. They are markers of a near collision in the past, and often foreshadow a more dramatic collision with a companion in the relatively near future, where it and its companion will merge into a single, newly built object.
Have your own space question? Feel free to ask!