There's also the option of a taxi. If your layover time is tight, I'd take the cercanias to Atocha, since it won't get stuck in traffic. But a taxi is a fixed rate of €30 to Atocha (and indeed to a large area of central Madrid), and there's no need to tip beyond this. This would be much easier than bus or train, and if you're taking the risk of traffic anyway by using the bus, I'd opt for the taxi instead.
Madrid airport is HUGE. Particularly if you're arriving from the US on Iberia (terminal 4S), it will take some time to get to terminal 4 where you go through immigration, before you can even consider leaving the airport to get to the city. Other nonstops from the US use other terminals which aren't quite as gigantic.
Which airlines are you using, where are you coming from and going to, and what are your scheduled arrival and departure times? With this information, people can give better advice.