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

A054994 Numbers of the form q1^b1 * q2^b2 * q3^b3 * q4^b4 * q5^b5 * ... where q1=5, q2=13, q3=17, q4=29, q5=37, ... (A002144) and b1 >= b2 >= b3 >= b4 >= b5 >= ....

Original entry on oeis.org

1, 5, 25, 65, 125, 325, 625, 1105, 1625, 3125, 4225, 5525, 8125, 15625, 21125, 27625, 32045, 40625, 71825, 78125, 105625, 138125, 160225, 203125, 274625, 359125, 390625, 528125, 690625, 801125, 1015625, 1185665, 1221025, 1373125, 1795625
Offset: 1

Views

Author

Bernard Altschuler (Altschuler_B(AT)bls.gov), May 30 2000

Keywords

Comments

This sequence is related to Pythagorean triples regarding the number of hypotenuses which are in a particular number of total Pythagorean triples and a particular number of primitive Pythagorean triples.
Least integer "mod 4 prime signature" values that are the hypotenuse of at least one primitive Pythagorean triple. - Ray Chandler, Aug 26 2004
See A097751 for definition of "mod 4 prime signature"; terms of A097752 with all prime factors of form 4*k+1.
Sequence A006339 (Least hypotenuse of n distinct Pythagorean triangles) is a subset of this sequence. - Ruediger Jehn, Jan 13 2022

Examples

			1=5^0, 5=5^1, 25=5^2, 65=5*13, 125=5^3, 325=5^2*13, 625=5^4, etc.
		

Crossrefs

