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.

A127661 Lengths of the infinitary aliquot sequences.

Original entry on oeis.org

2, 3, 3, 3, 3, 1, 3, 4, 3, 5, 3, 5, 3, 6, 4, 3, 3, 6, 3, 6, 4, 7, 3, 8, 3, 4, 4, 6, 3, 6, 3, 4, 5, 7, 4, 7, 3, 8, 4, 8, 3, 5, 3, 4, 5, 5, 3, 7, 3, 7, 5, 7, 3, 4, 4, 6, 4, 5, 3, 1, 3, 8, 4, 5, 4, 3, 3, 8, 5, 10, 3, 3, 3, 9, 4, 9, 4, 2, 3, 8, 3, 5, 3, 10, 4, 6, 6, 8, 3, 1, 5, 7, 5, 8, 4, 9, 3, 8, 5, 7
Offset: 1

Views

Author

Ant King, Jan 26 2007

Keywords

Comments

An infinitary aliquot sequence is defined by the map x->A049417(x)-x. The map usually terminates with a zero, but may enter cycles (if n in A127662 for example).
The length of an infinitary aliquot sequence is defined to be the length of its transient part + the length of its terminal cycle.
The value of a(840) starting the infinitary aliquot sequence 840 -> 2040 -> 4440 -> 9240 -> 25320,... is >1500. - R. J. Mathar, Oct 05 2017

Examples

			a(4)=3 because the infinitary aliquot sequence generated by 4 is 4 -> 1 -> 0 and it has length 3.
a(6) = 1 because 6 -> 6 -> 6 ->... enters a cycle after 1 term.
a(8) = 4 because 8 -> 7 -> 1 -> 0 terminates after 4 terms.
a(30) = 6 because 30 ->42 -> 54 -> 66 -> 78 -> 90 -> 90 -> 90 -> ...enters a cycle after 6 terms.
a(126)=2 because 126 -> 114 -> 126 enters a cycle after 2 terms.
		

Crossrefs

