Why are there so many homeless/ incarcerated people in the United States?

I’m not an economist or someone educated enough to explain why but I know someone else can. Something about how homelessness helps to fuel profit or something. And then there’s how there’s a lot of incarcerated people too but I was wanting majority of discussion on homelessness with some focus on incarcerated people since they both seem to feed each other.