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

A055527 Shortest other leg of a Pythagorean triangle with n as length of a leg.

Original entry on oeis.org

4, 3, 12, 8, 24, 6, 12, 24, 60, 5, 84, 48, 8, 12, 144, 24, 180, 15, 20, 120, 264, 7, 60, 168, 36, 21, 420, 16, 480, 24, 44, 288, 12, 15, 684, 360, 52, 9, 840, 40, 924, 33, 24, 528, 1104, 14, 168, 120, 68, 39, 1404, 72, 48, 33, 76, 840, 1740, 11, 1860, 960, 16, 48, 72
Offset: 3

Views

Author

Henry Bottomley, May 22 2000

Keywords

Comments

From Alex Ratushnyak, Mar 30 2014: (Start)
Least positive k such that n^2 + k^2 is a square.
For odd n, a(n) <= 4*triangular((n-1)/2), because n^2 + (4 * triangular((n-1)/2))^2 = ((n^2+1)/2) ^ 2, which is a perfect square since n is odd.
For n = 4*k+2, a(n) <= 8*triangular(k), because (4k+2)^2 + (4*k*(k+1))^2 = (4*k^2 + 4*k + 2)^2. (End)

Crossrefs

See A082183 for a similar sequence involving triangular numbers.

Programs

  • Mathematica
    Table[k = 1; While[! IntegerQ[Sqrt[n^2 + k^2]], k++]; k, {n, 3, 100}] (* T. D. Noe, Apr 02 2014 *)

Formula

a(n) = sqrt(A055526(n)^2-n^2) = 2*A054436/n.

A055523 Longest other leg of a Pythagorean triangle with n as length of a leg.

Original entry on oeis.org

4, 3, 12, 8, 24, 15, 40, 24, 60, 35, 84, 48, 112, 63, 144, 80, 180, 99, 220, 120, 264, 143, 312, 168, 364, 195, 420, 224, 480, 255, 544, 288, 612, 323, 684, 360, 760, 399, 840, 440, 924, 483, 1012, 528, 1104, 575, 1200, 624, 1300, 675, 1404, 728, 1512, 783
Offset: 3

Views

Author

Henry Bottomley, May 22 2000

Keywords

Crossrefs

Programs

  • Maple
    seq(`if`(n::even, (n/2-1)*(n/2+1), (n-1)*(n+1)/2), n=3..100); # Robert Israel, Dec 16 2014
  • Mathematica
    a[n_Integer/;n>=3]:=(3 (n^2-2)+(-1)^(n+1) (n^2+2))/8 (* Todd Silvestri, Dec 16 2014 *)
  • PARI
    Vec(x^3*(x^3-3*x-4)/((x-1)^3*(x+1)^3) + O(x^100)) \\ Colin Barker, Sep 15 2014

Formula

a(n) = 2*A055522(n)/n = sqrt(A055524(n)^2-n^2).
a(2k) = (k-1)*(k+1), a(2k+1) = 2k*(k+1).
a(n) = 3*a(n-2)-3*a(n-4)+a(n-6). G.f.: x^3*(x^3-3*x-4) / ((x-1)^3*(x+1)^3). - Colin Barker, Sep 15 2014
a(n) = (3*(n^2-2)+(-1)^(n+1)*(n^2+2))/8. - Todd Silvestri, Dec 16 2014
E.g.f.: 1 + (3*x^2/8 + 3*x/8 - 3/4)*exp(x) + (-x^2/8 + x/8 - 1/4)*exp(-x). - Robert Israel, Dec 16 2014

A055524 Longest other side of a Pythagorean triangle with n as length of one of the three sides (in fact n is a leg and a(n) the hypotenuse).

Original entry on oeis.org

5, 5, 13, 10, 25, 17, 41, 26, 61, 37, 85, 50, 113, 65, 145, 82, 181, 101, 221, 122, 265, 145, 313, 170, 365, 197, 421, 226, 481, 257, 545, 290, 613, 325, 685, 362, 761, 401, 841, 442, 925, 485, 1013, 530, 1105, 577, 1201, 626, 1301, 677, 1405, 730, 1513, 785
Offset: 3

