The hospital may receive tax dollars, but it is not a public place like the sidewalk. You can be kicked out of a hospital for a variety of reasons, including violating hospital rules on smoking. You can't (generally) be kicked off a sidewalk.
This smoking ban was put into affect after I had worked there and smoked in the designated area. Smokers pay more for health insurance offered by the hospital.