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.

Previous Showing 21-30 of 44 results. Next

A155176 Perimeter s/6 (divided by 6) of primitive Pythagorean triangles such that perimeters are Averages of twin prime pairs, q=p+1, a=q^2-p^2, c=q^2+p^2, b=2*p*q, s=a+b+c, s-+1 are primes.

Original entry on oeis.org

2, 5, 40, 77, 287, 590, 1335, 1717, 2882, 3337, 3927, 4030, 6902, 7315, 7740, 8932, 15965, 20592, 26070, 27405, 34277, 34580, 40920, 50692, 92132, 96647, 113575, 139690, 160557, 167167, 220225, 237407, 279720, 300832, 310765, 336777, 389895
Offset: 1

Views

Author

Keywords

Comments

p=1,q=2,a=3,b=4,c=5,s=12-+1primes, ...

Crossrefs

Programs

  • Mathematica
    lst={};Do[p=n;q=p+1;a=q^2-p^2;c=q^2+p^2;b=2*p*q;s=a+b+c;If[PrimeQ[s-1]&&PrimeQ[s+1],AppendTo[lst,s/6]],{n,8!}];lst

A009188 Short leg of more than one Pythagorean triangle.

Original entry on oeis.org

9, 12, 15, 16, 18, 20, 21, 24, 25, 27, 28, 30, 32, 33, 35, 36, 39, 40, 42, 44, 45, 48, 49, 50, 51, 52, 54, 55, 56, 57, 60, 63, 64, 65, 66, 68, 69, 70, 72, 75, 76, 77, 78, 80, 81, 84, 85, 87, 88, 90, 91, 92, 93, 95, 96, 98, 99, 100, 102, 104, 105, 108, 110, 111, 112, 114, 115, 116
Offset: 1

Views

Author

Keywords

Comments

Values of n for which composite n X n magic squares are possible. - J. Lowell, May 20 2010
If n is in the sequence, k*n is in the sequence for all k > 1. So odd semiprimes (A046315) and numbers of the form 4*p where p is an odd prime are core subsequences which give the initial terms of arithmetic progressions in this sequence. - Altug Alkan, Nov 29 2015
Numbers appearing more than once in A009004. - Sean A. Irvine, Apr 20 2018

Crossrefs

Programs

  • Maple
    filter:= proc(n) not isprime(n) and (n::odd or not isprime(n/2)) end proc:
    select(filter, [$9 .. 10000]); # Robert Israel, Nov 30 2015
  • Mathematica
    filterQ[n_] := !PrimeQ[n] && (OddQ[n] || !PrimeQ[n/2]);
    Select[Range[9, 120], filterQ] (* Jean-François Alcover, Feb 28 2019, from Maple *)
  • PARI
    forcomposite(n=9, 1e3, if(n % 2 == 1 || !isprime(n/2), print1(n, ", "))) \\ Altug Alkan, Dec 01 2015
    
  • Python
    from sympy import primepi
    def A009188(n):
        def f(x): return int(n+2+primepi(x)+primepi(x>>1))
        m, k = n+2, f(n+2)
        while m != k: m, k = k, f(k)
        return m # Chai Wah Wu, Oct 17 2024

Formula

a(n) = A264828(n+2). - Chai Wah Wu, Oct 17 2024

A155177 Area ar/6 (divided by 6) of primitive Pythagorean triangles such that perimeters are Averages of twin prime pairs, q=p+1, a=q^2-p^2, c=q^2+p^2, b=2*p*q, ar=a*b/2; s=a+b+c, s-+1 are primes.

Original entry on oeis.org

1, 5, 140, 385, 2870, 8555, 29370, 42925, 93665, 116795, 149226, 155155, 348551, 380380, 414090, 513590, 1229305, 1801800, 2567895, 2767905, 3873301, 3924830, 5053620, 6970150, 17090486, 18362930, 23396450, 31919165, 39336465, 41791750
Offset: 1

Views

Author

Keywords

Comments

p=1,q=2,a=3,b=4,c=5, ar=3*4/2=6, s=12-+1primes, ...

Crossrefs

Programs

  • Mathematica
    lst={};Do[p=n;q=p+1;a=q^2-p^2;c=q^2+p^2;b=2*p*q;s=a+b+c;ar=a*b/2;If[PrimeQ[s-1]&&PrimeQ[s+1],AppendTo[lst,ar/6]],{n,8!}];lst

A381005 Ordered short legs of the Pythagorean triangles defined by a = 2^(4n) + 2^(2n+1), b = 2^(4n) - 2^(4n-2) - 2^(2n) - 1, c = 2^(4n) + 2^(4n-2) + 2^(2n) + 1.

Original entry on oeis.org