Views

Author

Henry Bottomley, May 22 2000

Keywords

Crossrefs

Programs

  • Mathematica
    A055524[n_] := (3*n^2-(-1)^n*(n^2-2)+6)/8; Array[A055524, 100, 3] (* or *)
    LinearRecurrence[{0, 3, 0, -3, 0, 1}, {5, 5, 13, 10, 25, 17}, 100] (* Paolo Xausa, Feb 29 2024 *)
  • PARI
    Vec(-x^3*(2*x^5+x^4-5*x^3-2*x^2+5*x+5)/((x-1)^3*(x+1)^3) + O(x^100)) \\ Colin Barker, Sep 15 2014

Formula

a(n) = sqrt(n^2+A055523(n)^2). a(2k) = k^2+1, a(2k+1) = k^2+(k+1)^2.
a(n) = 3*a(n-2)-3*a(n-4)+a(n-6). G.f.: -x^3*(2*x^5+x^4-5*x^3-2*x^2+5*x+5) / ((x-1)^3*(x+1)^3). - Colin Barker, Sep 15 2014
a(n) = (3*n^2+6-(n^2-2)*(-1)^n)/8. - Luce ETIENNE, Jul 11 2015

A055525 Shortest other side of a Pythagorean triangle having n as length of one of the three sides.

Original entry on oeis.org

4, 3, 3, 8, 24, 6, 12, 6, 60, 5, 5, 48, 8, 12, 8, 24, 180, 12, 20, 120, 264, 7, 7, 10, 36, 21, 20, 16, 480, 24, 44, 16, 12, 15, 12, 360, 15, 9, 9, 40, 924, 33, 24, 528, 1104, 14, 168, 14, 24, 20, 28, 72, 33, 33, 76, 40, 1740, 11, 11, 960, 16, 48, 16, 88, 2244, 32, 92, 24
Offset: 3

Views

Author

Henry Bottomley, May 22 2000

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_] := Block[{a, c, k = 1, n2 = n^2}, While[ If[ k > n, !IntegerQ[c = Sqrt[n2 + k^2]], !IntegerQ[c = Sqrt[n2 + k^2]] && !IntegerQ[a = Sqrt[n2 - k^2]]], k++; If[k == n, k++]]; If[ IntegerQ@ c, k, Sqrt[n2 - a^2]]]; (* Robert G. Wilson v, Feb 23 2024 *)

Formula

From Robert G. Wilson v, Feb 23 2024: (Start)
sqrt(2*(n-1)) < a(n) < n^2/2.
If n = k*m, then a(n) <= k*a(m). (End)

A055526 Shortest hypotenuse of a Pythagorean triangle with n as length of a leg.

Original entry on oeis.org

5, 5, 13, 10, 25, 10, 15, 26, 61, 13, 85, 50, 17, 20, 145, 30, 181, 25, 29, 122, 265, 25, 65, 170, 45, 35, 421, 34, 481, 40, 55, 290, 37, 39, 685, 362, 65, 41, 841, 58, 925, 55, 51, 530, 1105, 50, 175, 130, 85, 65, 1405, 90, 73, 65, 95, 842, 1741, 61, 1861, 962, 65
Offset: 3

Views

Author

Henry Bottomley, May 22 2000

Keywords

Comments

Smallest k>n such that the squarefree part of k+n equals the squarefree part of k-n - Benoit Cloitre, May 26 2002

Crossrefs