Programs

  • Mathematica
    maxTerm = 10^15;(* this limit gives ~ 500 terms *) maxNumberOfExponents = 9;(* this limit has to be increased until the number of reaped terms no longer changes *) bmax = Ceiling[ Log[ maxTerm]/Log[q]]; q = Reap[For[k = 0 ; cnt = 0, cnt <= maxNumberOfExponents, k++, If[PrimeQ[4*k + 1], Sow[4*k + 1]; cnt++]]][[2, 1]]; Clear[b]; b[maxNumberOfExponents + 1] = 0; iter = Sequence @@ Table[{b[k], b[k + 1], bmax[[k]]}, {k, maxNumberOfExponents, 1, -1}]; Reap[ Do[an = Product[q[[k]]^b[k], {k, 1, maxNumberOfExponents}]; If[an <= maxTerm, Print[an]; Sow[an]], Evaluate[iter]]][[2, 1]] // Flatten // Union (* Jean-François Alcover, Jan 18 2013 *)
  • PARI
    list(lim)=
    {
      my(u=[1], v=List(), w=v, pr, t=1);
      forprime(p=5,,
        if(p%4>1, next);
        t*=p;
        if(t>lim, break);
        listput(w,t)
      );
      for(i=1,#w,
        pr=1;
        for(e=1,logint(lim\=1,w[i]),
          pr*=w[i];
          for(j=1,#u,
            t=pr*u[j];
            if(t>lim, break);
            listput(v,t)
          )
        );
        if(w[i]^2Charles R Greathouse IV, Dec 11 2016
    
  • Python
    def generate_A054994():
        """generate arbitrarily many elements of the sequence.
        TO_DO is a list of pairs (radius, exponents) where
        "exponents" is a weakly decreasing sequence, and
        radius == prod(prime_4k_plus_1(i)**j for i,j in enumerate(exponents))
        An example entry is (5525, (2, 1, 1)) because 5525 = 5**2 * 13 * 17.
        """
        TO_DO = {(1,())}
        while True:
            radius, exponents = min(TO_DO)
            yield radius #, exponents
            TO_DO.remove((radius, exponents))
            TO_DO.update(successors(radius,exponents))
    def successors(radius,exponents):
        # try to increase each exponent by 1 if possible
        for i,e in enumerate(exponents):
            if i==0 or exponents[i-1]>e:
                # can add 1 in position i without violating monotonicity
                yield (radius*prime_4k_plus_1(i), exponents[:i]+(e+1,)+exponents[i+1:])
        if exponents==() or exponents[-1]>0: # add new exponent 1 at the end:
            yield (radius*prime_4k_plus_1(len(exponents)), exponents+(1,))
    from sympy import isprime
    primes_congruent_1_mod_4 = [5] # will be filled with 5,13,17,29,37,...
    def prime_4k_plus_1(i): # the i-th prime that is congruent to 1 mod 4
        while i>=len(primes_congruent_1_mod_4): # generate primes on demand
            n = primes_congruent_1_mod_4[-1]+4
            while not isprime(n): n += 4
            primes_congruent_1_mod_4.append(n)
        return primes_congruent_1_mod_4[i]
    for n,radius in enumerate(generate_A054994()):
        if n==34:
            print(radius)
            break # print the first 35 elements
        print(radius, end=", ")
    # Günter Rote, Sep 12 2023

Formula

Sum_{n>=1} 1/a(n) = Product_{n>=1} 1/(1 - 1/A006278(n)) = 1.2707219403... - Amiram Eldar, Oct 20 2020

Extensions

More terms from Henry Bottomley, Mar 14 2001

A097752 Least integer with each "mod 4 prime signature".

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 8, 9, 10, 12, 15, 16, 18, 20, 21, 24, 25, 27, 30, 32, 36, 40, 42, 45, 48, 50, 54, 60, 63, 64, 65, 72, 75, 80, 81, 84, 90, 96, 100, 105, 108, 120, 125, 126, 128, 130, 135, 144, 150, 160, 162, 168, 180, 189, 192, 195, 200, 210, 216, 225, 231, 240, 243
Offset: 1

Views

Author

Ray Chandler, Aug 26 2004

Keywords

Comments

See A097751 for definition of "mod 4 prime signature".
A097751 sorted and duplicates removed; n such that A097751(n)=n.

Crossrefs

Programs

  • Mathematica
    mod4PrimeSignature[n_] := {fi = FactorInteger[n]; If[OddQ[n], 0, fi[[1, 2]]], Select[fi, Mod[#[[1]], 4] == 3 &][[All, 2]]//Sort, Select[fi, Mod[#[[1]], 4] == 1 &][[All, 2]]}; A097751[n_] := Catch[For[k = 2, True, k++, If[ mod4PrimeSignature[k] == mod4PrimeSignature[n], Throw[k]]]]; A097751[1] = 1; Select[ Range[243], A097751[#] == # &] (* Jean-François Alcover, Jan 10 2013 *)
  • PARI
    is(n)=n>>=valuation(n,2); my(e3=valuation(n,3),e1=valuation(n,5),e); n/=3^e3 * 5^e1; forprime(p=7,, e=valuation(n,p); if(p%4==1, if(e1Charles R Greathouse IV, Dec 10 2016
    
  • PARI
    See Greathouse link.

A097751 Least integer with same "mod 4 prime signature" as n.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 3, 8, 9, 10, 3, 12, 5, 6, 15, 16, 5, 18, 3, 20, 21, 6, 3, 24, 25, 10, 27, 12, 5, 30, 3, 32, 21, 10, 15, 36, 5, 6, 15, 40, 5, 42, 3, 12, 45, 6, 3, 48, 9, 50, 15, 20, 5, 54, 15, 24, 21, 10, 3, 60, 5, 6, 63, 64, 65, 42, 3, 20, 21, 30, 3, 72, 5, 10, 75, 12, 21, 30, 3, 80, 81
Offset: 1

Views

Author

Ray Chandler, Aug 26 2004

Keywords

Comments

For n=2^a_0*p_1^a_1*...*p_n^a_n*q_1^b_1*...*q_m^b_m where p_i is a prime of form 4k+3, q_i is a prime of the form 4k+1, with a_1>=a_2>=...>=a_n and b_1>=b_2>=...>=b_m, define "mod 4 prime signature" to be ordered prime exponents [a_0,(a_1,...,a_n),(b_1,...,b_m)].
Least integer with a given "mod 4 prime signature" is obtained by replacing p_i with i-th prime of form 4k+3 and q_i with i-th prime of form 4k+1.

Crossrefs

Programs

  • Mathematica
    mod4PrimeSignature[n_] := {fi = FactorInteger[n]; If[OddQ[n], 0, fi[[1, 2]]], Select[fi, Mod[#[[1]], 4] == 3 &][[All, 2]]//Sort, Select[fi, Mod[#[[1]], 4] == 1 &][[All, 2]]}; a[n_] := Catch[ For[k = 2, True, k++, If[ mod4PrimeSignature[k] == mod4PrimeSignature[n], Throw[k]]]]; a[1] = 1; Table[a[n], {n, 1, 81}] (* Jean-François Alcover, Jan 10 2013 *)

A097753 Table read by antidiagonals of least integer "mod 4 prime signatures" k ordered by number of Pythagorean triples with hypotenuse = k.

Original entry on oeis.org

1, 2, 5, 3, 10, 25, 4, 15, 50, 125, 6, 20, 75, 250, 65, 8, 30, 100, 375, 130, 3125, 9, 40, 150, 500, 195, 6250, 15625, 12, 45, 200, 750, 260, 9375, 31250, 325, 16, 60, 225, 1000, 390, 12500, 46875, 650, 390625, 18, 80, 300, 1125, 520, 18750, 62500, 975
Offset: 1

Views

Author

Ray Chandler, Aug 26 2004

Keywords

Comments

See A097751 for definition of "mod 4 prime signature".
Row 0 of table represents "mod 4 prime signature" values k such that no PTs have hypotenuse=k.
Row n of table, n>0, represents "mod 4 prime signature" values k such that n PTs have hypotenuse=k.

Examples

			Table begins:
0: 1,2,3,4,6,8,9,12,16,18,21,...
1: 5,10,15,20,30,40,45,60,80,90,105,...
2: 25,50,75,100,150,200,225,300,400,450,525,...
3: 125,250,375,500,750,1000,1125,1500,2000,2250,2625,...
4: 65,130,195,260,390,520,585,625,780,1040,1170,...
5: 3125,6250,9375,12500,18750,25000,28125,37500,...
6: 15625,31250,46875,62500,93750,125000,140625,...
7: 325,650,975,1300,1950,2600,2925,3900,5200,...
8: 390625,781250,1171875,1562500,2343750,...
9: 1953125,3906250,5859375,7812500,11718750,...
10: 1625,3250,4875,6500,9750,13000,14625,19500,...
		

Crossrefs

Extensions

Correct offset. Ray Chandler, Jan 15 2013

A097754 Table read by antidiagonals of least integer "mod 4 prime signatures" k ordered by number of primitive Pythagorean triples with hypotenuse = k.

Original entry on oeis.org

1, 2, 5, 3, 25, 65, 4, 125, 325, 1105, 6, 625, 1625, 5525, 32045, 8, 3125, 4225, 27625, 160225, 1185665, 9, 15625, 8125, 71825, 801125, 5928325, 48612265, 10, 78125, 21125, 138125, 2082925, 29641625, 243061325, 2576450045, 12, 390625, 40625
Offset: 1

Views

Author

Ray Chandler, Aug 26 2004

Keywords

Comments

See A097751 for definition of "mod 4 prime signature".
Row 0 of table represents "mod 4 prime signature" values k such that no PPTs have hypotenuse=k.
Row n of table, n>0, represents "mod 4 prime signature" values k such that 2^(n-1) PPTs have hypotenuse=k.

Examples

			Table begins:
0: 1,2,3,4,6,8,9,10,12,15,16,18,20,21,24,27,30,...
1: 5,25,125,625,3125,15625,78125,390625,1953125,...
2: 65,325,1625,4225,8125,21125,40625,105625,203125,...
4: 1105,5525,27625,71825,138125,359125,690625,1221025,...
8: 32045,160225,801125,2082925,4005625,10414625,20028125,...
16: 1185665,5928325,29641625,77068225,148208125,385341125,...
32: 48612265,243061325,1215306625,3159797225,6076533125,...
64: 2576450045,12882250225,64411251125,167469252925,...
128: 157163452745,785817263725,3929086318625,10215624428425,...
256: 11472932050385,57364660251925,286823301259625,...
		

Crossrefs

Row 1 is A000351 except for starting point.

Extensions

Correct offset. Ray Chandler, Jan 15 2013

A097755 Least integer "mod 4 prime signature" values that are the hypotenuse of no Pythagorean triples.

Original entry on oeis.org

1, 2, 3, 4, 6, 8, 9, 12, 16, 18, 21, 24, 27, 32, 36, 42, 48, 54, 63, 64, 72, 81, 84, 96, 108, 126, 128, 144, 162, 168, 189, 192, 216, 231, 243, 252, 256, 288, 324, 336, 378, 384, 432, 441, 462, 486, 504, 512, 567, 576, 648, 672, 693, 729, 756, 768, 864, 882, 924
Offset: 1

Views

Author

Ray Chandler, Aug 26 2004

Keywords

Comments

See A097751 for definition of "mod 4 prime signature".
Row 0 of table described in A097753; terms of A097752 with no prime factor of form 4k+1.

Crossrefs

Extensions

Correct offset. Ray Chandler, Jan 15 2013
Showing 1-6 of 6 results.