login
A133905
Least composite number m such that binomial(n+m,m) mod m = 1.
2
4, 9, 25, 10, 26, 9, 9, 9, 6, 4, 4, 34, 34, 85, 289, 4, 4, 57, 87, 8, 8, 25, 25, 25, 134, 4, 4, 15, 15, 111, 111, 4, 4, 8, 8, 10, 10, 121, 121, 82, 86, 4, 4, 49, 49, 49, 49, 4, 4, 265, 68, 10, 10, 8, 8, 6, 9, 4, 4, 194, 194, 469, 249, 4, 4, 44, 44, 146, 146, 16, 16, 6, 6, 4, 4, 162
OFFSET
1,1
LINKS
EXAMPLE
a(1)=4, since binomial(1+4,4) mod 4 = 5 mod 4 = 1 and 4 is the minimal composite number with this property.
a(5)=26 because of binomial(5+26,26)=169911=6535*26+1, but binomial(5+k,k) mod k<>1 for all composite numbers <26.
MATHEMATICA
lcn[n_]:=Module[{m=4}, While[PrimeQ[m]||Mod[Binomial[n+m, m], m]!=1, m++]; m]; Array[lcn, 80] (* Harvey P. Dale, May 13 2022 *)
PROG
(PARI) a(n) = { my(m = 4, ok = 0); until (ok, if (! isprime(m) && (binomial(n+m, m) % m == 1), ok = 1, m++); ); return (m); } \\ Michel Marcus, Jul 15 2013
KEYWORD
nonn
AUTHOR
Hieronymus Fischer, Oct 20 2007
STATUS
approved