Magma provides an experimental implementation of the fastest general
purpose factoring algorithm known: the number field sieve (NFS).
The implementation can be used for both general number field and
special number field factorizations: the only difference is in the
polynomial selection. Presently, Magma does not provide a function
to choose a good polynomial for a particular number to be factored.
However, Magma does provide some functions that are useful for
the implementation of the polynomial selection algorithms developed
by Peter Montgomery and Brian Murphy.