OFFSET
1,2
COMMENTS
This sequence is unbounded.
LINKS
Antti Karttunen, Table of n, a(n) for n = 1..65537
FORMULA
a(p) = 1 for any odd prime number p.
EXAMPLE
The first terms, alongside the corresponding intervals, are:
n a(n) {x..y}
-- ---- --------------------------
1 1 {1..1}
2 2 {1..2, 2..2}
3 1 {3..3}
4 1 {4..4}
5 1 {5..5}
6 3 {1..3, 2..3, 6..6}
7 1 {7..7}
8 1 {8..8}
9 1 {9..9}
10 1 {10..10}
11 1 {11..11}
12 4 {1..4, 2..4, 3..4, 12..12}
13 1 {13..13}
14 1 {14..14}
15 1 {15..15}
PROG
(PARI) a(n) = { my (v=0); fordiv (n, x, my (l=1); for (y=x, oo, l=lcm(l, y); if (l>n, break, l==n, v++))); v }
CROSSREFS
KEYWORD
nonn
AUTHOR
Rémy Sigrist, Sep 29 2020
STATUS
approved