Oh, so forced labour then?
I’m sure the next objection will be “what, so you’re going to concentrate them in some kind of camp?” Yes because that’s the smart thing to do with a large scale problem. Use scalable solutions.
But the mentally unwell person didn't force society to pay for their living expenses. Society decided it couldn't stand them living their life the way they were and locked them up.
Society pays for locking people up because it is done for the benefit of society. The point is that a functioning society is more productive than an unorganized one, and so can afford to do that kind of thing.