We've stayed at the Sofitel at Madrid Airport. It doesn't matter what the surroundings are like because there's a metro stop outside the hotel, so you could be staying in any part of the city for that matter.
Also there's a courtesy bus to the airport, which is probably true for most of the hotels in this area. We've also camped at a site near Barajas before (I'm not saying that's what you should do!
) and took a bus into the Barajas district, where we had a good meal and took in a couple of good bars. Eddie can tell you quite a bit about this area. He's very knowledgeable about this neck of the woods, so send him a private message if he doen't see this?
If you can, try and see Aranjuez on your way up from Granada, even if it's just to drive through the town. If you do, carry on to Chinchon and maybe have lunch there before heading on to Madrid. You won't be disappointed.