It's because such research has no obvious initial use that the public must pay for it; no private enterprise will fund it, and often it will be useless knowledge, but occasionally someone will figure something out that unlocks a whole new understanding of the world.