How can I get the prime factors of a number, with all the primes being less to a factor base
$B$. For example given
$B=8$, then the primes used can only be in
$\{2,3,5,7\}$. And given
$48$, it returns
$2^43$.
Anyone know how to do this in wolfram alpha?
Thanks