turn factorial into a sum instead