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.

A205551 The least j such that n divides k^k-j^j, where k (as in A205546) is the least number for which there is such a j.

Original entry on oeis.org

1, 1, 1, 2, 1, 2, 2, 4, 2, 4, 1, 2, 1, 2, 1, 4, 1, 2, 4, 4, 2, 1, 2, 4, 4, 1, 3, 2, 4, 4, 1, 4, 3, 4, 1, 2, 4, 1, 1, 4, 5, 2, 1, 1, 1, 2, 4, 4, 6, 4, 1, 1, 7, 3, 6, 6, 7, 4, 5, 4, 5, 2, 2, 4, 1, 3, 6, 4, 2, 6, 1, 8, 3, 1, 6, 1, 6, 3, 8, 4, 6, 5, 12, 2, 1, 4, 1, 6, 2, 6, 1, 2, 9, 4, 5, 4, 6, 6, 3
Offset: 1

Views

Author

Clark Kimberling, Jan 31 2012

Keywords

Comments

For a guide to related sequences, see A204892.

Examples

			1 divides 2^2-1^1 -> k=2, j=1
2 divides 3^3-1^1 -> k=3, j=1
3 divides 2^2-1^1 -> k=2, j=1
4 divides 4^4-2^2 -> k=2, j=2
		

Crossrefs

Cf. A204892.

Programs

  • Mathematica
    s = Table[n^n, {n, 1, 120}];
    lk = Table[NestWhile[# + 1 &, 1,
       Min[Table[Mod[s[[#]] - s[[j]], z], {j, 1, # - 1}]] =!= 0 &], {z, 1, Length[s]}]
    Table[NestWhile[# + 1 &, 1,
      Mod[s[[lk[[j]]]] - s[[#]], j] =!= 0 &],
     {j, 1, Length[lk]}]
    (* Peter J. C. Moses, Jan 27 2012 *)

A205561 Least positive integer k such that n divides (2k)! - (2j)! for some j in [1,k-1].

Original entry on oeis.org

2, 2, 3, 3, 4, 3, 5, 3, 4, 4, 2, 3, 8, 5, 4, 4, 10, 4, 4, 4, 5, 2, 4, 3, 4, 8, 6, 5, 3, 4, 5, 5, 4, 10, 5, 4, 20, 4, 8, 4, 11, 5, 10, 4, 4, 4, 5, 4, 6, 4, 10, 8, 6, 6, 4, 5, 8, 3, 13, 4, 8, 5, 5, 5, 8, 4, 16, 10, 4, 5, 7, 4, 4, 20, 4, 8, 7, 8, 11, 4, 6, 11, 22, 5, 10, 10, 3, 4, 5, 4, 8, 4
Offset: 1

Views

Author

Clark Kimberling, Feb 01 2012

Keywords

Comments

For a guide to related sequences, see A204892.
From Robert Israel, Nov 20 2024: (Start)
a(n) <= ceil(A002034(n)/2) + 1.
The last occurrence of k >= 2 in the sequence is a((2*k)! - 2) = k. (End)

Examples

			1 divides (2*2)!-(2*1)! -> k=2, j=1
2 divides (2*2)!-(2*1)! -> k=2, j=1
3 divides (2*3)!-(2*2)! -> k=3, j=2
4 divides (2*3)!-(2*2)! -> k=3, j=2
5 divides (2*4)!-(2*3)! -> k=4, j=3
		

Crossrefs

Programs

  • Maple
    f:= proc(n) local S,j,x;
      S:= {}:
      x:= 1:
      for j from 1 do
        x:=x*2*j*(2*j-1) mod n;
        if member(x,S) then return j fi;
        S:= S union {x}
      od
    end proc:
    map(f, [$1..100]); # Robert Israel, Nov 18 2024
  • Mathematica
    s = Table[(2n)!, {n, 1, 120}];
    lk = Table[NestWhile[# + 1 &, 1,
       Min[Table[Mod[s[[#]] - s[[j]], z], {j, 1, # - 1}]] =!= 0 &], {z, 1, Length[s]}]
    Table[NestWhile[# + 1 &, 1,
      Mod[s[[lk[[j]]]] - s[[#]], j] =!= 0 &],
    {j, 1, Length[lk]}]
    (* Peter J. C. Moses, Jan 27 2012 *)

A205554 Least positive integer k such that n divides k^(k-1)-j^(j-1) for some j in [1,k-1].

Original entry on oeis.org

2, 3, 4, 3, 4, 5, 3, 3, 4, 7, 4, 5, 5, 5, 7, 5, 5, 7, 7, 7, 4, 5, 6, 5, 6, 5, 7, 5, 12, 8, 4, 6, 5, 7, 11, 7, 9, 7, 5, 7, 8, 13, 7, 5, 7, 6, 12, 5, 8, 8, 5, 5, 7, 12, 4, 5, 7, 12, 12, 11, 12, 4, 4, 8, 7, 8, 7, 7, 7, 11, 7, 7, 9, 9, 8, 7, 5, 5, 8, 9, 9, 8, 10, 13, 7, 7, 14, 5, 5, 13, 16, 7
Offset: 1

Views

Author

Clark Kimberling, Feb 01 2012

Keywords

Comments

For a guide to related sequences, see A204892.

Examples

			1 divides 2^(2-1)-1^(1-1) -> k=2, j=1
2 divides 3^(3-1)-1^(1-1) -> k=3, j=1
3 divides 4^(4-1)-1^(1-1) -> k=4, j=1
4 divides 3^(3-1)-1^(1-1) -> k=3, j=1
5 divides 4^(4-1)-3^(3-1) -> k=4, j=3
		

Crossrefs

Programs

  • Mathematica
    s = Table[n^(n-1), {n, 1, 120}];
    lk = Table[NestWhile[# + 1 &, 1,
       Min[Table[Mod[s[[#]] - s[[j]], z], {j, 1, # - 1}]] =!= 0 &], {z, 1, Length[s]}]
    Table[NestWhile[# + 1 &, 1,
      Mod[s[[lk[[j]]]] - s[[#]], j] =!= 0 &],
    {j, 1, Length[lk]}]
    (* Peter J. C. Moses, Jan 27 2012 *)
Showing 1-3 of 3 results.