Algebra.js
function(symbol, factors) {
                if(symbol.group !== PL) return symbol; //only PL need apply
                var d = core.Utils.arrayMin(keys(symbol.symbols));
                var retval = new Symbol(0);
                var q = _.parse(symbol.value+'^'+d);
                symbol.each(function(x) {
                    x = _.divide(x, q.clone());
                    retval = _.add(retval, x);
                });
                factors.add(q);
                return retval;
            }
function(symbol, factors) {
                if(symbol.group !== PL) return symbol; //only PL need apply
                var d = core.Utils.arrayMin(keys(symbol.symbols));
                var retval = new Symbol(0);
                var q = _.parse(symbol.value+'^'+d);
                symbol.each(function(x) {
                    x = _.divide(x, q.clone());
                    retval = _.add(retval, x);
                });
                factors.add(q);
                return retval;
            }
function ( symbol , factors ) { if ( symbol . group !== PL ) return symbol ; //only PL need apply
 var d = core . Utils . arrayMin ( keys ( symbol . symbols ) ) ; var retval = new Symbol ( 0 ) ; var q = _ . parse ( symbol . value + '^' + d ) ; symbol . each ( function ( x ) { x = _ . divide ( x , q . clone ( ) ) ; retval = _ . add ( retval , x ) ; } ) ; factors . add ( q ) ; return retval ; }
Factors the powers such that the lowest power is a constant
@param {Symbol} symbol
@param {Factors} factors
@returns {[Symbol, Factor]}
Factors the powers such that the lowest power is a constant