Programs

  • Mathematica
    core[n_] := core[n] = Times @@ Map[#[[1]]^Mod[#[[2]], 2] &, FactorInteger[n]];
    A055526[n_] := Block[{k = n}, While[core[++k+n] != core[k-n]]; k];
    Array[A055526, 100, 3] (* Paolo Xausa, Feb 29 2024 *)
  • PARI
    for(n=3,105,s=n+1; while(abs(core(s+n)-core(s-n))>0,s++); print1(s,","))

Formula

a(n) = sqrt(n^2+A055527(n)^2).

A054435 Smallest area of a Pythagorean triangle with n as length of one of the three sides.

Original entry on oeis.org

6, 6, 6, 24, 84, 24, 54, 24, 330, 30, 30, 336, 54, 96, 60, 216, 1710, 96, 210, 1320, 3036, 84, 84, 120, 486, 294, 210, 216, 7440, 384, 726, 240, 210, 270, 210, 6840, 270, 180, 180, 840, 19866, 726, 486, 12144, 25944, 336, 4116, 336, 540, 480, 630, 1944, 726
Offset: 3

Views

Author

Henry Bottomley, May 22 2000

Keywords

Crossrefs

A054436 Smallest area of a Pythagorean triangle with n as length of a leg.

Original entry on oeis.org

6, 6, 30, 24, 84, 24, 54, 120, 330, 30, 546, 336, 60, 96, 1224, 216, 1710, 150, 210, 1320, 3036, 84, 750, 2184, 486, 294, 6090, 240, 7440, 384, 726, 4896, 210, 270, 12654, 6840, 1014, 180, 17220, 840, 19866, 726, 540, 12144, 25944, 336, 4116, 3000, 1734, 1014
Offset: 3

Views

Author

Henry Bottomley, May 22 2000

Keywords

Crossrefs

Programs

  • Maple
    readlib(issqr): for a from 3 to 80 do for b from 1 by 1 while not issqr(a^2+b^2) do od: printf("%d, ",a*b/2) od: # C. Ronaldo
  • Mathematica
    a[n_] := For[k = 1, True, k++, If[IntegerQ[Sqrt[n^2+k^2]], Return[n k/2]]];
    a /@ Range[3, 100] (* Jean-François Alcover, Feb 14 2020 *)

Formula

a(n) = n*A055527(n)/2.

A048759 Longest perimeter of a Pythagorean triangle with n as length of one of the three sides.

Original entry on oeis.org

12, 12, 30, 24, 56, 40, 90, 60, 132, 84, 182, 112, 240, 144, 306, 180, 380, 220, 462, 264, 552, 312, 650, 364, 756, 420, 870, 480, 992, 544, 1122, 612, 1260, 684, 1406, 760, 1560, 840, 1722, 924, 1892, 1012, 2070, 1104, 2256, 1200, 2450, 1300, 2652
Offset: 3

Views

Author

Henry Bottomley, Jun 15 2000

Keywords

Crossrefs

Programs

  • Magma
    [(3*n^2+4*n-n^2*(-1)^n)/4: n in [3..60]]; // Vincenzo Librandi, Jul 19 2015
  • Mathematica
    A048759[n_] := (3 - (-1)^n)*n^2 / 4 + n; Array[A048759, 100, 3] (* or *)
    LinearRecurrence[{0, 3, 0, -3, 0, 1}, {12, 12, 30, 24, 56, 40}, 100] (* Paolo Xausa, Feb 29 2024 *)
  • PARI
    Vec(-2*x^3*(2*x^5+x^4-6*x^3-3*x^2+6*x+6)/((x-1)^3*(x+1)^3) + O(x^100)) \\ Colin Barker, Sep 13 2014
    

Formula

a(n) = n*A029578(n+2) = n+A055523(n)+A055524(n).
a(2*k) = 2*k*(k+1), a(2*k+1) = 2*(2*k+1)*(k+1).
a(n) = 3*a(n-2)-3*a(n-4)+a(n-6). - Colin Barker, Sep 13 2014
G.f.: -2*x^3*(2*x^5+x^4-6*x^3-3*x^2+6*x+6) / ((x-1)^3*(x+1)^3). - Colin Barker, Sep 13 2014
a(n) = (3*n^2+4*n-n^2*(-1)^n)/4. - Luce ETIENNE, Jul 18 2015
E.g.f.: x*((4 + x)*cosh(x) + (3 + 2*x)*sinh(x) - 4*(1 + x))/2. - Stefano Spezia, May 24 2021
Showing 1-8 of 8 results.