What is the point of public transport?

What is the point of having public transport? What’s it for? That’s what I was thinking about driving around Frankfurt-am-Main. You see, in my mind, the point of public transport was always to provide a means of transport that is cheaper than driving cars. This includes providing transport for those who cannot afford cars, that’s the same thing. Interestingly, it does not seem to be the case in Germany.

The public fare from Darmstadt to Frankfurt-am-Main with the S-Bahn (suburban train) is 8 euro one way. The distance is only 35 kilometres center to center, so by car you would spend less than 4 Euro including maintenance costs and depreciation. Even if you were to drive alone, it would make perfect sense to go by car instead of public transport.

So it turns out that the public transport in Germany is twice as expensive as driving cars. What is it for then?