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

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
Showing 1-1 of 1 results.