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 41-50 of 57 results. Next

A239480 Palindromes such that additive and multiplicative persistences coincide.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 22, 33, 99, 101, 111, 121, 131, 141, 151, 161, 171, 202, 212, 222, 262, 282, 303, 313, 393, 404, 424, 454, 474, 525, 545, 565, 585, 595, 636, 656, 676, 757, 838, 858, 959, 1001, 1111, 1221, 1331, 1441, 1991, 2002, 2112, 2552
Offset: 1

Views

Author

Arkadiusz Wesolowski, Mar 20 2014

Keywords

Comments

Palindromes k for which A031286(k) = A031346(k).

Examples

			99 -> 18 -> 9 has additive persistence 2. 99 -> 81 -> 8 has multiplicative persistence 2. The palindromic number 99 is therefore in the sequence.
		

Crossrefs

Programs

  • PARI
    for(n=0, 2552, s=Vec(Str(n)); if(s==vecextract(s, "-1..1"), v=n; a=0; while(n>9, a++; n=sumdigits(n)); n=v; m=0; while(n>9, m++; d=digits(n); n=prod(k=1, #d, d[k])); n=v; if(a==m, print1(n, ", "))));
    
  • Python
    from math import prod
    from itertools import count, islice, product
    def A031286(n):
        ap = 0
        while n > 9: n, ap = sum(map(int, str(n))), ap+1
        return ap
    def A031346(n):
        mp = 0
        while n > 9: n, mp = prod(map(int, str(n))), mp+1
        return mp
    def is_pal(n): return (s:=str(n)) == s[::-1]
    def pals(base=10): # all d-digit palindromes
        digits = "".join(str(i) for i in range(base))
        for d in count(1):
            for p in product(digits, repeat=d//2):
                if d > 1 and p[0] == "0": continue
                left = "".join(p); right = left[::-1]
                for mid in [[""], digits][d%2]: yield int(left + mid + right)
    def ok(n): return is_pal(n) and A031286(n) == A031346(n)
    def agen(): yield from filter(ok, pals())
    print(list(islice(agen(), 20))) # Michael S. Branicky, Jun 22 2023

Formula

A002113 INTERSECT A239427.

A343403 Numbers k such that the product of the digits of k is not the product of digits of any earlier term in the sequence.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 25, 26, 27, 28, 29, 35, 37, 38, 39, 45, 47, 48, 49, 55, 56, 57, 58, 59, 67, 68, 69, 77, 78, 79, 88, 89, 99, 255, 256, 257, 258, 259, 267, 268, 269, 277, 278, 279, 288, 289, 299, 355, 357, 358, 359, 377, 378, 379, 388, 389, 399, 455
Offset: 1

Views

Author

Collin King, Apr 14 2021

Keywords

Comments

Observations:
The digits 0 and 1 appear only in terms 0 and 1, respectively.
Terms cannot contain two 2s, two 3s, a 2 and a 3, a 2 and a 4, a 3 and a 4, or a 4 and a 6.
Digits in each term appear in ascending order (A009994).

Crossrefs

Cf. A003001, A007954, A009994 (ascending digits), A031346, A068189, A343160.

Programs

  • Maple
    # product of digits
    A007954 := proc(n::integer)
        if n = 0 then
            0;
        else
            mul( d, d=convert(n, base, 10)) ;
        end if;
    end proc:
    hit:=Array(0..10000,-1);
    a:=[0];
    hit[0]:=0;
    for n from 1 to 50000 do p:=A007954(n);
       if p>0 and hit[p]=-1 then hit[p]:=n; a:=[op(a),n]; fi; od:
    a; # N. J. A. Sloane, Apr 14 2021
  • PARI
    See Links section.

A381966 Row sums of A381965.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 14, 16, 18, 20, 22, 24, 26, 28, 20, 23, 26, 29, 32, 35, 40, 45, 50, 55, 30, 34, 38, 42, 48, 55, 62, 60, 70, 84, 40, 45, 50, 57, 66, 65, 78, 97, 86, 111, 50, 56, 62, 73, 74, 90, 86, 112, 98, 124, 60, 67, 76, 89, 96, 95, 128, 117
Offset: 0

Views

Author

Paolo Xausa, Mar 12 2025

Keywords

Crossrefs

Programs

  • Mathematica
    A381966[n_] := Total[NestWhileList[Times @@ IntegerDigits[#] &, n, # >= 10 &]];
    Array[A381966, 100, 0]

Formula

a(n) = Sum_{k = 0..A031346(n)} A381965(n,k).

A130544 Multiplicative persistence of n!!.

Original entry on oeis.org

0, 0, 0, 0, 0, 1, 2, 1, 4, 2, 1, 1, 1, 3, 1, 1, 1, 2, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
Offset: 0

Views

Author

Keywords

Comments

From 24!! on all the numbers have same digits equal to zero thus the persistence is equal to 1.

Examples

			6!!= 6*4*2= 48 --> 4*8=32 --> 3*2= 6 --> Persistence=2
13!!=135135 --> 1*3*5*1*3*5=225 -->2*2*5=20 --> 2*0=0 --> Persistence=3
		

Crossrefs

Programs

  • Maple
    P:=proc(n) local i,k,w,ok,cont; for i from 0 by 1 to n do k:=i; w:=i-2; while w>0 do k:=k*w; w:=w-2; od; w:=1; ok:=1; if k<10 then print(0); else cont:=1; while ok=1 do while k>0 do w:=w*(k-(trunc(k/10)*10)); k:=trunc(k/10); od; if w<10 then ok:=0; print(cont); else cont:=cont+1; k:=w; w:=1; fi; od; fi; od; end: P(100);

A131837 Multiplicative persistence of Cullen numbers.

Original entry on oeis.org

0, 0, 0, 2, 2, 1, 2, 2, 1, 1, 1, 2, 2, 1, 3, 2, 1, 2, 2, 2, 1, 1, 3, 2, 1, 1, 1, 2, 2, 2, 2, 1, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, 2, 2, 1, 2, 2, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
Offset: 1

Views

Author

Keywords

Comments

After the 111th term, all the numbers have some digits equal to zero, thus the persistence is equal to 1.

Examples

			Cullen number 65 --> 6*5=30 --> 3*0=0 thus persistence is 2.
		

Crossrefs

Programs

  • Maple
    P:=proc(n) local i,k,w,ok,cont; for i from 0 by 1 to n do w:=1; k:=i*2^i+1; ok:=1; if k<10 then print(0); else cont:=1; while ok=1 do while k>0 do w:=w*(k-(trunc(k/10)*10)); k:=trunc(k/10); od; if w<10 then ok:=0; print(cont); else cont:=cont+1; k:=w; w:=1; fi; od; fi; od; end: P(120);
  • Mathematica
    Table[cn=n*2^n+1;Length[NestWhileList[Times@@IntegerDigits[#]&, cn, #>=10&]], {n, 0, 104}]-1 (* James C. McMahon, Mar 01 2025 *)

Formula

a(n) = A031346(A002064(n)). - Michel Marcus, Mar 01 2025

A131838 Multiplicative persistence of Woodall numbers.

Original entry on oeis.org

0, 0, 1, 2, 3, 3, 2, 1, 1, 1, 2, 2, 1, 2, 2, 1, 5, 2, 2, 1, 1, 8, 3, 1, 1, 1, 2, 2, 2, 2, 1, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, 2, 2, 1, 2, 2, 1, 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
Offset: 1

Views

Author

Keywords

Comments

After the 111th term, all the numbers have some digits equal to zero, thus the persistence is equal to 1.

Examples

			Woodall number 159 --> 1*5*9=45 --> 4*5=20 --> 2*0=0 thus persistence is 3.
		

Crossrefs

Programs

  • Maple
    P:=proc(n) local i,k,w,ok,cont; for i from 1 by 1 to n do w:=1; k:=i*2^i-1; ok:=1; if k<10 then print(0); else cont:=1; while ok=1 do while k>0 do w:=w*(k-(trunc(k/10)*10)); k:=trunc(k/10); od; if w<10 then ok:=0; print(cont); else cont:=cont+1; k:=w; w:=1; fi; od; fi; od; end: P(120);
  • Mathematica
    Table[wn=n*2^n-1;Length[NestWhileList[Times@@IntegerDigits[#]&, wn, #>=10&]], {n,  105}]-1  (* James C. McMahon, Mar 01 2025 *)

Formula

a(n) = A031346(A003261(n)). - Michel Marcus, Mar 01 2025

A159613 Palindromic primes with multiplicative persistence value 1.

Original entry on oeis.org

11, 101, 131, 151, 181, 191, 313, 10301, 10501, 10601, 11311, 11411, 16061, 30103, 30203, 30403, 30703, 30803, 31013, 35053, 38083, 70207, 70507, 70607, 73037, 74047, 90709, 91019, 94049, 1003001, 1008001, 1022201, 1028201, 1035301
Offset: 1

Views

Author

Lekraj Beedassy, Apr 17 2009

Keywords

Crossrefs

Cf. A046501.
Cf. A056709. - R. J. Mathar, Apr 21 2009

Programs

  • Maple
    isA002113 := proc(n) local dgs,i ; dgs := convert(n,base,10) ; for i from 1 to nops(dgs)/2 do if op(i,dgs) <> op(-i,dgs) then RETURN(false): fi; od: RETURN(true) ; end: ndigs := proc(n) max(1, ilog10(n)+1) ; end: A031346 := proc(n) local p,nred; p := 0 ; nred := n ; while ndigs(nred) > 1 do nred := mul(d, d=convert(nred,base,10) ) ; p := p+1 ; od: p ; end: isA159613 := proc(n) RETURN(isprime(n) and isA002113(n) and A031346(n) = 1) ; end: for n from 1 to 100000 do p := ithprime(n) ; if isA159613(p) then printf("%d,",p) ; fi; od: # R. J. Mathar, Apr 21 2009
  • Mathematica
    palpQ[n_]:=Module[{idn=IntegerDigits[n]},idn==Reverse[idn] && Length[ NestWhileList[Times@@IntegerDigits[#]&,n,#>9&]]==2]; Select[Prime[ Range[82000]],palpQ] (* Harvey P. Dale, Dec 16 2011 *)

Formula

A002385 INTERSECT A046501. - R. J. Mathar, Apr 21 2009

Extensions

Extended by R. J. Mathar, Apr 21 2009

A201991 Smallest palindrome which has multiplicative persistence n.

Original entry on oeis.org

0, 11, 44, 55, 77, 868, 69996, 2683862, 6783876, 268969862, 37889398873, 477788989887774
Offset: 0

Views

Author

Arkadiusz Wesolowski, Dec 07 2011

Keywords

Comments

Probably finite.

Examples

			0 has persistence 0.
11 -> 1 has persistence 1.
44 -> 16 -> 6 has persistence 2.
55 -> 25 -> 10 -> 0 has persistence 3.
77 -> 49 -> 36 -> 18 -> 8 has persistence 4.
868 -> 384 -> 96 -> 54 -> 20 -> 0 has persistence 5.
		

Crossrefs

Programs

  • Mathematica
    lst = {}; int[n_] := IntegerDigits[n]; n = 0; Do[While[True, s = Length@int[n]; r = PadRight[int[n], 2*s, Reverse@int[n]]; If[s > 1, r = Drop[r, {s}]]; p = k = FromDigits[r]; c = 0; While[k > 9, k = Times @@ int[k]; c++]; If[c == l, Break[]]; n++]; AppendTo[lst, p], {l, 0, 10}]; lst (* Arkadiusz Wesolowski, Jul 05 2012 *)

A335808 Nonzero multiplicative persistence in base 10: number of iterations of "multiply nonzero digits in base 10" needed to reach a number < 10.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 1, 1, 1, 1, 2, 2, 2, 2, 2, 3, 1, 1, 1, 2, 2, 2, 2, 3, 2, 3, 1, 1, 2, 2, 2, 3, 2, 3, 2, 3, 1, 1, 2, 2, 2, 2, 3, 2, 3, 3, 1, 1, 2, 2, 3, 3, 2, 4, 3, 3, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 1, 1, 2, 3, 3, 3, 3, 3, 3, 2
Offset: 0

Views

Author

Lucas Colucci, Jun 24 2020

Keywords

Comments

Coincides with A031346 up to n=204.
Differs from A087472 first at n=110. - R. J. Mathar, Aug 10 2020

References

  • R. K. Guy, Unsolved Problems in Number Theory, E16, pages 262-263.

Crossrefs

Programs

A117884 Numbers at which the average multiplicative persistence of the interval (0,n) sets a new record.

Original entry on oeis.org

0, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 43, 44, 45, 46, 47, 48, 49, 52, 53, 54, 55, 56, 57, 58, 59, 63, 64, 65, 66, 67, 68, 69, 73, 74, 75, 76, 77, 78, 79, 84, 85, 86, 87, 88, 89, 93, 94, 95, 96
Offset: 0

Views

Author

Sergio Pimentel, May 02 2006

Keywords

Comments

This sequence seems to be finite. a(525)=9999 seems to be the last term, at a record of 2.282. No higher value found up to 100,000 Is the average multiplicative persistence of (0,Inf) = 1 ???

Examples

			E.g."39 belongs to the sequence because the average multiplicative persistence of the interval (0,39)= 1.05 which sets a new record. 40 is not because the average multiplicative persistence of the interval (0,40) = 1.048 which is not a record value"
		

Crossrefs

Previous Showing 41-50 of 57 results. Next