A new algorithm for solving differential equations of Lane-Emden type