Let's do out the math on this... A subway tunnel might have a diameter of about 6 meters, so cross section = 3 * 3 * pi = 28 square meters. Digging subway tunnel through rock costs about $100M per kilometer. On the one hand, these holes would be vertical, which is harder than horizontal; on the other hand, they wouldn't need ventilation and train tracks and stuff. Let's handwave and say it's $100M for a 1 km deep hol…
wouldn't this last a lot longer than lithium batteries?
If you assume that the thing lasts forever, well, you divide $x/infinity so it's free. EXCEPT that you've got $x tied up that could be earning interest instead. So it's not $x/infinity, it's the opportunity cost on $x versus anything else out there like batteries, the grid, etc.