7, 175, 3007, 48895, 785407, 12578815, 201310207, 3221159935, 51539345407, 824632672255, 13194135339007, 211106215755775, 3377699653419007, 54043195260010495, 864691127381393407, 13835058050987196415, 221360928867334750207, 3541774862083514433535, 56668397794160864657407
Offset: 1

Views

Author

Robert C. Lyons, Feb 12 2025

Keywords

Comments

Proper subset of A020884.
Conjecture: These Pythagorean triangles are primitive. Verified up to n=100000.
The preceding conjecture is true, since, for n>=1, the values of a,b,c are given by Euclid's formula for generating Pythagorean triples: a=2xy, b=x^2-y^2, c=x^2+y^2 with x=2^(2n) and y=2^(2n-1)+1 and x and y are coprime and x is even and y is odd. - Chai Wah Wu, Feb 13 2025

Crossrefs

Cf. A020884.
Cf. A381006 (long legs), A381007 (hypotenuses), A381008 (perimeters), A381009 (areas).

Programs

  • Magma
    [2^(4*n) - 2^(4*n-2) - 2^(2*n) - 1: n in [1..20]];
    
  • Mathematica
    A381005[n_] := (3*# + 2)*(# - 2)/4 & [4^n]; Array[A381005, 20] (* or *)
    LinearRecurrence[{21, -84, 64}, {7, 175, 3007}, 20] (* Paolo Xausa, Feb 26 2025 *)
  • PARI
    a(n) = 2^(4*n) - 2^(4*n-2) - 2^(2*n) - 1
    
  • Python
    def A381005(n): return ((m:=1<<(n<<1)-1)-1)*(3*m+1) # Chai Wah Wu, Feb 13 2025

Formula

a(n) = 2^(4n) - 2^(4n-2) - 2^(2n) - 1.
a(n) = sqrt( A381007(n)^2 - A381006(n)^2 ).
G.f.: (7 + 28*x - 80*x^2)/((1 - x)*(1 - 4*x)*(1 - 16*x)). - Stefano Spezia, Feb 13 2025

A081925 Ordered even short legs of primitive Pythagorean triangles.

Original entry on oeis.org

8, 12, 16, 20, 20, 24, 28, 28, 32, 36, 36, 40, 44, 44, 48, 48, 52, 52, 56, 60, 60, 60, 64, 68, 68, 72, 76, 76, 80, 84, 84, 84, 88, 88, 92, 92, 96, 96, 100, 100, 104, 104, 108, 108, 112, 116, 116, 120, 120, 120, 124, 124, 128, 132, 132, 132, 136, 136, 140, 140, 140, 144
Offset: 1

Views

Author

Lekraj Beedassy, Apr 23 2003

Keywords

Crossrefs

Cf. A020884.

Extensions

Corrected and extended by Ray Chandler, Oct 29 2003
Offset corrected by Michel Marcus, Nov 12 2019

A120211 x values giving the smallest integer solutions of y^2 = x*(a^N - x)*( b^N + x) (elliptic curve, Weierstrass equation) with a and b legs in primitive Pythagorean triangles and N = 2. Sequence ordered in increasing values of leg a. Relevant y values in A120210.

Original entry on oeis.org

4, 6, 12, 24, 15, 40, 60, 40, 70, 84, 72, 56, 126, 144, 180, 168, 198, 180, 220, 264, 126, 286, 312, 364, 360, 390, 420, 480, 510, 49, 544, 300, 612, 616, 646, 684, 720, 760, 288, 798, 840, 924, 726, 966, 700, 1012, 1104, 990, 1150, 1200
Offset: 1

Views

Author

Giorgio Balzarotti, Paolo P. Lava, Jun 10 2006

Keywords

Examples

			First primitive Pythagorean triad: 3, 4, 5
Weierstrass equation. y^2 = x*( 3^2 - x)*( 4^2 + x)
Smallest integer solution (x, y) = (4,20)
First element in the sequence x = 4
		

References

  • G. Balzarotti and P. P. Lava, Le sequenze di numeri interi, Hoepli, 2008, p. 47.

Crossrefs

Programs

  • Maple
    flag :=1;x:=0; # a, b, c primitive Pythagorean triad while flag =1 do x:=x+1; y2:= x*( a^2 - x)*(x+b^2); if ((floor(sqrt(y2)))^2=y2)then print( x);flag :=0;fi; od;

A155178 Numbers p of primitive Pythagorean triangles such that perimeters and products of 3 sides are Averages of twin prime pairs, q=p+1, a=q^2-p^2, c=q^2+p^2, b=2*p*q, ar=a*b/2; s=a+b+c, s-+1 are primes, pr=a*b*c, pr-+1 are primes.

Original entry on oeis.org

1, 7916, 35882, 37816, 47491, 128429, 131830, 146471, 154799, 157579, 170219, 174964, 187544, 207829, 208039, 222887, 223142, 262502, 291544, 319825, 327602, 331627, 353857, 476681, 477659, 494207, 522025, 537454, 540682, 558161, 571670
Offset: 1

Views

Author

Keywords

Comments

p=1,q=2,a=3,b=4,c=5,s=12-+1 primes,pr=3*4*5=60-+1 primes, ...

Crossrefs

Programs

  • Mathematica
    lst={};Do[p=n;q=p+1;a=q^2-p^2;c=q^2+p^2;b=2*p*q;ar=a*b/2;s=a+b+c;pr=a*b*c;If[PrimeQ[s-1]&&PrimeQ[s+1]&&PrimeQ[pr-1]&&PrimeQ[pr+1],AppendTo[lst,n]],{n,3*9!}];lst

A024355 Consider primitive Pythagorean triangles (A^2 + B^2 = C^2, (A, B) = 1, A <= B); sequence gives values of AUB, sorted.

Original entry on oeis.org

3, 4, 5, 7, 8, 9, 11, 12, 12, 13, 15, 15, 16, 17, 19, 20, 20, 21, 21, 23, 24, 24, 25, 27, 28, 28, 29, 31, 32, 33, 33, 35, 35, 36, 36, 37, 39, 39, 40, 40, 41, 43, 44, 44, 45, 45, 47, 48, 48, 49, 51, 51, 52, 52, 53, 55, 55, 56, 56, 57, 57, 59, 60, 60, 60, 60, 61, 63, 63, 64, 65
Offset: 1

Views

Author

Keywords

Comments

Union of A020883 and A020884, sorted (with multiplicity); n occurs A024361(n) times. - Ray Chandler, Feb 03 2020

Crossrefs

A024357 Consider primitive Pythagorean triangles (A^2 + B^2 = C^2, (A, B) = 1, A <= B); sequence gives values of AUBUC, sorted.

Original entry on oeis.org

3, 4, 5, 5, 7, 8, 9, 11, 12, 12, 13, 13, 15, 15, 16, 17, 17, 19, 20, 20, 21, 21, 23, 24, 24, 25, 25, 27, 28, 28, 29, 29, 31, 32, 33, 33, 35, 35, 36, 36, 37, 37, 39, 39, 40, 40, 41, 41, 43, 44, 44, 45, 45, 47, 48, 48, 49, 51, 51, 52, 52, 53, 53, 55, 55, 56, 56, 57
Offset: 1

Views

Author

Keywords

Crossrefs

A024411 Short leg of more than one primitive Pythagorean triangle.

Original entry on oeis.org

20, 28, 33, 36, 39, 44, 48, 51, 52, 57, 60, 65, 68, 69, 75, 76, 84, 85, 87, 88, 92, 93, 95, 96, 100, 104, 105, 108, 111, 115, 116, 119, 120, 123, 124, 129, 132, 133, 135, 136, 140, 141, 145, 147, 148, 152, 155, 156, 159, 160, 161, 164, 165, 168, 172, 175, 177, 180, 183, 184
Offset: 1

Views

Author

Keywords

Comments

Every term is composite. - Clark Kimberling, Feb 04 2024
Proof by contradiction: let p prime be the short leg. Then p^2 + b^2 = c^2 i.e., p^2 = (c - b) * (c + b). Then (c - b, c + b) in {(1, p^2), (p, p)}. If (c - b, c + b) = (p, p) then c = p and b = 0 which is impossible. Hence there is at most one solution for (c - b, c + b). A contradiction. - David A. Corneth, Feb 04 2024

Crossrefs

Programs

  • Mathematica
    aa=1;s="";For[a=1,a<=10^2,For[b=a+1,((b+1)^2-b^2)<=a^2,c=(a^2+b^2)^0.5;If[c==Round[c]&&GCD[a,b]==1,If[a==aa,s=s<>ToString[a]<>","];If[a!=aa,aa=a,aa=1]];b++ ];a++ ];s (* Vladimir Joseph Stephan Orlovsky, Apr 29 2008 *)
  • PARI
    is(n) = {
    	my(d = divisors(n^2), q = 0, b, c);
    	for(i = 1, #d\2,
    		if(!bitand(d[#d + 1 - i] - d[i], 1),
    			c = (d[i] + d[#d + 1 - i])/2;
    			b = d[#d + 1 - i] - c;
    			if(gcd(n, b) == 1 && n < b,
    				q++;
    				if(q >= 2,
    					return(1)
    				)
    			)
    		)
    	); 0
    } \\ David A. Corneth, Feb 04 2024
Previous Showing 21-30 of 44 results. Next