login
Grimm numbers (1): a(n) = largest k so that for each m in {n+1, n+2, ..., n+k} there corresponds a different prime factor p_m.
4

%I #23 Apr 23 2024 08:29:06

%S 2,3,4,4,3,5,4,6,6,7,6,7,6,5,8,8,7,8,7,7,8,7,6,7,9,8,8,11,10,11,10,11,

%T 11,10,12,12,11,10,9,9,8,11,10,9,10,9,8,11,13,13,12,11,10,11,14,15,14,

%U 13,12,14,13,12,13,13,14,14,13,12,11,10,9,15,14,13,14,13,13,17,16,17

%N Grimm numbers (1): a(n) = largest k so that for each m in {n+1, n+2, ..., n+k} there corresponds a different prime factor p_m.

%C Guy (2004) discusses some conjectures of Grimm that could produce related sequences.

%C The name "Grimm numbers" refers to the American mathematician Carl Albert Grimm (1926-2018). - _Amiram Eldar_, Apr 23 2024

%D Richard K. Guy, Unsolved Problems in Number Theory, 3rd Edition, Springer, 2004, Section B32, pp. 133-134.

%D József Sándor, Dragoslav S. Mitrinovic, and Borislav Crstici, Handbook of Number Theory I, Springer Science & Business Media, 2005, Chapter XII, p. 438, Section XII.15.

%H T. D. Noe, <a href="/A059686/b059686.txt">Table of n, a(n) for n = 1..10000</a>

%H C. A. Grimm, <a href="http://www.jstor.org/stable/2317188">A conjecture on consecutive composite numbers</a>, Amer. Math. Monthly, 76 (1969), 1126-1128.

%e For n=4 we look at the sequence {5,6,7,8,9,...} and we must pick a different prime factor for as many as we can. We can choose 5 for 5, 3 for 6, 7 for 7, 2 for 8, but now we are stuck, so k=4, a(4) = 4.

%t Needs["DiscreteMath`Combinatorica`"]; factors[n_Integer] := First[Transpose[FactorInteger[n]]]; Join[{2, 3}, Table[k=2; While[s=Table[{}, {n0+k}]; prms=0; Do[If[PrimeQ[n], prms++, t=factors[n]; s[[n]]=t; Do[i=t[[j]]; If[i<n, AppendTo[s[[i]], n]], {j, Length[t]}]], {n, n0+1, n0+k}]; Length[BipartiteMatching[FromAdjacencyLists[s]]]+prms == k, k++ ]; k-1, {n0, 3, 80}]] (* _T. D. Noe_ *)

%Y Cf. A059751, A059752.

%Y Cf. A101083 (largest k such that the product (n+1)(n+2)...(n+k) has at least k distinct prime factors).

%K nonn,easy,nice,look

%O 1,1

%A _N. J. A. Sloane_, Feb 06 2001

%E More terms from _Fabian Rothelius_, Feb 08 2001

%E Corrected and extended by _Naohiro Nomoto_, Feb 28 2001