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.

Showing 1-3 of 3 results.

A228562 Composite numbers k that are not prime powers such that binomial(2k-1, k-1) is congruent to 1 (mod k).

Original entry on oeis.org

27173, 2001341, 16024189487
Offset: 1

Views

Author

Felix Fröhlich, Aug 25 2013

Keywords

Crossrefs

The odd terms of A328497.

Programs

  • Mathematica
    Select[Range[30000], PrimeNu[#] > 1 && Mod[Binomial[2# - 1, # - 1], #] == 1 &] (* Alonso del Arte, May 11 2014 *)
  • PARI
    N=10^9; for(n=2, N, if(Mod(binomial(2*n-1, n-1), n)==1 && !ispower(n) && !isprime(n), print1(n, ", "))); \\ Felix Fröhlich, May 11 2014
    
  • PARI
    vp(n,p)=my(s); while(n\=p, s+=n); s
    is(n)=my(f=factor(n)[,1],G); if(#f==1, return(0)); for(i=1,#f, if(vp(2*n-1,f[i]) > vp(n,f[i])+vp(n-1,f[i]), return(0))); G=prod(i=1,#f,f[i]^(log(n)\log(f[i]))); prod(i=n+1,2*n-1, i/gcd(i,G), Mod(1,n))/prod(i=2,n-1, i/gcd(i,G), Mod(1,n))==1
    forcomposite(n=4,1e9, if(is(n), print1(n", "))) \\ Charles R Greathouse IV, May 12 2014

Formula

A099905(a(n)) = 1. - Jonathan Sondow, Jan 24 2016

A082180 Composite integers k such that binomial(2*k, k) == 2 (mod k).

Original entry on oeis.org

4, 9, 25, 49, 121, 125, 169, 289, 343, 361, 418, 529, 841, 961, 1331, 1369, 1681, 1849, 2197, 2209, 2809, 3481, 3721, 4489, 4913, 5041, 5329, 6241, 6859, 6889, 7921, 9409, 10201, 10609, 11449, 11881, 12167, 12769, 16129, 17161, 18769, 19321
Offset: 1

Views

Author

Benoit Cloitre, May 10 2003

Keywords

Comments

Also, composite integers k such that A000108(k) == 2 (mod k).
It seems that the sequence contains all squares of primes and some cubes of odd primes. But it includes other terms as well, including 418 = 2*11*19 and 27173 = 29*937. [edited by Jon E. Schoenfield, Jul 31 2018]
By Wolstenholme's theorem, this sequence does contain all squares of primes and cubes of primes > 3^3, since for primes p > 3 we have binomial(2p^3, p^3) == binomial(2p^2, p^2) == binomial(2p, p) == binomial(2, 1) == 2 (mod p^3). See the link below. - Jianing Song, Aug 01 2018
Note that binomial(2*(n+1), n+1) = binomial(2*n, n) * (4 - 2/(n+1)), which could be used to find terms. - David A. Corneth, Aug 05 2018
Up to a(800) = 30946969, 2001341 = 787 * 2543 is the only further term which, like 418 and 27173, is neither a square nor a cube. - Giovanni Resta, Aug 08 2018

Crossrefs

Programs

  • GAP
    Filtered([1..1000],n->not IsPrime(n) and Binomial(2*n,n) mod n =2); # Muniru A Asiru, Aug 01 2018
  • Maple
    select(n-> not isprime(n) and modp(binomial(2*n,n),n)=2,[$1..10000]); # Muniru A Asiru, Aug 01 2018
  • Mathematica
    nn=20000;With[{comps=Complement[Range[nn],Prime[Range[PrimePi[nn]]]]}, Select[ comps,Mod[Binomial[2#,#],#]==2&]] (* Harvey P. Dale, May 24 2012 *)
    Select[Range@ 20000, CompositeQ@# && Mod[Binomial[2 #, #], #] == 2 &] (* Robert G. Wilson v, Aug 01 2018 *)
  • PARI
    forcomposite(c=1, 2e4, if(Mod(binomial(2*c, c), c)==2, print1(c, ", "))) \\ Felix Fröhlich, Jul 30 2018
    
  • PARI
    upto(n) = {my(binomp = 2, res = List()); for(t = 2, n, binomp *= (4 - 2/t);
    if(!isprime(t) && binomp % t == 2, listput(res, t))); res} \\ David A. Corneth, Aug 05 2018
    

Extensions

More terms from John W. Layman, Jun 09 2004

A084699 Composite integers j such that binomial(2*j,j) == 2^j (mod j).

Original entry on oeis.org

12, 30, 56, 424, 992, 16256, 58288, 119984, 356992, 1194649, 9973504, 12327121, 13141696, 22891184, 67100672, 233850649
Offset: 1

Views

Author

Benoit Cloitre, Oct 15 2003

Keywords

Comments

If p is prime, binomial(2*p,p) == 2^p (mod p).
a(17) > 10^9.
From Gabriel Guedes and Ricardo Machado, Nov 16 2023: (Start)
Theorem. Let j = (2^k)*p, where p is an odd prime and k is in N; then binomial(2*j,j) == 2^j (mod j) if and only if p satisfies the following conditions:
a) p divides binomial(2^(k+1),2^k) - 2^(2^k);
b) p has at least k 1's in its binary expansion.
Theorem. If m is an even perfect number then j = 2m satisfies the congruence binomial(2*j,j) == 2^j (mod j). See A000396.
Theorem. Let j = p^2 with p a prime number. Then p is a Wieferich prime if and only if binomial(2*j,j) == 2^j (mod j). See A001220. (End)
Contains 17179738112 and 274877382656 (from Guedes-Machado paper). - Michael De Vlieger, Nov 22 2023
Contains 3386741824, 750984028672, 33029195197184, 1145067923695616, 422612863956511744. - Ricardo Machado, Nov 23 2023
Contains 84385517065596416, 62648180117928433664, 273984397779878971648, 36506097537257040703232. - Max Alekseyev, Dec 07 2023

Crossrefs

Contains A139256 as a subsequence.

Programs

  • PARI
    lista(nn) = {forcomposite(n=1, nn, if (binomod(2*n, n, n) == Mod(2, n)^n, print1(n, ", ")));} \\ Michel Marcus, Dec 06 2013 and Dec 03 2023

Extensions

More terms from David Wasserman, Jan 03 2005
a(11)-a(16) from Max Alekseyev, Aug 05 2011
Showing 1-3 of 3 results.