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.

A075660 Let f(n) = abs(lpd(n)-gpf(n)), where lpd(n) is the largest proper divisor of n and gpf(n) is the greatest prime factor of n. Sequence gives number of iterations for f(n) to reach zero.

This page as a plain text file.
%I A075660 #12 Mar 28 2018 22:02:23
%S A075660 1,2,3,1,2,1,2,3,1,1,2,4,5,1,1,2,3,2,3,3,1,1,2,2,1,1,2,3,4,2,3,2,1,1,
%T A075660 1,2,3,1,1,2,3,2,3,3,2,1,2,2,1,4,1,6,7,3,1,2,1,1,2,2,3,1,2,3,1,2,3,4,
%U A075660 1,4,5,2,3,1,4,4,1,2,3,2,3,1,2,2,1,1,1,2,3,3,1,3,1,1,1,3,4,3,2,3
%N A075660 Let f(n) = abs(lpd(n)-gpf(n)), where lpd(n) is the largest proper divisor of n and gpf(n) is the greatest prime factor of n. Sequence gives number of iterations for f(n) to reach zero.
%H A075660 Michael De Vlieger, <a href="/A075660/b075660.txt">Table of n, a(n) for n = 1..10000</a>
%H A075660 Jason Earls, <a href="https://pdfs.semanticscholar.org/4559/ac50797ddeda688576630c4d92229440a0a3.pdf#page=259">Smarandache iterations of the first kind on functions involving divisors and prime factors</a>, in Smarandache Notions Journal (2004), Vol. 14.1, page 259.
%e A075660 a(12)=4 because 12 -> 3 -> 2 -> 1 -> 0.
%t A075660 Array[-1 + Length@ NestWhileList[Function[n, Abs[If[n == 1, 0, #[[-2]]] - SelectFirst[Reverse@ #, PrimeQ]] &@ Divisors[n]], #, # > 0 &] &, 100] (* _Michael De Vlieger_, Mar 28 2018 *)
%o A075660 (PARI) lpd(n)=n/factor(n)[1,1];
%o A075660 gpf(n)=my(f=factor(n)[,1]); f[#f];
%o A075660 f(n)=abs(lpd(n)-gpf(n));
%o A075660 a(n)=my(k=1); while(n=f(n), k++); k \\ _Charles R Greathouse IV_, May 30 2014
%K A075660 nonn
%O A075660 1,2
%A A075660 _Jason Earls_, Sep 23 2002