We study the optimal design of R&D policies and corporate taxation as a dynamic mechanism design with externalities using the tools of public economics. Firms are heterogeneous in their research productivity, i.e., in the efficiency with which they convert a given set of R&D inputs into...