The battery was bulging slightly, warping the bottom of the laptop. I found several references to this in Mac forums as a symptom of an aging battery. I noticed that it was difficult to get the MagSafe power adapter to recharge the battery sometimes: I had to keep reseating the adapter until the light started glowing. I thought replacing the battery might help with this as well.
There's nothing to it. Shut down the Mac, turn the slot with a coin, pop out the old battery, slip in the new one, and charge it up overnight.
Replacing the battery did not help with the charging issue. (I still think it is worth it to have a healthy battery that holds a charge longer.) I discovered that the MagSafe adapter port on the side of the MacBook had attracted a used staple that was hiding in one corner. Of course this made it harder to get the adapter to sit properly. Once I realized it was there, it was easy to remove. The adapter is still finicky. When I borrow a newer adapter the problem seems to go away.