Godtone
Joined 17 December 2020
m →My Python 3 code: allow using factorization to avoid re-factorizations |
m →My Python 3 code: fix sopfr |
||
| Line 1,253: | Line 1,253: | ||
f[0] = num2s # restore | f[0] = num2s # restore | ||
if func==3: | if func==3: | ||
return sum([ prime_idx(i)*f[i] for i in range(len(f)) ]) | return sum([ prime_idx(i)*abs(f[i]) for i in range(len(f)) ]) | ||
return no2s_x[0]*no2s_x[1] if func==2 else math.log(no2s_x[0]*no2s_x[1], 2) if func==1 else func(x, f, no2s_x[0], no2s_x[1]) | return no2s_x[0]*no2s_x[1] if func==2 else math.log(no2s_x[0]*no2s_x[1], 2) if func==1 else func(x, f, no2s_x[0], no2s_x[1]) | ||