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

A056021 Numbers k such that k^4 == 1 (mod 5^2).

Original entry on oeis.org

1, 7, 18, 24, 26, 32, 43, 49, 51, 57, 68, 74, 76, 82, 93, 99, 101, 107, 118, 124, 126, 132, 143, 149, 151, 157, 168, 174, 176, 182, 193, 199, 201, 207, 218, 224, 226, 232, 243, 249, 251, 257, 268, 274, 276, 282, 293, 299, 301, 307, 318, 324, 326, 332, 343, 349
Offset: 1

Views

Author

Robert G. Wilson v, Jun 08 2000

Keywords

Comments

Numbers congruent to {1, 7, 18, 24} mod 25.
These terms (apart from 1) are tetration bases characterized by a constant convergence speed strictly greater than 1 (see A317905). - Marco RipĂ , Jan 25 2024

Crossrefs

Programs

  • Mathematica
    Select[ Range[ 400 ], PowerMod[ #, 4, 25 ]==1& ]
    (* or *)
    LinearRecurrence[{1, 0, 0, 1, -1}, {1, 7, 18, 24, 26}, 100] (* Mike Sheppard, Feb 18 2025 *)
  • PARI
    a(n) = (-25 - (-1)^n + (9-9*I)*(-I)^n + (9+9*I)*I^n + 50*n) / 8 \\ Colin Barker, Oct 16 2015
    
  • PARI
    Vec(x*(x^2+3*x+1)^2/((1+x)*(x^2+1)*(x-1)^2) + O(x^100)) \\ Colin Barker, Oct 16 2015
    
  • PARI
    for(n=0, 1e3, if(n^4 % 5^2 == 1, print1(n", "))) \\ Altug Alkan, Oct 16 2015
    
  • PARI
    isok(k) = Mod(k, 25)^4 == 1; \\ Michel Marcus, Jun 30 2021

Formula

G.f.: x*(x^2+3*x+1)^2 / ((1+x)*(x^2+1)*(x-1)^2). - R. J. Mathar, Oct 25 2011
a(n) = (-25 - (-1)^n + (9-9*i)*(-i)^n + (9+9*i)*i^n + 50*n) / 8, where i = sqrt(-1). - Colin Barker, Oct 16 2015
From Mike Sheppard, Feb 18 2025: (Start)
a(n) = a(n-1) + a(n-4) - a(n-5).
a(n) ~ (5^2/4)*n. (End)

A056022 Numbers k such that k^6 == 1 (mod 7^2).

Original entry on oeis.org

1, 18, 19, 30, 31, 48, 50, 67, 68, 79, 80, 97, 99, 116, 117, 128, 129, 146, 148, 165, 166, 177, 178, 195, 197, 214, 215, 226, 227, 244, 246, 263, 264, 275, 276, 293, 295, 312, 313, 324, 325, 342, 344, 361, 362, 373, 374, 391, 393, 410, 411, 422, 423, 440, 442
Offset: 1

Views

Author

Robert G. Wilson v, Jun 08 2000

Keywords

Crossrefs

Cf. A381319 (general case mod n^2).

Programs

  • Mathematica
    Select[ Range[ 500 ], PowerMod[ #, 6, 49 ]==1& ]
    LinearRecurrence[{1, 0, 0, 0, 0, 1, -1}, {1, 18, 19, 30, 31, 48, 50}, 61] (* Mike Sheppard, Feb 18 2025 *)
  • PARI
    isok(k) = Mod(k, 49)^6 == 1; \\ Michel Marcus, Jun 30 2021

Formula

From Mike Sheppard, Feb 18 2025 : (Start)
a(n) = a(n-1) + a(n-6) - a(n-7).
a(n) = a(n-6) + 7^2.
a(n) ~ (7^2/6)*n.
G.f.: (1 + x*(17 + x + 11*x^2 + x^3 + 17*x^4 + x^5))/(1 - x - x^6 + x^7). (End)

A056024 Numbers k such that k^10 == 1 (mod 11^2).

Original entry on oeis.org

1, 3, 9, 27, 40, 81, 94, 112, 118, 120, 122, 124, 130, 148, 161, 202, 215, 233, 239, 241, 243, 245, 251, 269, 282, 323, 336, 354, 360, 362, 364, 366, 372, 390, 403, 444, 457, 475, 481, 483, 485, 487, 493, 511, 524, 565, 578, 596, 602, 604, 606, 608, 614, 632
Offset: 1

Views

Author

Robert G. Wilson v, Jun 08 2000

Keywords

Crossrefs

Cf. A381319 (general case mod n^2).

Programs

  • Mathematica
    Select[ Range[ 800 ], PowerMod[ #, 10, 121 ]==1& ]
    LinearRecurrence[{1, 0, 0, 0, 0, 0, 0, 0, 0, 1, -1}, {1, 3, 9, 27, 40, 81, 94, 112, 118, 120, 122}, 65] (* Mike Sheppard, Feb 19 2025 *)

Formula

From Mike Sheppard, Feb 19 2025: (Start)
a(n) = a(n-1) + a(n-10) - a(n-11).
a(n) = a(n-10) + 11^2.
a(n) ~ (11^2/10)*n. (End)

A056025 Numbers k such that k^12 == 1 (mod 13^2).

Original entry on oeis.org

1, 19, 22, 23, 70, 80, 89, 99, 146, 147, 150, 168, 170, 188, 191, 192, 239, 249, 258, 268, 315, 316, 319, 337, 339, 357, 360, 361, 408, 418, 427, 437, 484, 485, 488, 506, 508, 526, 529, 530, 577, 587, 596, 606, 653, 654, 657, 675, 677, 695, 698, 699, 746
Offset: 1

Views

Author

Robert G. Wilson v, Jun 08 2000

Keywords

Comments

From 19 to 168 inclusive, these are the numbers that 'fool' the strong pseudoprimality test described in Wilf (1986) in regard to determining whether 169 is composite. - Alonso del Arte, Feb 05 2012

References

  • Herbert S. Wilf, Algorithms and Complexity, Englewood Cliffs, New Jersey: Prentice-Hall, 1986, pp. 158-160.

Crossrefs

Cf. A381319 (general case mod n^2).

Programs

  • Mathematica
    Select[ Range[ 800 ], PowerMod[ #, 12, 169 ]==1& ]
    LinearRecurrence[{1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, -1}, {1, 19, 22, 23, 70, 80, 89, 99, 146, 147, 150, 168, 170}, 56] (* Mike Sheppard, Feb 19 2025 *)
  • PARI
    is(k)=Mod(k,169)^12==1 \\ Charles R Greathouse IV, Feb 07 2018

Formula

From Mike Sheppard, Feb 19 2025 : (Start)
a(n) = a(n-1) + a(n-12) - a(n-13).
a(n) = a(n-12) + 13^2.
a(n) ~ (13^2/12)*n. (End)

Extensions

Definition corrected by T. D. Noe, Aug 23 2008

A056027 Numbers k such that k^16 == 1 (mod 17^2).

Original entry on oeis.org

1, 38, 40, 65, 75, 110, 131, 134, 155, 158, 179, 214, 224, 249, 251, 288, 290, 327, 329, 354, 364, 399, 420, 423, 444, 447, 468, 503, 513, 538, 540, 577, 579, 616, 618, 643, 653, 688, 709, 712, 733, 736, 757, 792, 802, 827, 829, 866, 868, 905, 907, 932, 942
Offset: 1

Views

Author

Robert G. Wilson v, Jun 08 2000

Keywords

Crossrefs

Programs

  • Mathematica
    x=17; Select[ Range[ 1000 ], PowerMod[ #, x-1, x^2 ]==1& ]
    (* or *)
    LinearRecurrence[{1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, -1}, {1, 38, 40, 65, 75, 110, 131, 134, 155, 158, 179, 214, 224, 249, 251, 288, 290}, 55] (* Mike Sheppard, Feb 17 2025 *)

Formula

From Mike Sheppard, Feb 17 2025: (Start)
a(n) = a(n-1) + a(n-16) - a(n-17).
a(n) ~ (17^2/16) * n.
G.f.: (x*(1 + 37*x + 2*x^2 + 25*x^3 + 10*x^4 + 35*x^5 + 21*x^6 + 3*x^7 + 21*x^8 + 3*x^9 + 21*x^10 + 35*x^11 + 10*x^12 + 25*x^13 + 2*x^14 + 37*x^15 + x^16))/((1-x)*(1-x^16)).
(End)

A056034 Numbers k such that k^28 == 1 (mod 29^2).

Original entry on oeis.org

1, 14, 41, 60, 63, 137, 190, 196, 221, 236, 267, 270, 374, 416, 425, 467, 571, 574, 605, 620, 645, 651, 704, 778, 781, 800, 827, 840, 842, 855, 882, 901, 904, 978, 1031, 1037, 1062, 1077, 1108, 1111, 1215, 1257, 1266, 1308, 1412, 1415, 1446, 1461, 1486, 1492
Offset: 1

Views

Author

Robert G. Wilson v, Jun 08 2000

Keywords

Crossrefs

Cf. A381319 (general case mod n^2).

Programs

  • Mathematica
    x=29; Select[ Range[ 2000 ], PowerMod[ #, x-1, x^2 ]==1& ]
  • PARI
    isok(k) = Mod(k, 29^2)^28 == 1; \\ Michel Marcus, Apr 10 2025

Formula

From Mike Sheppard, Feb 20 2025 : (Start)
a(n) = a(n-1) + a(n-28) - a(n-29).
a(n) = a(n-28) + 29^2.
a(n) ~ (29^2/28)*n. (End)

A056035 Numbers k such that k^30 == 1 (mod 31^2).

Original entry on oeis.org

1, 115, 117, 145, 229, 235, 333, 338, 374, 388, 414, 430, 439, 440, 448, 513, 521, 522, 531, 547, 573, 587, 623, 628, 726, 732, 816, 844, 846, 960, 962, 1076, 1078, 1106, 1190, 1196, 1294, 1299, 1335, 1349, 1375, 1391, 1400, 1401, 1409, 1474, 1482, 1483
Offset: 1

Views

Author

Robert G. Wilson v, Jun 08 2000

Keywords

Crossrefs

Programs

  • Mathematica
    x=31; Select[ Range[ 2000 ], PowerMod[ #, x-1, x^2 ]==1& ]

Formula

From Mike Sheppard, Feb 20 2025 : (Start)
a(n) = a(n-1) + a(n-30) - a(n-31).
a(n) = a(n-30) + 31^2.
a(n) ~ (31^2/30)*n. (End)

A143548 Irregular triangle of numbers k < p^2 such that p^2 divides k^(p-1)-1, with p=prime(n).

Original entry on oeis.org

1, 1, 8, 1, 7, 18, 24, 1, 18, 19, 30, 31, 48, 1, 3, 9, 27, 40, 81, 94, 112, 118, 120, 1, 19, 22, 23, 70, 80, 89, 99, 146, 147, 150, 168, 1, 38, 40, 65, 75, 110, 131, 134, 155, 158, 179, 214, 224, 249, 251, 288, 1, 28, 54, 62, 68, 69, 99, 116, 127, 234, 245, 262, 292, 293, 299, 307, 333, 360
Offset: 1

Views

Author

T. D. Noe, Aug 24 2008

Keywords

Comments

Row n begins with 1 and has prime(n)-1 terms. The first differences of each row are symmetric. For k > p^2, the solutions are just shifted by m*p^2 for m > 0. An open question is whether every integer appears in this sequence. For instance, 2 does not appear until the prime 1093 and 5 does not appear until the prime 20771.
For row n > 1, the sum of the terms in row n is (p-1)*p^2*(p+1)/2, which is A138416. - T. D. Noe, Aug 24 2008, corrected by Robert Israel, Sep 27 2016
Max Alekseyev points out that there is a much faster method of computing these numbers. Let p=prime(n) and let r be a primitive root of p (see A001918 and A060749). Then the terms in row n are r^(k*p) (mod p^2) for k=0..p-2. - T. D. Noe, Aug 26 2008
The numbers in this sequence are the bases to Euler pseudoprimes q, which are squares of prime numbers, such that n^((q-1)/2) == +-1 mod q. An exception is the first number 9 = 3*3, which is, following the strict definition in Crandall and Pomerance, no Fermat pseudoprime and hence no Euler pseudoprime. - Karsten Meyer, Jan 08 2011
For row n > 1, the sum is zero modulo p^2 (rows are antisymmetric due to Binomial Theorem). - Peter A. Lawrence, Sep 11 2016

Examples

			(2)   1,
(3)   1, 8,
(5)   1, 7, 18, 24,
(7)   1, 18, 19, 30, 31, 48,
(11)  1, 3, 9, 27, 40, 81, 94, 112, 118, 120,
(13)  1, 19, 22, 23, 70, 80, 89, 99, 146, 147, 150, 168,
(17)  1, 38, 40, 65, 75, 110, 131, 134, 155, 158, 179, 214, 224, 249, 251, 288,
		

References

  • R. Crandall and C. Pomerance, Prime Numbers: A Computational Perspective, Springer, NY, 2005

Crossrefs

Programs

  • Maple
    f:= proc(n) local p,j,x;
      p:= ithprime(n);
      x:= numtheory:-primroot(p);
      op(sort([seq(x^(i*p) mod p^2, i=0..p-2)]))
    end proc:
    map(f, [$1..20]); # Robert Israel, Sep 27 2016
  • Mathematica
    Flatten[Table[p=Prime[n]; Select[Range[p^2], PowerMod[ #,p-1,p^2]==1&], {n,50}]] (* T. D. Noe, Aug 24 2008 *)
    Flatten[Table[p=Prime[n]; r=PrimitiveRoot[p]; b=PowerMod[r,p,p^2]; Sort[NestList[Mod[b*#,p^2]&,1,p-2]], {n,50}]] (* Faster version from T. D. Noe, Aug 26 2008 *)

A056026 Numbers k such that k^14 == 1 (mod 15^2).

Original entry on oeis.org

1, 26, 199, 224, 226, 251, 424, 449, 451, 476, 649, 674, 676, 701, 874, 899, 901, 926, 1099, 1124, 1126, 1151, 1324, 1349, 1351, 1376, 1549, 1574, 1576, 1601, 1774, 1799, 1801, 1826, 1999, 2024, 2026, 2051, 2224, 2249, 2251, 2276, 2449, 2474, 2476, 2501
Offset: 1

Views

Author

Robert G. Wilson v, Jun 08 2000

Keywords

Comments

Numbers congruent to {1, 26, 129, 224} mod 225.

Crossrefs

Programs

  • Mathematica
    Select[ Range[ 3000 ], PowerMod[ #, 14, 225 ]==1& ]
    LinearRecurrence[{1,0,0,1,-1},{1,26,199,224,226},50] (* Harvey P. Dale, Nov 11 2011 *)
  • PARI
    a(n) = (-225 - 125*(-1)^n + (171-171*I)*(-I)^n + (171+171*I)*I^n + 450*n)/8 \\ Colin Barker, Oct 16 2015
    
  • PARI
    Vec(x*(1+25*x+173*x^2+25*x^3+x^4)/((1+x)*(1+x^2)*(x-1)^2) + O(x^100)) \\ Colin Barker, Oct 16 2015

Formula

G.f.: x*(1+25*x+173*x^2+25*x^3+x^4) / ( (1+x)*(1+x^2)*(x-1)^2 ). - R. J. Mathar, Oct 25 2011
a(1)=1, a(2)=26, a(3)=199, a(4)=224, a(5)=226, a(n) = a(n-1)+a(n-4)-a(n-5). - Harvey P. Dale, Nov 11 2011
a(n) = (-225 - 125*(-1)^n + (171-171*i)*(-i)^n + (171+171*i)*i^n + 450*n)/8 where i=sqrt(-1). - Colin Barker, Oct 16 2015

A381319 Order of linear recurrence with constant coefficients of solutions of k satisfying k^(n-1) == 1 (mod n^2) for a given n.

Original entry on oeis.org

2, 3, 2, 5, 2, 7, 2, 3, 2, 11, 2, 13, 2, 5, 2, 17, 2, 19, 2, 5, 2, 23, 2, 5, 2, 3, 4, 29, 2, 31, 2, 5, 2, 5, 2, 37, 2, 5, 2, 41, 2, 43, 2, 9, 2, 47, 2, 7, 2, 5, 4, 53, 2, 5, 2, 5, 2, 59, 2, 61, 2, 5, 2, 17, 6, 67, 2, 5, 4, 71, 2, 73, 2, 5, 4, 5, 2, 79, 2, 3, 2, 83, 2, 17, 2, 5, 2, 89
Offset: 2

Views

Author

Mike Sheppard, Feb 20 2025

Keywords

Comments

For a given n, the solutions for k have the linear recurrence with constant coefficients k(m) = k(m-1) + k(m-(a(n)-1)) - k(m-a(n)), with order a(n). If a(n)=2 then the term k(m-1) appears twice and is k(m) = 2*k(m-1) - k(m-2).
Also, k(m) - k(m-(a(n)-1)) = n^2 = k(m-1) - k(m-a(n)), so all have nonhomogeneous linear recurrence of k(m) = k(m-(a(n)-1)) + n^2. Equivalently, k(m) = k(m-A063994(n)) + n^2, with order A063994(n). Thus, k(m) ~ (n^2 / A063994(n)) * m = (n^2 / (a(n)-1)) * m.

Examples

			For n=5 the congruence equation k^4 ==1 mod (5^2) has solutions of k (A056021) which satisfy k(m) = k(m-1) + k(m-4) - k(m-5), the order being 5, a(5)=5.
For n=9, k^8==1 mod (9^2) has solutions of k with recurrence k(m) = k(m-1) + k(m-2) - k(m-3), order 3, a(9)=3.
		

Crossrefs

Cf. A063994, A056020 (n=3), A056021 (n=5), A056022 (n=7), A056024 (n=11), A056025 (n=13), A056028 (n=19), A056031 (n=23), A056034 (n=29), A056035 (n=31).

Programs

  • Mathematica
    A381319[n_] := Times @@ GCD[FactorInteger[n][[All, 1]] - 1, n - 1] + 1;
    Array[A381319, 100, 2] (* Paolo Xausa, Mar 05 2025 *)

Formula

a(n) = 1 + A063994(n).
a(p) = p if p is prime.
Showing 1-10 of 10 results.