Programs

  • Maple
    # Uses code snippets of A049417
    A127661 := proc(n)
        local trac,x;
        x := n ;
        trac := [x] ;
        while true do
            x := A049417(x)-trac[-1] ;
            if x = 0 then
                return 1+nops(trac) ;
            elif x in trac then
                return nops(trac) ;
            end if;
            trac := [op(trac),x] ;
        end do:
    end proc:
    seq(A127661(n),n=1..100) ; # R. J. Mathar, Oct 05 2017
  • Mathematica
    ExponentList[n_Integer,factors_List]:={#,IntegerExponent[n,# ]}&/@factors;InfinitaryDivisors[1]:={1}; InfinitaryDivisors[n_Integer?Positive]:=Module[ { factors=First/@FactorInteger[n], d=Divisors[n] }, d[[Flatten[Position[ Transpose[ Thread[Function[{f,g}, BitOr[f,g]==g][ #,Last[ # ]]]&/@ Transpose[Last/@ExponentList[ #,factors]&/@d]],?(And@@#&),{1}]] ]] ]; properinfinitarydivisorsum[k]:=Plus@@InfinitaryDivisors[k]-k;g[n_] := If[n > 0,properinfinitarydivisorsum[n], 0];iTrajectory[n_] := Most[NestWhileList[g, n, UnsameQ, All]];Length[iTrajectory[ # ]] &/@ Range[100]
    (* Second program: *)
    A049417[n_] := If[n == 1, 1, Sort@ Flatten@ Outer[Times, Sequence @@ (FactorInteger[n] /. {p_, m_Integer} :> p^Select[Range[0, m], BitOr[m, #] == m &])]] // Total;
    A127661[n_] := Module[{trac, x}, x = n; trac = {x}; While[True, x = A049417[x] - trac[[-1]]; If[x == 0, Return[1 + Length[trac]], If[MemberQ[trac, x], Return[Length[trac]]]]; trac = Append[trac, x]]];
    Table[A127661[n], {n, 1, 100}] (* Jean-François Alcover, Aug 28 2023, after R. J. Mathar *)

A127662 Integers whose infinitary aliquot sequences end in an infinitary perfect number (A007357).

Original entry on oeis.org

6, 30, 42, 54, 60, 66, 72, 78, 90, 100, 140, 148, 152, 192, 194, 196, 208, 220, 238, 244, 252, 268, 274, 292, 296, 298, 300, 336, 348, 350, 360, 364, 372, 374, 380, 382, 386, 400, 416, 420, 424, 476, 482, 492, 516, 520, 532, 540, 542, 544, 550, 572, 576, 578, 586
Offset: 1

Views

Author

Ant King, Jan 26 2007

Keywords

Examples

			a(5) = 60 because the fifth number whose infinitary aliquot sequence ends in an infinitary perfect number is 60.
6 -> 6 ...
30 -> 42 -> 54 -> 66 -> 78 -> 90 -> 90 -> ..
42 -> 54 -> 66 -> 78 -> 90 -> 90 -> ..
54 -> 66 -> 78 -> 90 -> 90 -> ..
60 -> 60 -> ..
66 -> 78 -> 90 -> 90 -> ..
72 -> 78 -> 90 -> 90 -> ..
78 -> 90 -> 90 -> ..
90 -> 90 -> ..
100 -> 30 -> 42 -> 54 -> 66 -> 78 -> 90 -> 90 -> ..
102 -> 114 -> 126 -> 114 -> ..  cycle but not in the sequence
114 -> 126 -> 114 -> .. cycle but not in the sequence
126 -> 114 -> 126 -> ..
140 -> 100 -> 30 -> 42 -> 54 -> 66 -> 78 -> 90 -> 90 -> ..
148 -> 42 -> 54 -> 66 -> 78 -> 90 -> 90 -> ..
152 -> 148 -> 42 -> 54 -> 66 -> 78 -> 90 -> 90 -> ..
192 -> 148 -> 42 -> 54 -> 66 -> 78 -> 90 -> 90 -> ..
194 -> 100 -> 30 -> 42 -> 54 -> 66 -> 78 -> 90 -> 90 -> ..
196 -> 54 -> 66 -> 78 -> 90 -> 90 -> ..
208 -> 30 -> 42 -> 54 -> 66 -> 78 -> 90 -> 90 -> ..
210 -> 366 -> 378 -> 582 -> 594 -> 846 -> 594 -> ..
220 -> 140 -> 100 -> 30 -> 42 -> 54 -> 66 -> 78 -> 90 -> 90 -> ..
238 -> 194 -> 100 -> 30 -> 42 -> 54 -> 66 -> 78 -> 90 -> 90 -> ..
244 -> 66 -> 78 -> 90 -> 90 -> ..
246 -> 258 -> 270 -> 450 -> 330 -> 534 -> 546 -> 798 -> 1122 -> 1470 -> 2130 -> 3054 -> 3066 -> 4038 -> 4050 -> 2346 -> 2838 -> 3498 -> 4278 -> 4938 -> 4950 -> 4410 -> 4590 -> 8370 -> 14670 -> 14850 -> 22590 -> 22770 -> 29070 -> 35730 -> 35910 -> 79290 -> 79470 -> 79650 -> 107550 -> 79650 -> ..
		

Crossrefs

Programs

  • Maple
    isA007357 := proc(n)
        A049417(n) = 2*n ;
        simplify(%) ;
    end proc:
    isA127662 := proc(n)
        local trac,x;
        x := n ;
        trac := [x] ;
        while true do
            x := A049417(x)-trac[-1] ;
            if x = 0 then
                return false ;
            elif x in trac then
                return isA007357(x) ;
            end if;
            trac := [op(trac),x] ;
        end do:
    end proc:
    for n from 1 do
        if isA127662(n) then
            printf("%d,\n",n) ;
        end if;
    end do: # R. J. Mathar, Oct 05 2017
  • Mathematica
    ExponentList[n_Integer,factors_List]:={#,IntegerExponent[n,# ]}&/@factors;InfinitaryDivisors[1]:={1}; InfinitaryDivisors[n_Integer?Positive]:=Module[ { factors=First/@FactorInteger[n], d=Divisors[n] }, d[[Flatten[Position[ Transpose[ Thread[Function[{f,g}, BitOr[f,g]==g][ #,Last[ # ]]]&/@ Transpose[Last/@ExponentList[ #,factors]&/@d]],?(And@@#&),{1}]] ]] ] Null;properinfinitarydivisorsum[k]:=Plus@@InfinitaryDivisors[k]-k;g[n_] := If[n > 0,properinfinitarydivisorsum[n], 0];iTrajectory[n_] := Most[NestWhileList[g, n, UnsameQ, All]];InfinitaryPerfectNumberQ[0]=False;InfinitaryPerfectNumberQ[k_Integer] :=If[properinfinitarydivisorsum[k]==k,True,False];Select[Range[500],InfinitaryPerfectNumberQ[Last[iTrajectory[ # ]]] &]
    s[n_] := Times @@ (1 + Power @@@ FactorInteger[n]) - n; s[0] = s[1] = 0; q[n_] := Module[{v = NestWhileList[s, n, UnsameQ, All]}, v[[-1]] != n && v[[-2]] == v[[-1]] > 0]; Select[Range[3200], q] (* Amiram Eldar, Mar 11 2023 *)

Extensions

More terms from Amiram Eldar, Mar 11 2023

A127663 Infinitary aspiring numbers.

Original entry on oeis.org

30, 42, 54, 66, 72, 78, 100, 140, 148, 152, 192, 194, 196, 208, 220, 238, 244, 252, 268, 274, 292, 296, 298, 300, 336, 348, 350, 360, 364, 372, 374, 380, 382, 386, 400, 416, 420, 424, 476, 482, 492, 516, 520, 532, 540, 542, 544, 550, 572, 576, 578, 586, 592
Offset: 1

Views

Author

Ant King, Jan 26 2007

Keywords

Comments

Numbers whose infinitary aliquot sequences end in an infinitary perfect number, but are not infinitary perfect numbers themselves.

Examples

			a(5) = 72 because the fifth non-infinitary perfect number whose infinitary aliquot sequence ends in an infinitary perfect number is 72.
		

Crossrefs

Programs

  • Mathematica
    ExponentList[n_Integer,factors_List]:={#,IntegerExponent[n,# ]}&/@factors;InfinitaryDivisors[1]:={1}; InfinitaryDivisors[n_Integer?Positive]:=Module[ { factors=First/@FactorInteger[n], d=Divisors[n] }, d[[Flatten[Position[ Transpose[ Thread[Function[{f,g}, BitOr[f,g]==g][ #,Last[ # ]]]&/@ Transpose[Last/@ExponentList[ #,factors]&/@d]],?(And@@#&),{1}]] ]] ] Null;properinfinitarydivisorsum[k]:=Plus@@InfinitaryDivisors[k]-k;g[n_] := If[n > 0,properinfinitarydivisorsum[n], 0];iTrajectory[n_] := Most[NestWhileList[g, n, UnsameQ, All]];InfinitaryPerfectNumberQ[0]=False;InfinitaryPerfectNumberQ[k_Integer] :=If[properinfinitarydivisorsum[k]==k,True,False];Select[Range[750],InfinitaryPerfectNumberQ[Last[iTrajectory[ # ]]] && !InfinitaryPerfectNumberQ[ # ]&]
    f[p_, e_] := Module[{b = IntegerDigits[e, 2]}, m = Length[b]; Product[If[b[[j]] > 0, 1 + p^(2^(m - j)), 1], {j, 1, m}]]; s[n_] := Times @@ f @@@ FactorInteger[n] - n; s[0] = s[1] = 0; q[n_] := Module[{v = NestWhileList[s, n, UnsameQ, All]}, n != v[[-2]] == v[[-1]] > 0]; Select[Range[839], q]  (* Amiram Eldar, Mar 11 2023 *)

A127665 Numbers whose infinitary aliquot sequences end in an infinitary amicable pair.

Original entry on oeis.org

102, 114, 126, 210, 246, 258, 270, 318, 330, 342, 354, 366, 378, 388, 390, 408, 426, 436, 438, 450, 474, 484, 486, 498, 510, 522, 534, 536, 546, 552, 570, 582, 594, 600, 606, 618, 630, 642, 648, 654, 666, 672, 702, 726, 738, 750, 760, 762, 774, 786, 798
Offset: 1

Views

Author

Ant King, Jan 26 2007

Keywords

Comments

Sometimes called the infinitary 2-cycle attractor set.

Examples

			a(5)=246 because 246 is the fifth number whose infinitary aliquot sequence ends in an infinitary amicable pair.
		

Crossrefs

Programs

  • Mathematica
    ExponentList[n_Integer,factors_List]:={#,IntegerExponent[n,# ]}&/@factors;InfinitaryDivisors[1]:={1}; InfinitaryDivisors[n_Integer?Positive]:=Module[ { factors=First/@FactorInteger[n], d=Divisors[n] }, d[[Flatten[Position[ Transpose[ Thread[Function[{f,g}, BitOr[f,g]==g][ #,Last[ # ]]]&/@ Transpose[Last/@ExponentList[ #,factors]&/@d]],?(And@@#&),{1}]] ]] ] Null;properinfinitarydivisorsum[k]:=Plus@@InfinitaryDivisors[k]-k;g[n_] := If[n > 0,properinfinitarydivisorsum[n], 0];iTrajectory[n_] := Most[NestWhileList[g, n, UnsameQ, All]];InfinitaryAmicableNumberQ[k_]:=If[Nest[properinfinitarydivisorsum,k,2]==k && !properinfinitarydivisorsum[k]==k,True,False];Select[Range[820],InfinitaryAmicableNumberQ[Last[iTrajectory[ # ]]] &]

A127664 Infinitary amicable numbers.

Original entry on oeis.org

114, 126, 594, 846, 1140, 1260, 4320, 5940, 7920, 8460, 8640, 10744, 10856, 11760, 12285, 13500, 14595, 17700, 25728, 35712, 43632, 44772, 45888, 49308, 60858, 62100, 62700, 67095, 67158, 71145, 73962, 74784, 79296, 79650, 79750, 83142, 83904, 86400, 88730
Offset: 1

Views

Author

Ant King, Jan 26 2007

Keywords

Examples

			a(5)=1140 because 1140 is the fifth infinitary amicable number.
		

Crossrefs

Programs

  • Mathematica
    ExponentList[n_Integer,factors_List]:={#,IntegerExponent[n,# ]}&/@factors;InfinitaryDivisors[1]:={1}; InfinitaryDivisors[n_Integer?Positive]:=Module[ { factors=First/@FactorInteger[n], d=Divisors[n] }, d[[Flatten[Position[ Transpose[ Thread[Function[{f,g}, BitOr[f,g]==g][ #,Last[ # ]]]&/@ Transpose[Last/@ExponentList[ #,factors]&/@d]],?(And@@#&),{1}]] ]] ] Null;properinfinitarydivisorsum[k]:=Plus@@InfinitaryDivisors[k]-k;g[n_] := If[n > 0,properinfinitarydivisorsum[n], 0];iTrajectory[n_] := Most[NestWhileList[g, n, UnsameQ, All]];InfinitaryAmicableNumberQ[k_]:=If[Nest[properinfinitarydivisorsum,k,2]==k && !properinfinitarydivisorsum[k]==k,True,False];Select[Range[50000],InfinitaryAmicableNumberQ[ # ] &]
    fun[p_, e_] := Module[{b = IntegerDigits[e, 2]}, m = Length[b]; Product[If[b[[j]] > 0, 1 + p^(2^(m - j)), 1], {j, 1, m}]]; infs[n_] := Times @@ (fun @@@ FactorInteger[n]) - n; s = {}; Do[k = infs[n]; If[k != n && infs[k] == n, AppendTo[s, n]], {n, 2, 10^5}]; s (* Amiram Eldar, Mar 16 2019 *)

Formula

Non-infinitary perfect numbers which satisfy A126168(A126168(n)) = n.

Extensions

More terms from Amiram Eldar, Mar 16 2019
Showing 1-5 of 5 results.