Algorithms to generate smooth numbers
See the definition of smooth number on Wikipedia and MathWorld.
Compute the first 10 3-smooth numbers, i.e. numbers of the form 2^i * 3^j
:
julia> using SmoothNumbers
julia> smooth(3, 10)
10-element Vector{Int64}:
1
2
3
4
6
8
9
12
16
18
Compute the first 10 numbers of the form 2^3 * 3^i * 7^i
:
julia> using SmoothNumbers
julia> with_bases([2, 3, 7], 10)
10-element Vector{Int64}:
1
2
3
4
6
7
8
9
12
14