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-7 of 7 results.

A109641 Composite n such that binomial(3n, n) == 3^k (mod n) for some integer k > 0.

Original entry on oeis.org

4, 9, 15, 25, 27, 34, 36, 49, 51, 57, 63, 68, 75, 81, 87, 93, 111, 121, 125, 129, 132, 138, 141, 153, 155, 159, 169, 177, 237, 249, 258, 261, 264, 267, 274, 276, 279, 289, 298, 303, 324, 339, 343, 357, 361, 375, 381, 387, 393, 411, 417, 423, 441, 447, 453, 477
Offset: 1

Views

Author

Ryan Propper, Aug 05 2005

Keywords

Comments

Includes p^k for k >= 2 and p > 2 in A019334 but not in A014127, as binomial(3n,n) is coprime to p and 3 is a primitive root mod p^k. - Robert Israel, Nov 12 2017

Examples

			Binomial(3*34,34) == 3^6 (mod 34), so 34 is a member.
		

Crossrefs

Programs

  • Maple
    filter:= proc(n) local p,m,k,t;
      if isprime(n) then return false fi;
      p:= padic:-ordp(n,3);
      p:= p + numtheory:-order(3, n/3^p);
      m:= binomial(3*n,n) mod n;
      t:= 1;
      for k from 1 to p do
        t:= t*3 mod n;
        if t = m then return true fi;
      od:
    false
    end proc;
    select(filter, [$2..1000]); # Robert Israel, Nov 12 2017
  • Mathematica
    okQ[n_] := Module[{p, m}, If[PrimeQ[n], Return[False]]; p = IntegerExponent[n, 3]; p = p + MultiplicativeOrder[3, n/3^p]; m = Mod[Binomial[3n, n], n]; AnyTrue[Range[p], m == PowerMod[3, #, n]&]];
    Select[Range[2, 500], okQ] (* Jean-François Alcover, Mar 27 2019, after Robert Israel *)

Extensions

Corrected and extended by Max Alekseyev, Sep 13 2009
Edited by Max Alekseyev, Sep 20 2009

A109642 a(n) = least composite m such that binomial(3m,m) mod m = 3^n.

Original entry on oeis.org

4, 15, 57, 765, 1025, 2097, 4947, 9189, 103599, 216927, 4346128, 1558269, 1977777, 208510373, 14493123, 493262541, 144228033
Offset: 1

Views

Author

Ryan Propper, Aug 05 2005

Keywords

Comments

Subsequence of A109641.

Crossrefs

Programs

  • Mathematica
    In[1]:= n = 1; Do[If[ !PrimeQ[k] && Mod[Binomial[3*k, k], k] == 3^n, Print[k]; n++ ], {k, 1, 10^4}]

Extensions

Edited by Max Alekseyev, Nov 03 2009
a(14)-a(17) from Chai Wah Wu, Jul 30 2025

A260636 a(n) = binomial(3n, n) mod n.

Original entry on oeis.org

0, 1, 0, 3, 3, 0, 3, 7, 3, 5, 3, 0, 3, 8, 9, 15, 3, 15, 3, 15, 0, 4, 3, 12, 3, 2, 3, 12, 3, 24, 3, 15, 18, 15, 0, 9, 3, 34, 6, 31, 3, 21, 3, 0, 15, 38, 3, 36, 3, 40, 33, 40, 3, 42, 0, 16, 27, 44, 3, 0, 3, 46, 45, 47, 39, 51, 3, 53, 15, 0, 3, 45, 3, 15, 9, 20, 76, 0, 3, 7, 3
Offset: 1

Views

Author

M. F. Hasler, Nov 11 2015

Keywords

Comments

Motivated by A080469: C(3n,n)=3^n (mod n), A109641, A109642 and other sequences.
See A059288 for the "2n" analog. Sequence A260640 yields the indices of zeros (analog to A014847 for 2n).

Examples

			n=1: C(3,1) = 3 = 0 (mod 1).
n=2: C(3*2,2) = 15 = 1 (mod 2).
n=3: C(3*3,3) = 84 = 0 (mod 3).
n=4: C(3*4,4) = 495 = 3 (mod 4).
		

Crossrefs

Cf. A080469, A109641, A109642; A260640 (indices of zeros); A059288, A014847 (analogs for 2n).

Programs

  • Magma
    [Binomial(3*n,n) mod n : n in [1..100]]; // Wesley Ivan Hurt, Nov 12 2015
    
  • Maple
    A260636:=n->binomial(3*n,n) mod n: seq(A260636(n), n=1..100); # Wesley Ivan Hurt, Nov 12 2015
  • Mathematica
    Array[Mod[Binomial[3 #, #], #] &, 112] (* Michael De Vlieger, Nov 12 2015 *)
  • PARI
    a(n)=binomial(3*n,n)%n
    
  • PARI
    A260636(n)=lift(binomod(3*n,n,n)) \\ using binomod.gp by M. Alekseyev, cf. Links.
    
  • Python
    from _future_ import division
    A260636_list, b = [], 3
    for n in range(1,10001):
        A260636_list.append(b % n)
        b = b*3*(3*n+2)*(3*n+1)//((2*n+2)*(2*n+1)) # Chai Wah Wu, Jan 27 2016

A260640 Numbers n such that binomial(3*n,n) == 0 (mod n).

Original entry on oeis.org

1, 3, 6, 12, 21, 35, 44, 55, 60, 70, 78, 88, 90, 99, 102, 110, 117, 119, 120, 133, 156, 171, 176, 180, 184, 204, 207, 220, 225, 230, 231, 234, 238, 240, 247, 252, 255, 285, 286, 300, 312, 341, 342, 348, 360, 368, 372, 391, 403, 408, 414, 425, 434, 460, 462, 465, 468, 481, 483, 494, 495, 504, 506, 510, 550, 555, 561, 572, 574, 585, 600
Offset: 1

Views

Author

M. F. Hasler, Nov 11 2015

Keywords

Comments

See A014847 for the analog for 2n.

Crossrefs

Programs

  • Magma
    [n: n in [1..600] |Binomial(3*n,n) mod n eq 0]; // Vincenzo Librandi, Jan 29 2016
  • Mathematica
    Select[Range@ 600, Mod[Binomial[3 #, #], #] == 0 &] (* Michael De Vlieger, Nov 12 2015 *)
  • PARI
    for(n=1,999,binomod(3*n,n,n)==0&&print1(n",")) \\ Using binomod.gp by M. Alekseyev, cf. links.
    
  • Python
    from _future_ import division
    A260640_list, b = [], 3
    for n in range(1,10**3):
        if not b % n:
            A260640_list.append(n)
        b = b*3*(3*n+2)*(3*n+1)//((2*n+2)*(2*n+1)) # Chai Wah Wu, Jan 27 2016
    

A109760 Composite n such that binomial(5*n,n) == 5^n (mod n).

Original entry on oeis.org

4, 365, 400, 685, 3200, 6400, 12550, 12800, 16525, 25600, 51200, 225125, 70463125, 271094125, 431434441
Offset: 1

Views

Author

Ryan Propper, Aug 12 2005

Keywords

Comments

No other terms below 10^9.

Examples

			4 is a term because binomial(5*4, 4) = 4845, 5^4 = 625 and 4845 mod 4 = 625 mod 4 = 1.
		

Crossrefs

Cf. A080469.

Programs

  • Mathematica
    Do[If[ !PrimeQ[n], If[Mod[Binomial[5*n, n], n] == Mod[5^n, n], Print[n]]], {n, 1, 50000}]
    Select[Range[250000],CompositeQ[#]&&Mod[Binomial[5#,#],#]==PowerMod[5,#,#]&] (* The program generates the first 12 terms of the sequence. *) (* Harvey P. Dale, Jul 28 2025 *)

Extensions

a(12) from D. S. McNeil, Mar 15 2009
225125 from Max Alekseyev, Sep 13 2009
Three more terms from Max Alekseyev, Nov 06 2009

A109769 Composite n such that binomial(7*n, n) == 7^n (mod n).

Original entry on oeis.org

18, 25, 133, 2107, 4676, 226037, 4477739, 827867201
Offset: 1

Views

Author

Ryan Propper, Aug 13 2005

Keywords

Comments

No other terms below 10^9.

Examples

			18 is a term because binomial(7*18, 18) = 2797093093529137508875, 7^18 = 1628413597910449 and 2797093093529137508875 mod 18 = 1628413597910449 mod 18 = 1.
		

Crossrefs

Cf. A080469.

Programs

  • Mathematica
    Do[If[ !PrimeQ[n], If[Mod[Binomial[7*n, n], n] == Mod[7^n, n], Print[n]]], {n, 2, 20000}]

Extensions

226037 from Max Alekseyev, Sep 13 2009
Two more terms from Max Alekseyev, Nov 06 2009

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-7 of 7 results.