Short answer: because some bike racks are really unsafe to park my beloved bike at. You have seen many of them, they are the low racks like the one in the picture above, where you can only lock either a front or a back wheel with a U-lock (much harder to break than the cable version) and no part of the bike frame. So, locking my bike up there means there's a good chance of me coming back out of the library/restaurant/shop only to find a wheel locked to the rack... without the rest of the bike. A road bike wheel is expensive. Yes. But not nearly as expensive as the rest of the bike!
Another library, another bad bike rack (there's no way you can U-lock any part of the bike frame to this rack). Luckily this one is surrounded by metal railing, so I locked my beloved Giant Defy to the railing instead, and so did a recumbent cyclist who got there before I did.
It bugs me a bit that many bike shops around town only offer bad bike racks like this one in front of their store. There was no other bike around, so I managed to lock the frame to it by taking up two spaces instead of just one. I wonder how many bikes get stolen from in front of bike shops each year. I mean... what better setting for a thief to just grab a bike and ride off than in front of a bike shop that offers no sight-line to the bike rack from inside the store? I mean, people do that all day long there... going off test-riding bikes that they didn't arrive on. A bike thief would blend right in!
Now these are good bike racks for a change. I can U-lock the frame and the rear wheel (the two most expensive parts of the bike) to these racks. We need more of them around!