partially fix #111 / improve minimalPrimes
decompose optimize
doc degree change
fix sign bug in factor
degree doc change
add degree test