editing
proposed
editing
proposed
1, 1, 7, 17, 17, 137, 9223, 69283, 1791367, 8687893, 64720793, 918317263, 39330021517, 2831766522007, 3546808269427, 40217476619183, 56941594761107557, 1248402398171502073, 6934202069468068973, 884110435325700470387, 92195422498751163402233
nonn,more,changed
The table below illustrates the first four terms. (In the table, 2*floor(k/2) is arbitrarily listed as the "nearest multiple" of 2 for each value of k; choosing 2*ceiling(k/2) would give the same resultresulting terms.)
1, 1, 7, 17, 17, 137, 9223, 69283, 1791367, 8687893, 64720793, 918317263
allocated for Jon E. Schoenfield
a(n) is the smallest positive number that is as far as possible from the nearest multiple of each of the first n primes.
1, 1, 7, 17, 17, 137, 9223, 69283, 1791367, 8687893
1,3
In other words, a(n) is the smallest positive number that differs from the nearest multiple of prime(k) by at least floor(prime(k)/2) for each k in 1..n.
a(1)=1 because prime(1)=2, the nearest multiples of 2 to 1 are 0 and 2, and each differs from 1 by floor(2/2) = 1.
a(2)=1 as well because 1 satisfies not only the requirement regarding the distance from the nearest multiple of prime(1)=2 but also the additional requirement regarding the distance from the nearest multiple of prime(2)=3: the nearest multiple of 3 to 1 is 0, and |0-1| = 1 = floor(3/2) = 1.
a(3)=7 because prime(3)=5 and neither of the numbers smaller than 7 that differ from their respective nearest multiples of 5 by floor(5/2) = floor(5/2) = 2, namely, 2 and 3, also differ by 1 from their nearest multiples of 2 and 3.
The table below illustrates the first four terms. (In the table, 2*floor(k/2) is arbitrarily listed as the "nearest multiple" of 2 for each value of k; choosing 2*ceiling(k/2) would give the same result.)
.
| nearest | abs. diff. from |
| multiple of | nearest multiple of|
k | 2 3 5 7 | 2 3 5 7 | terms
---+----------------+--------------------+------------
1 | 0 0 0 0 | *1*--*1* 1 1 | a(1), a(2)
2 | 2 3 0 0 | 0 *1* *2* 2 |
3 | 2 3 5 0 | *1* 0 *2* *3* |
4 | 4 3 5 7 | 0 *1* 1 *3* |
5 | 4 6 5 7 | *1* *1* 0 2 |
6 | 6 6 5 7 | 0 0 1 1 |
7 | 6 6 5 7 | *1*--*1*--*2* 0 | a(3)
8 | 8 9 10 7 | 0 *1* *2* 1 |
9 | 8 9 10 7 | *1* 0 1 2 |
10 | 10 9 10 7 | 0 *1* 0 *3* |
11 | 10 12 10 14 | *1* *1* 1 *3* |
12 | 12 12 10 14 | 0 0 *2* 2 |
13 | 12 12 15 14 | *1* *1* *2* 1 |
14 | 14 15 15 14 | 0 *1* 1 0 |
15 | 14 15 15 14 | *1* 0 0 1 |
16 | 16 15 15 14 | 0 *1* 1 2 |
17 | 16 18 15 14 | *1*--*1*--*2*--*3* | a(4)
allocated
nonn,more
Jon E. Schoenfield, May 08 2019
approved
editing
allocated for Jon E. Schoenfield
allocated
approved