Cool topic, huh?
Anyhow, there are a lot of people who do not seem to get that certain systems have an inherent logic, like free markets for example but also socialized systems.
Utilitarianism is the creed of the greatest good for the greatest number. This runs into some logical problems (see mere addition paradox) and is almost never relevant when it comes to social systems.
What we have here usually is average utilitarianism which is basically either the idea to maximize the average utility for a given number or to have a group with as high an average utility as possible, period.
The problem is the same that a lot of welfare problems run into, i.e. that money does not equal utility. Some people are way more efficient at converting money into utility than others so if you wish to achieve the maximum “welfare” you must concentrate your resources on those.
F.e. why replace hips for over 80 year olds if you can also pay for cancer research for the young? Why treat the severely handicapped when all the amount of money you put into them can only marginally better their life? Does it make sense to allow children to be borne that would have costly life long diseases?
And finally, if you want to be consistent, why not get rid of those who are a burden to the system and not very likely to contribute to it ever again?
There is no ill will in all of this, it is just that if you want to find some ethical way of allocating resources, which you will have to do when the market does not do it for you, you must simply put your money where it will make a difference.
So, nobody will pull a plug on grandma, she will never get a plug in the first place.