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.

A309892 a(0) = 0, a(1) = 1, and for any n > 1, a(n) is the number of iterations of the map x -> x - gpf(x) (where gpf(x) denotes the greatest prime factor of x) required to reach 0 starting from n.

This page as a plain text file.
%I A309892 #16 Aug 22 2019 20:43:27
%S A309892 0,1,1,1,2,1,2,1,3,3,2,1,4,1,2,3,3,1,4,1,4,3,2,1,4,5,2,5,4,1,6,1,7,3,
%T A309892 2,5,4,1,2,3,6,1,6,1,4,7,2,1,8,7,8,3,4,1,4,5,8,3,2,1,6,1,2,9,3,5,6,1,
%U A309892 4,3,10,1,4,1,2,11,4,7,6,1,12,7,2,1,8,5
%N A309892 a(0) = 0, a(1) = 1, and for any n > 1, a(n) is the number of iterations of the map x -> x - gpf(x) (where gpf(x) denotes the greatest prime factor of x) required to reach 0 starting from n.
%C A309892 This sequence is similar to A175126: here we subtract the greatest prime factor, there the least prime factor.
%H A309892 Antti Karttunen, <a href="/A309892/b309892.txt">Table of n, a(n) for n = 0..16384</a>
%H A309892 Antti Karttunen, <a href="/A309892/a309892.txt">Data supplement: n, a(n) computed for n = 0..65537</a>
%F A309892 a(n) <= n / A006530(n) for any n > 0.
%F A309892 a(n) = n if n <= 1, for n >= 2, a(n) = 1+a(A076563(n)). - _Antti Karttunen_, Aug 22 2019
%e A309892 For n = 16:
%e A309892 - the greatest prime factor of 16 is 2,
%e A309892 - the greatest prime factor of 16-2 = 14 is 7,
%e A309892 - the greatest prime factor of 14-7 = 7 is 7,
%e A309892 - 7 - 7 = 0,
%e A309892 - hence a(16) = 3.
%o A309892 (PARI) a(n) = for (k=0, oo, if (n==0, return (k), n==1, n--, my (f=factor(n)); n-=f[#f~,1]))
%Y A309892 Cf. A006530, A052126, A076563, A175126.
%K A309892 nonn
%O A309892 0,5
%A A309892 _Rémy Sigrist_, Aug 21 2019