Human capital formation, research and development and innovation