2

For example, for the numbers 1 to 10, one can just find the necessary factors and multiply them: $5 \times 7 \times 8 \times 9 = 2520$, and all the other numbers in that range follow. But with larger ranges, larger numbers logically result. Is there a simpler way to find this smallest number other than straight multiplication filtering?

Lee Sleek
  • 1,682

2 Answers2

2

You are looking for A003418. The starting terms are as follows:

1, 1, 2, 6, 12, 60, 60, 420, 840, 2520, 2520, 27720, 27720, 360360, 360360, 360360, 720720, 12252240, 12252240, 232792560, 232792560

Ed Pegg
  • 20,955
2

Notice that for the numbers $1$ through $10$, inclusive, we have that $5\times 7\times 8 \times 9 = 2^3 \times 3^2 \times 5\times 7\times = 2520$ and every number $2$ to $10$ can be written as the product of some combination of the given factors. This is due to the fact that:

What you can say is that the least integer divisible by every element in $\{1, 2, \cdots, n\}$ is equal to the least common multiple $\operatorname{lcm}(1, 2, \cdots, n)$.

amWhy
  • 209,954
  • I was looking for more of a formula, so this is the best answer. In other words, multiply all the prime numbers less than n, raised to the highest power less than n. – Lee Sleek May 07 '13 at 03:37
  • Yes, indeed, you're correct: in the example above, $2^3$ covers $2, 4, 8$; $3^2$ covers $3, 9,$ $5\times 2$ covers 10, and 7 covers 7 – amWhy May 07 '13 at 03:47