Some key issues: First, and in general, let's use our heads and not follow anti-thinking, anti-science, Republican slogan "economics" which says any government role or action is inefficient and the pure free market is always more efficient and better.
As acclaimed growth economist Paul Romer points out in a nice interview in Reason, the economics of ideas (understandings, writings, formulas, etc.) is very different from the economics of physical things (and products, etc.). Unlike physical things, ideas have little or no marginal cost (the cost of letting an additional person have and use them). So, for efficiency, widespread distribution is very important, and that often means the government doing it (or the government paying universities or private firms to do it), and then releasing it free over the internet. Or the government having some other important role.
Suppose some firm gains an important understanding of how a gene works. They will want to keep it secret so that their competitors can't use it. And they can't sell it, because once it gets out, it can be told to anyone for free. Moreover, you really can't patent a basic understanding or idea. Legally it's way too costly to adjudicate bazillions of lawsuits to determine did product X result 1/1000 from this patented understanding, or 1/5000, and so on.
In addition, aside from that, there is the issue of the inability to price discriminate well. Even if the idea, or understanding, or knowledge is patented, and they charge $1,000 for it, then there may be 100,000 scientists who won't have access to it because their marginal utility for it is $999 or less. But that's inefficient, because you could have provided it to them for zero marginal cost.
So basically, if the government pays for it, it's put on the internet and used by, in many cases, 1 million scientists and technicians, instead of just the perhaps 100 scientists and technicians in some private company keeping it secret. The gross inefficiency of the underutilization can be enormous.
So some government role is often crucial to efficiency when it comes to production and utilization of ideas, either the government doing it itself, or paying universities or private firms to do it, or providing key rule and regulations. So this is no area for us to turn off our brains and become Republicans.