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

A174999 Partial sums of A156681.

Original entry on oeis.org

4, 16, 24, 48, 63, 75, 115, 139, 199, 215, 250, 334, 382, 402, 438, 550, 580, 643, 787, 811, 891, 1071, 1092, 1140, 1239, 1267, 1339, 1559, 1679, 1943, 1975, 2020, 2090, 2233, 2293, 2605, 2773, 2809, 2929, 3293, 3338, 3434, 3629, 4049, 4089, 4161, 4385
Offset: 1

Views

Author

Jonathan Vos Post, Apr 03 2010

Keywords

Crossrefs

Cf. A156681.

Formula

a(n) = Sum_{i=1..n} A156681(i).

Extensions

a(45) corrected by Georg Fischer, Aug 29 2020

A195770 Positive integer a is repeated m times, where m is the number of 1-Pythagorean triples (a,b,c) satisfying a<=b.

Original entry on oeis.org

3, 5, 6, 7, 7, 9, 9, 10, 11, 11, 12, 13, 13, 14, 14, 15, 15, 15, 16, 17, 17, 18, 18, 19, 19, 20, 21, 21, 21, 21, 22, 22, 23, 23, 24, 24, 25, 25, 25, 26, 26, 27, 27, 27, 28, 28, 29, 29, 30, 30, 30, 31, 31, 32, 32, 32, 33, 33, 33, 33
Offset: 1

Views

Author

Clark Kimberling, Sep 25 2011

Keywords

Comments

In case the number k=-cos(C) is a rational number, the law of cosines, c^2=a^2+b^2+k*a*b, can be regarded as a Diophantine equation having positive integer solutions a,b,c satisfying a<=b. The terms "k-Pythagorean triple" and "primitive k-Pythagorean triple" generalize the classical terms corresponding to the case k=0.
Example: the first five (3/2)-Pythagorean triples are
(5,18,22),(6,11,16),(9,11,71),(10,36,44),(12,22,32);
the first five primitive (3/2)-Pythagorean triples are
(5,18,22),(6,11,16),(9,64,71),(13,138,148),(14,75,86).
...
If |k|>2, there is no triangle with sidelengths a,b,c satisfying c^2=a^2+b^2+k*a*b, but this equation is, nevertheless, a Diophantine equation for rational k.
...
Related sequences (k-Pythagorean triples):
k...(a(1),b(1),c(1))........a(n).....b(n).....c(n)
0.......(3,4,5).............A009004..A156681..A156682
1.......(3,5,7).............A195770..A195866..A195867
3.......(3,7,11)............A196112..A196113..A196114
4.......(3,8,13)............A196119..A196120..A196121
5.......(1,3,5).............A196155..A196156..A196157
6.......(2,3,7).............A196162..A196163..A196164
7.......(1,1,3).............A196169..A196170..A196171
8.......(1,4,7).............A196176..A196177..A196178
9.......(1,15,19)...........A196183..A196184..A196185
10......(1,2,5).............A196238..A196239..A196240
1/2.....(2,3,4).............A195879..A195880..A195881
3/2.....(5,18,22)...........A195925..A195926..A195927
1/3.....(3,8,9).............A195939..A195940..A195941
2/3.....(4,9,11)............A196001..A196002..A196003
4/3.....(7,36,41)...........A196040..A196041..A196042
5/3.....(7,39,45)...........A196088..A196089..A196090
5/2.....(5,22,28)...........A196026..A196027..A196028
1/4.....(2,2,3).............A196259..A196260..A196261
3/4.....(2,6,7).............A196252..A196253..A196254
5/4.....(3,20,22)...........A196098..A196099..A196100
7/4.....(9,68,76)...........A196105..A196106..A196107
1/5.....(5,7,9).............A196348..A196349..A196350
1/8.....(4,10,11)...........A196355..A196356..A196357
-1......(1,1,1).............A195778..A195794..A195795
-3......(1,3,1).............A196369..A196370..A196371
-4......(1,4,1).............A196376..A196377..A196378
-5......(1,5,1).............A196383..A196384..A196385
-6......(1,6,1).............A196390..A196391..A196392
-1/2....(1,2,2).............A195872..A195873..A195874
-3/2....(2,3,2).............A195918..A195919..A195920
-5/2....(2,5,2).............A196362..A196363..A196364
-1/3....(1,3,3).............A195932..A195933..A195934
-2/3....(2,3,3).............A195994..A195995..A195996
-4/3....(3,4,3).............A196033..A196034..A196035
-5/3....(3,5,3).............A196008..A196009..A196083
-1/4....(1,4,4).............A196266..A196267..A196268
-3/4....(3,4,4).............A196245..A196247..A196248
...
Related sequences (primitive k-Pythagorean triples):
k...(a(1),b(1),c(1))........a(n).....b(n).....c(n)
0.......(3,4,5).............A020884..A156678..A156679
1.......(3,5,7).............A195868..A195869..A195870
3.......(3,7,11)............A196115..A196116..A196117
4.......(3,8,13)............A196122..A196123..A196124
5.......(1,3,5).............A196158..A196159..A196160
6.......(2,3,7).............A196165..A196166..A196167
7.......(1,1,3).............A196172..A196173..A196174
8.......(1,4,7).............A196179..A196180..A196181
9.......(1,15,19)...........A196186..A196187..A196188
10......(1,2,5).............A196241..A196242..A196243
1/2.....(2,3,4).............A195882..A195883..A195884
3/2.....(5,18,22)...........A195928..A195929..A195930
1/3.....(3,8,9).............A195990..A195991..A195992
2/3.....(4,9,11)............A196004..A196005..A196006
4/3.....(7,36,41)...........A196043..A196044..A196045
5/3.....(7,39,45)...........A196091..A196092..A196093
5/2.....(5,22,28)...........A196029..A196030..A196031
1/4.....(2,2,3).............A196262..A196263..A196264
3/4.....(2,6,7).............A196255..A196256..A196257
5/4.....(3,20,22)...........A196101..A196102..A196103
7/4.....(9,68,76)...........A196108..A196109..A196110
1/5.....(5,7,9).............A196351..A196352..A196353
1/8.....(4,10,11)...........A196358..A196359..A196360
-1......(1,1,1).............A195796..A195862..A195863
-3......(1,3,1).............A196372..A196373..A196374
-4......(1,4,1).............A196379..A196380..A196381
-5......(1,5,1).............A196386..A196387..A196388
-6......(1,6,1).............A196393..A196394..A196395
-1/2....(1,2,2).............A195875..A195876..A195877
-3/2....(2,3,2).............A195921..A195922..A195923
-5/2....(2,5,2).............A196365..A196366..A196367
-1/3....(1,3,3).............A195935..A195936..A195937
-2/3....(2,3,3).............A195997..A195998..A195999
-4/3....(3,4,3).............A196036..A196037..A196038
-5/3....(3,5,3).............A196084..A196085..A196086
-1/4....(1,4,4).............A196269..A196270..A196271
-3/4....(3,4,4).............A196249..A196250..A196246
From Georg Fischer, Oct 26 2020: (Start)
The Mathematica program below has fixed limits (z7, z8, z9). Therefore, it misses higher values of b. For example, the following triples are do not show up in the corresponding sequences:
A196112 A196113 A196114 - non-primitive 3-Pythagorean
49: 29 1008 1051
A196241 A196242 A196243 - primitive 10-Pythagorean
31: 13 950 1013
This problem affects 62 of the 74 parameter combinations. (End)

