Most estimates say if you want to do permaculture/homestead living and provide your own calories you need a good acre per person and a taste for sweet potatoes...
Even if apartment buildings are too dense, I still think we will see an increase in eco-village type arrangements.
One person needs about 5 hectares of land to be self-sufficient (i.e. to cover all its food needs, including protein). If you can afford your own 432 Park Avenue (Cost: ~$1BUSD, Floor area: ~4ha) for that, then the answer is yes.
But also, with that same $1BUSD you could buy around 100,000 hectares of land in rural US, close to the size of Qatar; you can see how relatively inefficient vertical farming is in economic terms.
That 5 hectares of land per person metric is totally inapplicable here. Sort of the entire point of vertical farming is to be (in theory) vastly more efficient per unit of land. If you believe the claims it's somewhere between a 10 and 50 times reduction in land usage for same output.
5 hectares is also on the very high end for estimates of that metric. It also drops hugely if you're not relying on animal products.
I don't think vertical farming in apartments is the future, but I think your calculations here are also way, way off.
That’s about a fifth of an acre, and other caveats apply like climate and the amount of labor during the growing season. If vertical farming works, and can also reduce the labor required (I have no idea if that’s one of its goals), it starts to look more plausible as something that could take off. Still won’t fit on a rooftop though, and as Jayne would say, “I smell a lotta ‘if’ coming off that plan.”
https://www.growveg.com/guides/growing-enough-food-to-feed-a...
Also, I'm sure that if humanity had put enough resources to this we would already have really efficient solutions around this. It tech that needs to (and hopefully will) be developed.
This has been tried (and proved wrong) countless times. The issue is that it needs a huge footprint, and space is something you don't have at large in apartment buildings.