Fix factoring