Examples

			The first seven 1-Pythagorean triples (a,b,c), ordered as
described above, are as follows:
3,5,7........7^2 = 3^2 + 5^2 + 3*5
5,16,19.....19^2 = 5^2 + 16^2 + 5*16
6,10,14.....14^2 = 6^2 + 10^2 + 6*10
7,8,13
7,33,37
9,15,21
9,56,61
10,32,38
		

Crossrefs

Programs

  • Maple
    f:= proc(a) local F,r,u,b;
        r:= 3*a^2;
        nops(select(proc(t) local b; b:= (r/t - t - 2*a)/4;
    (t + r/t) mod 4 = 0 and b::integer and b >= a end proc, numtheory:-divisors(3*a^2)));
    end proc:
    seq(a$f(a),a=1..100); # Robert Israel, Jul 04 2024
  • Mathematica
    z8 = 2000; z9 = 400; z7 = 100;
    k = 1; c[a_, b_] := Sqrt[a^2 + b^2 + k*a*b];
    d[a_, b_] := If[IntegerQ[c[a, b]], {a, b, c[a, b]}, 0]
    t[a_] := Table[d[a, b], {b, a, z8}]
    u[n_] := Delete[t[n], Position[t[n], 0]]
    Table[u[n], {n, 1, 15}]
    t = Table[u[n], {n, 1, z8}];
    Flatten[Position[t, {}]]
    u = Flatten[Delete[t, Position[t, {}]]];
    x[n_] := u[[3 n - 2]];
    Table[x[n], {n, 1, z7}]  (* this sequence *)
    y[n_] := u[[3 n - 1]];
    Table[y[n], {n, 1, z7}]  (* A195866 *)
    z[n_] := u[[3 n]];
    Table[z[n], {n, 1, z7}]  (* A195867 *)
    x1[n_] := If[GCD[x[n], y[n], z[n]] == 1, x[n], 0]
    y1[n_] := If[GCD[x[n], y[n], z[n]] == 1, y[n], 0]
    z1[n_] := If[GCD[x[n], y[n], z[n]] == 1, z[n], 0]
    f = Table[x1[n], {n, 1, z9}];
    x2 = Delete[f, Position[f, 0]]  (* A195868 *)
    g = Table[y1[n], {n, 1, z9}];
    y2 = Delete[g, Position[g, 0]]  (* A195869 *)
    h = Table[z1[n], {n, 1, z9}];
    z2 = Delete[h, Position[h, 0]]  (* A195870 *)

