fr.spad line 594 [edit on github]
FactoredFunctionUtilities implements some utility functions for manipulating factored objects.
refine(u, fn) is used to apply the function fn to each factor of u and then build a new factored object from the results. For example, if u were created by calling nilFactor(10, 2) then refine(u, factor) would create a factored object equal to that created by factor(100) or primeFactor(2, 2) * primeFactor(5, 2).