cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A327409 Smallest integer > 0 so that its remainders modulo the first n primes are at least half their respective moduli.

Original entry on oeis.org

1, 5, 23, 53, 53, 293, 503, 713, 1439, 1439, 16673, 16673, 16673, 16673, 16673, 16673, 16673, 298583, 728153, 728153, 728153, 19420253, 19420253, 66663659, 207178199, 384974819, 384974819, 384974819, 546086693, 546086693, 8504041103, 22060162703, 60826761629, 60826761629
Offset: 1

Views

Author

Bert Dobbelaere, Sep 07 2019

Keywords

Examples

			a(6) = 293.
293 mod 2 = 1 >= 2/2
293 mod 3 = 2 >= 3/2
293 mod 5 = 3 >= 5/2
293 mod 7 = 6 >= 7/2
293 mod 11 = 7 >= 11/2
293 mod 13 = 7 >= 13/2
293 is the smallest integer > 0 satisfying these inequalities for the first 6 primes.
		

Crossrefs

Companion sequence of A327408.

Programs

  • PARI
    isok(k, vp) = {for (i=1, #vp, if ((k % vp[i]) < vp[i]/2, return (0));); return (1);}
    a(n) = {my(k=1, vp = primes(n)); while (!isok(k, vp), k++); k;} \\ Michel Marcus, Sep 08 2019