Extensions

Name corrected by Robert Israel, Jul 04 2024

A156678 Consider primitive Pythagorean triangles (A^2 + B^2 = C^2, gcd (A, B) = 1, A < BA020884(n)).

Original entry on oeis.org

4, 12, 24, 15, 40, 60, 35, 84, 112, 63, 144, 180, 21, 99, 220, 264, 143, 312, 364, 45, 195, 420, 480, 255, 56, 544, 612, 77, 323, 684, 80, 760, 399, 840, 924, 117, 483, 1012, 1104, 55, 575, 1200, 140, 1300, 165, 675, 1404, 1512, 783, 176, 1624, 1740, 91, 221, 899
Offset: 1

Views

Author

Ant King, Feb 15 2009

Keywords

Comments

The ordered sequence of A values is A020884(n) and the ordered sequence of B values is A020883(n) (allowing repetitions) and A024354(n) (excluding repetitions)

Examples

			As the first four primitive Pythagorean triples (ordered by increasing A) are (3,4,5), (5,12,13), (7,24,25) and (8,15,17), then a(1)=4, a(2)=12, a(3)=24 and a(4)=15.
		

References

  • Beiler, Albert H.: Recreations In The Theory Of Numbers, Chapter XIV, The Eternal Triangle, Dover Publications Inc., New York, 1964, pp. 104-134.
  • Sierpinski, W.; Pythagorean Triangles, Dover Publications, Inc., Mineola, New York, 2003.

Crossrefs

Programs

  • Haskell
    a156678 n = a156678_list !! (n-1)
    a156678_list = f 1 1 where
       f u v | v > uu `div` 2        = f (u + 1) (u + 2)
             | gcd u v > 1 || w == 0 = f u (v + 2)
             | otherwise             = v : f u (v + 2)
             where uu = u ^ 2; w = a037213 (uu + v ^ 2)
    -- Reinhard Zumkeller, Nov 09 2012
  • Mathematica
    PrimitivePythagoreanTriplets[n_]:=Module[{t={{3,4,5}},i=4,j=5},While[i
    				

Formula

a(n) = A020884(n) + A156680(n).

A156682 Consider all Pythagorean triangles A^2 + B^2 = C^2 with AA009004(n)).

Original entry on oeis.org

5, 13, 10, 25, 17, 15, 41, 26, 61, 20, 37, 85, 50, 25, 39, 113, 34, 65, 145, 30, 82, 181, 29, 52, 101, 35, 75, 221, 122, 265, 40, 51, 74, 145, 65, 313, 170, 45, 123, 365, 53, 100, 197, 421, 50, 78, 226, 481, 68, 130, 257, 55, 65, 183, 545, 290, 91, 125, 613, 60, 85, 111
Offset: 1

Views

Author

Ant King, Feb 17 2009

Keywords

Comments

The corresponding sequence for primitive triples is A156679. For all triples, the ordered sequence of C values is A020882 (allowing repetitions) and A009003 (excluding repetitions).

Examples

			As the first four Pythagorean triples (ordered by increasing A) are (3,4,5), (5,12,13), (6,8,10) and (7,24,25), then a(1)=5, a(2)=13, a(3)=10 and a(4)=25.
		

References

  • Beiler, Albert H.: Recreations In The Theory Of Numbers, Chapter XIV, The Eternal Triangle, Dover Publications Inc., New York, 1964, pp. 104-134.
  • Sierpinski, W.; Pythagorean Triangles, Dover Publications, Inc., Mineola, New York, 2003.

Crossrefs

Programs

  • Mathematica
    PythagoreanTriplets[n_]:=Module[{t={{3,4,5}},i=4,j=5},While[i
    				

Formula

a(n) = sqrt(A009004(n)^2 + A156681(n)^2).

A198455 Consider triples a<=b

Original entry on oeis.org

2, 5, 9, 6, 14, 9, 20, 27, 10, 35, 13, 21, 44, 26, 54, 14, 20, 65, 17, 24, 77, 44, 90, 14, 18, 33, 51, 104, 21, 38, 119, 135, 22, 49, 75, 152, 25, 55, 84, 170, 35, 45, 189, 26, 39, 50, 68, 209, 29, 35, 75, 114, 230, 125
Offset: 1

Views

Author

Charlie Marion, Oct 26 2011

Keywords

Comments

See A198453.
The definition amounts to saying that T_a+T_b=T_c where T_i denotes a triangular number (A000217). - N. J. A. Sloane, Apr 01 2020

Examples

			2*3 + 2*3 = 3*4
3*4 + 5*6 = 6*7
4*5 + 9*10 = 10*11
5*6 + 6*7 = 8*9
5*6 + 14*15 = 15*16
6*7 + 9*10 = 11*12
		

References

  • A. H. Beiler, Recreations in the Theory of Numbers, Dover, New York, 1964, pp. 104-134.

Crossrefs

Showing 1-5 of 5 results.