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

A114557 a(2n-1) = 2*(p-1) and a(2n) = p + 3, where p=prime(n).

Original entry on oeis.org

2, 5, 4, 6, 8, 8, 12, 10, 20, 14, 24, 16, 32, 20, 36, 22, 44, 26, 56, 32, 60, 34, 72, 40, 80, 44, 84, 46, 92, 50, 104, 56, 116, 62, 120, 64, 132, 70, 140, 74, 144, 76, 156, 82, 164, 86, 176, 92, 192, 100, 200, 104, 204, 106, 212, 110, 216, 112, 224, 116, 252, 130, 260, 134
Offset: 1

Views

Author

Roger L. Bagula, Feb 15 2006

Keywords

Programs

  • Magma
    [((3-(-1)^n)*NthPrime(Floor((n+1)/2)) + (1+5*(-1)^n))/2: n in [1..70]]; // G. C. Greubel, May 20 2019
    
  • Mathematica
    Flatten[Table[Abs[Coefficient[Expand[(x+2)(x -(1 +Sqrt[Prime[n]]))*(x - (1 - Sqrt[Prime[n]]))], x, m]], {n, 1, 50}, {m, 0, 1}]]
    With[{p = Prime[Floor[(n+1)/2]]}, Table[If[OddQ[n], 2*(p-1), p+3], {n, 1, 70}]] (* G. C. Greubel, May 20 2019 *)
  • PARI
    {a(n) = ((3-(-1)^n)*prime(floor((n+1)/2)) + (1+5*(-1)^n))/2}; \\ G. C. Greubel, May 20 2019
    
  • Sage
    [( (3-(-1)^n)*nth_prime(floor((n+1)/2))+ (1+5*(-1)^n))/2 for n in (1..70)] # G. C. Greubel, May 20 2019

Formula

a(2n-1) = A037168(n). a(2n) = A113935(n).
a(n) = ( (3 - (-1)^n)*prime(floor((n+1)/2)) + (1 + 5*(-1)^n) )/2. - G. C. Greubel, May 20 2019

A369497 Table read by rows: row n is the unique primitive Pythagorean triple (a,b,c) such that (a-b+c)/2 = prime(n+2) and whose short leg "a" is even.

Original entry on oeis.org

8, 15, 17, 12, 35, 37, 20, 99, 101, 24, 143, 145, 32, 255, 257, 36, 323, 325, 44, 483, 485, 56, 783, 785, 60, 899, 901, 72, 1295, 1297, 80, 1599, 1601, 84, 1763, 1765, 92, 2115, 2117, 104, 2703, 2705, 116, 3363, 3365, 120, 3599, 3601, 132, 4355, 4357, 140, 4899, 4901, 144, 5183, 5185, 156, 6083, 6085
Offset: 1

Views

Author

Keywords

Comments

See Exercise 3.5 of the reference.

Examples

			Table begins:
  n=1:   8,  15,  17;
  n=2:  12,  35,  37;
  n=3:  20,  99, 101;
  n=4:  24, 143, 145;
  n=5:  32, 255, 257;
		

References

  • Miguel Ángel Pérez García-Ortega, José Manuel Sánchez Muñoz and José Miguel Blanco Casado, El Libro de las Ternas Pitagóricas, Preprint 2024.

Crossrefs

Cf. A037168 (short leg), A040976 (inradius).

Formula

Row n = (a, b, c) = (2*p - 2, p^2 - 2*p, p^2 - 2*p + 2), where p = prime(n+2) = A000040(n+2).
Showing 1-2 of 2 results.