login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

Maximum length of a divisibility chain of consecutive divisors of n.
8

%I #8 Apr 20 2023 02:11:15

%S 1,2,2,3,2,2,2,4,3,2,2,2,2,2,2,5,2,2,2,3,2,2,2,2,3,2,4,3,2,2,2,6,2,2,

%T 2,2,2,2,2,3,2,2,2,3,2,2,2,2,3,2,2,3,2,2,2,3,2,2,2,2,2,2,2,7,2,2,2,3,

%U 2,2,2,2,2,2,2,3,2,2,2,3,5,2,2,2,2,2,2

%N Maximum length of a divisibility chain of consecutive divisors of n.

%H Robert Israel, <a href="/A328162/b328162.txt">Table of n, a(n) for n = 1..10000</a>

%e The divisors of 968 split into consecutive divisibility chains {{1, 2, 4, 8}, {11, 22, 44, 88}, {121, 242, 484, 968}}, so a(968) = 4.

%p f:= proc(n) local F,L,d,i;

%p F:= sort(convert(numtheory:-divisors(n),list));

%p d:= nops(F);

%p L:= Vector(d);

%p L[1]:= 1;

%p for i from 2 to d do

%p if F[i] mod F[i-1] = 0 then L[i]:= L[i-1]+1

%p else L[i]:= 1

%p fi

%p od;

%p max(L)

%p end proc:

%p map(f, [$1..100]); # _Robert Israel_, Apr 20 2023

%t Table[Max@@Length/@Split[Divisors[n],Divisible[#2,#1]&],{n,100}]

%Y Records occur at powers of 2 (A000079).

%Y Taking only proper divisors gives A328194.

%Y Taking only divisors > 1 gives A328195.

%Y The maximum run-length among divisors of n is A055874.

%Y Cf. A000005, A027750, A060680, A060775, A328026, A328028, A328161, A328189.

%K nonn

%O 1,2

%A _Gus Wiseman_, Oct 06 2019