The Evolution of the IR Luminosity Function and Dust-obscured Star Formation over the Past 13 Billion Years