A225634
a(n) = Number of distinct values in column n of A225630.
Original entry on oeis.org
1, 1, 2, 3, 3, 4, 4, 4, 4, 5, 5, 6, 6, 7, 6, 6, 6, 7, 7, 8, 7, 7, 7, 8, 8, 8, 8, 9, 9, 9, 9, 10, 10, 10, 10, 10, 9, 10, 11, 11, 10, 11, 10, 12, 12, 12, 12, 13, 12, 13, 13, 13, 12, 13, 13, 13, 12, 12, 12, 13, 13, 14, 13, 13, 14, 14, 13, 14, 13, 13, 13, 14, 14
Offset: 0
A225629
a(n) = Last value in column n of A225630 which is not yet the fixed point A003418(n) of that column.
Original entry on oeis.org
1, 1, 1, 3, 4, 30, 30, 84, 120, 1260, 840, 13860, 13860, 180180, 180180, 180180, 240240, 6126120, 6126120, 116396280, 58198140, 116396280, 116396280, 2677114440, 2677114440, 13385572200, 13385572200, 40156716600, 40156716600, 776363187600, 776363187600
Offset: 0
A225638
a(n) is the row index where the first term in column n of A225630 equivalent to some term in column n of A225640 is found from.
Original entry on oeis.org
0, 0, 1, 1, 1, 2, 1, 2, 2, 2, 2, 3, 3, 2, 5, 5, 4, 3, 6, 3, 5, 5, 3, 3, 6, 6, 7, 7, 5, 3, 8, 5, 8, 6, 9, 6, 6, 5, 10, 7, 9, 4, 4, 4, 8, 8, 8, 4, 9, 11, 12, 8, 8, 4, 11, 11, 10, 9, 10, 5, 7, 5, 12, 12, 13, 12, 9, 6, 10, 12, 9, 7, 6, 7, 13, 12, 12, 12, 13, 7, 14, 14
Offset: 0
Looking at A225632 and A225642, which are just arrays A225630 and A225640 transposed and repeating values removed, we see that:
row 11 of A225632 is 1, 30, 420, 4620, 13860, 27720;
row 11 of A225642 is 11, 330, 4620, 13860, 27720;
their first common term, 4620 (= A226055(11)), occurs as three positions after the initial 1 of that row in A225632, thus a(11)=3.
Equivalently, 4620 occurs as the element A(3,11) of array A225630.
A226055
a(n) is the first common term in column n of tables A225630 and A225640, when scanned from the top to bottom.
Original entry on oeis.org
1, 1, 2, 3, 4, 30, 6, 84, 120, 180, 210, 4620, 4620, 780, 360360, 360360, 240240, 92820, 12252240, 175560, 58198140, 116396280, 360360, 753480, 2677114440, 13385572200, 26771144400, 40156716600, 2677114440, 13665960, 2329089562800, 82990547640, 48134517631200
Offset: 0
Row 8 of A225632 is 1, 15, 120, 840;
Row 8 of A225642 is 8, 120, 840;
Their first common term from the left is 120, thus a(8)=120.
Original entry on oeis.org
1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 3, 1, 1, 1, 2, 6, 4, 1, 1, 1, 2, 6, 12, 6, 1, 1, 1, 2, 6, 12, 30, 6, 1, 1, 1, 2, 6, 12, 60, 30, 12, 1, 1, 1, 2, 6, 12, 60, 60, 84, 15, 1, 1, 1, 2, 6, 12, 60, 60, 420, 120, 20, 1, 1, 1, 2, 6, 12, 60, 60, 420, 840, 180, 30, 1
Offset: 0
Irregular table
A225632 gives
A225634(n) distinct terms from the beginning of each row.
A003418
Least common multiple (or LCM) of {1, 2, ..., n} for n >= 1, a(0) = 1.
Original entry on oeis.org
1, 1, 2, 6, 12, 60, 60, 420, 840, 2520, 2520, 27720, 27720, 360360, 360360, 360360, 720720, 12252240, 12252240, 232792560, 232792560, 232792560, 232792560, 5354228880, 5354228880, 26771144400, 26771144400, 80313433200, 80313433200, 2329089562800, 2329089562800
Offset: 0
Roland Anderson (roland.anderson(AT)swipnet.se)
LCM of {1,2,3,4,5,6} = 60. The primes up to 6 are 2, 3 and 5. floor(log(6)/log(2)) = 2 so the exponent of 2 is 2.
floor(log(6)/log(3)) = 1 so the exponent of 3 is 1.
floor(log(6)/log(5)) = 1 so the exponent of 5 is 1. Therefore, a(6) = 2^2 * 3^1 * 5^1 = 60. - _David A. Corneth_, Jun 02 2017
- J. M. Borwein and P. B. Borwein, Pi and the AGM, Wiley, 1987, p. 365.
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
- Seiichi Manyama, Table of n, a(n) for n = 0..2308 (first 501 terms from T. D. Noe)
- R. Anderson and N. J. A. Sloane, Correspondence, 1975.
- Dorin Andrica, Sorin Rădulescu, and George Cătălin Ţurcaş, The Exponent of a Group: Properties, Computations and Applications, Disc. Math. and Applications, Springer, Cham (2020), 57-108.
- Javier Cilleruelo, Juanjo Rué, Paulius Šarka, and Ana Zumalacárregui, The least common multiple of sets of positive integers, arXiv:1112.3013 [math.NT], 2011.
- R. E. Crandall and C. Pomerance, Prime numbers: a computational perspective, MR2156291, p. 61.
- Roger B. Eggleton, Least Common Multiple of {1,2,...,n}, Mathematics Magazine, 61(1) (1988), pp. 47-48, Problem 1252.
- Bakir Farhi, An identity involving the least common multiple of binomial coefficients and its application, arXiv:0906.2295 [math.NT], 2009.
- Bakir Farhi, An identity involving the least common multiple of binomial coefficients and its application, Amer. Math. Monthly 116(9) (2009), 836-839.
- Steven Finch, Cilleruelo's LCM Constants, 2013. [Cached copy, with permission of the author]
- V. L. Gavrikov, On property of least common multiple to be a D-magic number, arXiv:1806.09264 [math.NT], 2018.
- S. Labbé and E. Pelantová, Palindromic sequences generated from marked morphisms, arXiv:1409.7510 [math.CO], 2014.
- J. C. Lagarias, An elementary problem equivalent to the Riemann hypothesis, Am. Math. Monthly 109 (6) (2002) 534-543. arXiv:math/0008177 [math.NT], 2000-2001.
- Peter Luschny and S. Wehmeier, The lcm(1, 2, ..., n) as a product of sine values sampled over the points in Farey sequences, arXiv:0909.1838 [math.CA], 2009.
- Des MacHale and Joseph Manning, Maximal runs of strictly composite integers, The Mathematical Gazette, 99, pp 213-219 (2015).
- Greg Martin, A product of Gamma function values at fractions with the same denominator, arXiv:0907.4384 [math.CA], 2009.
- M. Nair, On Chebychev-type inequalities for primes Amer. Math. Monthly 89(2) (1982), 126-129.
- S. Ramanujan, Highly composite numbers, Proceedings of the London Mathematical Society ser. 2, vol. XIV, no. 1 (1915), pp 347-409. (A variant of a better quality with an additional footnote is available here.)
- E. S. Selmer, On the number of prime divisors of a binomial coefficient, Math. Scand. 39 (1976), no. 2, 271-281 (1977).
- Jonathan Sondow, Criteria for irrationality of Euler's constant, Proc. AMS 131 (2003), 3335.
- Rosemary Sullivan and Neil Watling, Independent divisibility pairs on the set of integers from 1 to n, INTEGERS 13 (2013) #A65.
- M. Tchebichef, Mémoire sur les nombres premiers, J. Math. Pures Appliquées 17 (1852), 366-390.
- Helge von Koch, Sur la distribution des nombres premiers, Acta Math. 24 (1) (1901), 159-182.
- Eric Weisstein's World of Mathematics, Least Common Multiple, Chebyshev Functions, Mangoldt Function.
- Index to divisibility sequences
- Index entries for "core" sequences
- Index entries for sequences related to lcm's
Cf.
A000142,
A000793,
A002110,
A002182,
A002201,
A002944,
A014963,
A020500,
A025527,
A038610,
A051173,
A064446,
A064859,
A069513,
A072938,
A093880,
A094348,
A096179,
A099996,
A102910,
A106037,
A119682,
A179661,
A193181,
A225558,
A225630,
A225632,
A225640,
A225642.
Cf.
A025528 (number of prime factors of a(n) with multiplicity).
Cf.
A275120 (lengths of runs of consecutive equal terms),
A276781 (ordinal transform from term a(1)=1 onward).
-
a003418 = foldl lcm 1 . enumFromTo 2
-- Reinhard Zumkeller, Apr 04 2012, Apr 25 2011
-
[1] cat [Exponent(SymmetricGroup(n)) : n in [1..28]]; // Arkadiusz Wesolowski, Sep 10 2013
-
[Lcm([1..n]): n in [0..30]]; // Bruno Berselli, Feb 06 2015
-
A003418 := n-> lcm(seq(i,i=1..n));
HalfFarey := proc(n) local a,b,c,d,k,s; a := 0; b := 1; c := 1; d := n; s := NULL; do k := iquo(n + b, d); a, b, c, d := c, d, k*c - a, k*d - b; if 2*a > b then break fi; s := s,(a/b); od: [s] end: LCM := proc(n) local i; (1/2)*mul(2*sin(Pi*i),i=HalfFarey(n))^2 end: # Peter Luschny
# next Maple program:
a:= proc(n) option remember; `if`(n=0, 1, ilcm(n, a(n-1))) end:
seq(a(n), n=0..33); # Alois P. Heinz, Jun 10 2021
-
Table[LCM @@ Range[n], {n, 1, 40}] (* Stefan Steinerberger, Apr 01 2006 *)
FoldList[ LCM, 1, Range@ 28]
A003418[0] := 1; A003418[1] := 1; A003418[n_] := A003418[n] = LCM[n,A003418[n-1]]; (* Enrique Pérez Herrero, Jan 08 2011 *)
Table[Product[Prime[i]^Floor[Log[Prime[i], n]], {i, PrimePi[n]}], {n, 0, 28}] (* Wei Zhou, Jun 25 2011 *)
Table[Product[Cyclotomic[n, 1], {n, 2, m}], {m, 0, 28}] (* Fred Daniel Kline, May 22 2014 *)
a1[n_] := 1/12 (Pi^2+3(-1)^n (PolyGamma[1,1+n/2] - PolyGamma[1,(1+n)/2])) // Simplify
a[n_] := Denominator[Sqrt[a1[n]]];
Table[If[IntegerQ[a[n]], a[n], a[n]*(a[n])[[2]]], {n, 0, 28}] (* Gerry Martens, Apr 07 2018 [Corrected by Vaclav Kotesovec, Jul 16 2021] *)
-
a(n)=local(t); t=n>=0; forprime(p=2,n,t*=p^(log(n)\log(p))); t
-
a(n)=if(n<1,n==0,1/content(vector(n,k,1/k)))
-
a(n)=my(v=primes(primepi(n)),k=sqrtint(n),L=log(n+.5));prod(i=1,#v,if(v[i]>k,v[i],v[i]^(L\log(v[i])))) \\ Charles R Greathouse IV, Dec 21 2011
-
a(n)=lcm(vector(n,i,i)) \\ Bill Allombert, Apr 18 2012 [via Charles R Greathouse IV]
-
n=1; lim=100; i=1; j=1; until(n==lim, a=lcm(j,i+1); i++; j=a; n++; print(n" "a);); \\ Mike Winkler, Sep 07 2013
-
from functools import reduce
from operator import mul
from sympy import sieve
def integerlog(n,b): # find largest integer k>=0 such that b^k <= n
kmin, kmax = 0,1
while b**kmax <= n:
kmax *= 2
while True:
kmid = (kmax+kmin)//2
if b**kmid > n:
kmax = kmid
else:
kmin = kmid
if kmax-kmin <= 1:
break
return kmin
def A003418(n):
return reduce(mul,(p**integerlog(n,p) for p in sieve.primerange(1,n+1)),1) # Chai Wah Wu, Mar 13 2021
-
# generates initial segment of sequence
from math import gcd
from itertools import accumulate
def lcm(a, b): return a * b // gcd(a, b)
def aupton(nn): return [1] + list(accumulate(range(1, nn+1), lcm))
print(aupton(30)) # Michael S. Branicky, Jun 10 2021
-
[lcm(range(1,n)) for n in range(1, 30)] # Zerinvary Lajos, Jun 06 2009
-
(define (A003418 n) (let loop ((n n) (m 1)) (if (zero? n) m (loop (- n 1) (lcm m n))))) ;; Antti Karttunen, Jan 03 2018
A000793
Landau's function g(n): largest order of permutation of n elements. Equivalently, largest LCM of partitions of n.
Original entry on oeis.org
1, 1, 2, 3, 4, 6, 6, 12, 15, 20, 30, 30, 60, 60, 84, 105, 140, 210, 210, 420, 420, 420, 420, 840, 840, 1260, 1260, 1540, 2310, 2520, 4620, 4620, 5460, 5460, 9240, 9240, 13860, 13860, 16380, 16380, 27720, 30030, 32760, 60060, 60060, 60060, 60060, 120120
Offset: 0
G.f. = 1 + x + 2*x^2 + 3*x^3 + 4*x^4 + 6*x^5 + 6*x^6 + 12*x^7 + 15*x^8 + ...
From _Joerg Arndt_, Feb 15 2013: (Start)
The 15 partitions of 7 are the following:
[ #] [ partition ] lcm( parts )
[ 1] [ 1 1 1 1 1 1 1 ] 1
[ 2] [ 1 1 1 1 1 2 ] 2
[ 3] [ 1 1 1 1 3 ] 3
[ 4] [ 1 1 1 2 2 ] 2
[ 5] [ 1 1 1 4 ] 4
[ 6] [ 1 1 2 3 ] 6
[ 7] [ 1 1 5 ] 5
[ 8] [ 1 2 2 2 ] 2
[ 9] [ 1 2 4 ] 4
[10] [ 1 3 3 ] 3
[11] [ 1 6 ] 6
[12] [ 2 2 3 ] 6
[13] [ 2 5 ] 10
[14] [ 3 4 ] 12 (max)
[15] [ 7 ] 7
The maximum (LCM) value attained is 12, so a(7) = 12.
(End)
- J. Haack, "The Mathematics of Steve Reich's Clapping Music," in Bridges: Mathematical Connections in Art, Music and Science: Conference Proceedings, 1998, Reza Sarhangi (ed.), 87-92.
- Edmund Georg Hermann Landau, Handbuch der Lehre von der Verteilung der Primzahlen, Chelsea Publishing, NY 1953, p. 223.
- J.-L. Nicolas, On Landau's function g(n), pp. 228-240 of R. L. Graham et al., eds., Mathematics of Paul Erdős I.
- S. M. Shah, An inequality for the arithmetical function g(x), J. Indian Math. Soc., 3 (1939), 316-318. [See below for a scan of the first page.]
- N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
- Alois P. Heinz, Table of n, a(n) for n = 0..10000 (terms n = 0..814 from David Wasserman)
- Giedrius Alkauskas, Colouring monohedral tilings: defects and grain boundaries, 2024.
- Joerg Arndt, Table of n, a(n) for n = 0..65536 (xz compressed).
- Jan Brandts and A. Cihangir, Enumeration and investigation of acute 0/1-simplices modulo the action of the hyperoctahedral group, arXiv preprint arXiv:1512.03044 [math.CO], 2015.
- Marc Deléglise, Jean-Louis Nicolas, and Paul Zimmermann, Landau's function for one million billions, arXiv:0803.2160 [math.NT], 2008.
- Marc Deléglise and Jean-Louis Nicolas, On the Largest Product of Primes with Bounded Sum, Journal of Integer Sequences, Vol. 18 (2015), Article 15.2.8.
- Marc Deléglise and Jean-Louis Nicolas, The Landau function and the Riemann hypothesis, Univ. Lyon (France, 2019).
- John D. Dixon and Daniel Panario, The Degree of the Splitting Field of a Random Polynomial over a Finite Field, The Electronic Journal of Combinatorics 11:1 (2004).
- FindStat - Combinatorial Statistic Finder, The order of a permutation
- Jon Grantham, The largest prime dividing the maximal order of an element of S_n, Math. Comput. 64, No. 209, 407-410 (1995).
- Joel K. Haack, The Mathematics of Steve Reich's Clapping Music,in Bridges: Mathematical Connections in Art, Music and Science: Conference Proceedings, 1998, Reza Sarhangi (ed.), 87-92.
- Jan Elmar Krauskopf, Andreas Rauh, and Andreas Hein, Discrete simulation of maypole braiding machines to create collision-free braiding programmes, Heliyon (2025), Art. No. e42917.
- J. Kuzmanovich and A. Pavlichenkov, Finite groups of matrices whose entries are integers, Amer. Math. Monthly, 109 (2002), 173-186.
- Jean-Pierre Massias, Majoration explicite de l'ordre maximum d'un élément du groupe symétrique, (French) [Explicit upper bound on the maximum order of an element of the symmetric group] Ann. Fac. Sci. Toulouse Math. (5) 6 (1984), no. 3-4, 269--281 (1985). MR0799599 (87a:11093).
- Jean-Pierre Massias, Jean-Louis Nicolas, and Guy Robin, Effective bounds for the maximal order of an element in the symmetric group, Math. Comp. 53 (1989), no. 188, 665--678. MR0979940 (90e:11139).
- W. Miller, The Maximum Order of an Element of Finite Symmetric Group, Am. Math. Monthly, Jun-Jul 1987, pp. 497-506.
- Jean-Louis Nicolas, Sur l'ordre maximum d'un élément dans le groupe Sn des permutations, Acta Arith. 14, 315-332 (1968).
- Jean-Louis Nicolas, Ordre maximal d'un élément du groupe S_n des permutations et 'highly composite numbers', Bull. Soc. Math. France 97 (1969), 129-191.
- Jean-Louis Nicolas, Calcul de l'ordre maximum d'un élément du groupe symétrique S_n Revue française d'informatique et de recherche opérationnelle, série rouge 3.2 (1969): 43-50.
- Jean-Louis Nicolas, Ordre maximal d'un e'le'ment du'un groupe de permutations, C. R. Acad. Sci. Paris, A, 270 (1970), 1-4. [Annotated scanned copy]
- Roger D. Nussbaum, Lunel Verduyn, and M. Sjoerd, Asymptotic estimates for the periods of periodic points of non-expansive maps, Ergodic Theory Dynam. Systems 23 (2003), no. 4, pp. 1199-1226. MR1997973 (2004m:37033).
- S. M. Shah, An inequality for the arithmetical function g(x) (scan of first page).
- A. Wechsler, Re: Question (A000793(A007504(n)) =? A002110(n)), SeqFan mailing list, Mar 29 2015.
- Eric Weisstein's World of Mathematics, Landau's Function
- Herbert S. Wilf, The asymptotics of e^P(z) and the number of elements of each order in S_n, Bull. Amer. Math. Soc., 15.2 (1986), 225-232.
- Index entries for sequences related to lcm's
- Index entries for "core" sequences
Cf.
A000792,
A009490,
A034891,
A057731,
A074859,
A128305,
A129759,
A225655,
A225648-
A225650,
A225651,
A225636,
A225558.
-
a000793 = maximum . map (foldl lcm 1) . partitions where
partitions n = ps 1 n where
ps x 0 = [[]]
ps x y = [t:ts | t <- [x..y], ts <- ps t (y - t)]
-- Reinhard Zumkeller, Mar 29 2015
-
A000793 := proc(n)
l := 1:
p := combinat[partition](n):
for i from 1 to combinat[numbpart](n) do
if ilcm( p[i][j] $ j=1..nops(p[i])) > l then
l := ilcm( p[i][j] $ j=1..nops(p[i]))
end if:
end do:
l ;
end proc:
seq(A000793(n),n=0..30) ; # James Sellers, Dec 07 2000
seq( max( op( map( x->ilcm(op(x)), combinat[partition](n)))), n=0..30); # David Radcliffe, Feb 28 2006
# third Maple program:
b:= proc(n, i) option remember; local p;
p:= `if`(i<1, 1, ithprime(i));
`if`(n=0 or i<1, 1, max(b(n, i-1),
seq(p^j*b(n-p^j, i-1), j=1..ilog[p](n))))
end:
a:=n->b(n, `if`(n<8, 3, numtheory[pi](ceil(1.328*isqrt(n*ilog(n)))))):
seq(a(n), n=0..60); # Alois P. Heinz, Feb 16 2013
-
f[n_] := Max@ Apply[LCM, IntegerPartitions@ n, 1]; Array[f, 47] (* Robert G. Wilson v, Oct 23 2011 *)
b[n_, i_] := b[n, i] = Module[{p}, p = If[i<1, 1, Prime[i]]; If[n == 0 || i<1, 1, Max[b[n, i-1], Table[p^j*b[n-p^j, i-1], {j, 1, Log[p, n] // Floor}]]]]; a[n_] := b[n, If[n<8, 3, PrimePi[Ceiling[1.328*Sqrt[n*Log[n] // Floor]]]]]; Table[a[n], {n, 0, 100}] (* Jean-François Alcover, Mar 07 2014, after Alois P. Heinz *)
-
{a(n) = my(m, t, j, u); if( n<2, n>=0, m = ceil(n / exp(1)); t = ceil( (n/m)^m ); j=1; for( i=2, t, u = factor(i); u = sum( k=1, matsize(u)[1], u[k,1]^u[k,2]); if( u<=n, j=i)); j)}; /* Michael Somos, Oct 20 2004 */
-
c=0;A793=apply(t->eval(concat(Vec(t)[#Str(c++) .. -1])),select(t->#t,readstr("/tmp/b000793.txt")));A000793(n)=A793[n+1] \\ Assumes the b-file in the /tmp (or C:\tmp) folder. - M. F. Hasler, Mar 29 2015
-
A008475(n)=my(f=factor(n)); sum(i=1,#f~,f[i,1]^f[i,2]);
a(n)=
{
if(n<2, return(1));
forstep(i=ceil(exp(1.05315*sqrt(log(n)*n))), 2, -1,
if(A008475(i)<=n, return(i))
);
1;
} \\ Charles R Greathouse IV, Apr 28 2015
-
{ \\ translated from code given by Tomas Rokicki
my( N = 100 );
my( V = vector(N,j,1) );
forprime (i=2, N, \\ primes i
forstep (j=N, i, -1,
my( hi = V[j] );
my( pp = i ); \\ powers of prime i
while ( pp<=j, \\ V[] is 1-based
hi = max(if(j==pp, pp, V[j-pp]*pp), hi);
pp *= i;
);
V[j] = hi;
);
);
print( V ); \\ all values
\\ print( V[N] ); \\ just a(N)
\\ print("0 1"); for (n=1, N, print(n, " ", V[n]) ); \\ b-file
} \\ Joerg Arndt, Nov 14 2016
-
{a(n) = my(m=1); if( n<0, 0, forpart(v=n, m = max(m, lcm(Vec(v)))); m)}; /* Michael Somos, Sep 04 2017 */
-
from sympy import primerange
def aupton(N): # compute terms a(0)..a(N)
V = [1 for j in range(N+1)]
for i in primerange(2, N+1):
for j in range(N, i-1, -1):
hi = V[j]
pp = i
while pp <= j:
hi = max((pp if j==pp else V[j-pp]*pp), hi)
pp *= i
V[j] = hi
return V
print(aupton(47)) # Michael S. Branicky, Oct 09 2022 after Joerg Arndt
-
from sympy import primerange,sqrt,log,Rational
def f(N): # compute terms a(0)..a(N)
V = [1 for j in range(N+1)]
if N < 4:
C = 2
else:
C = Rational(166,125)
for i in primerange(C*sqrt(N*log(N))):
for j in range(N, i-1, -1):
hi = V[j]
pp = i
while pp <= j:
hi = max(V[j-pp]*pp, hi)
pp *= i
V[j] = hi
return V
# Philip Turecek, Mar 31 2023
-
def a(n):
return max([lcm(l) for l in Partitions(n)])
# Philip Turecek, Mar 28 2023
-
;; A naive algorithm searching through all partitions of n:
(define (A000793 n) (let ((maxlcm (list 0))) (fold_over_partitions_of n 1 lcm (lambda (p) (set-car! maxlcm (max (car maxlcm) p)))) (car maxlcm)))
(define (fold_over_partitions_of m initval addpartfun colfun) (let recurse ((m m) (b m) (n 0) (partition initval)) (cond ((zero? m) (colfun partition)) (else (let loop ((i 1)) (recurse (- m i) i (+ 1 n) (addpartfun i partition)) (if (< i (min b m)) (loop (+ 1 i))))))))
;; From Antti Karttunen, May 17 2013.
Removed erroneous comment about a(16) which probably originated from misreading a(15)=105 as a(16) because of offset=0: a(16) = 4*5*7 = 140 is correct as it stands. -
M. F. Hasler, Feb 02 2009
A225632
Irregular table read by rows: n-th row gives distinct values of successively iterated Landau-like functions for n, starting with the initial value 1.
Original entry on oeis.org
1, 1, 2, 1, 3, 6, 1, 4, 12, 1, 6, 30, 60, 1, 6, 30, 60, 1, 12, 84, 420, 1, 15, 120, 840, 1, 20, 180, 1260, 2520, 1, 30, 210, 840, 2520, 1, 30, 420, 4620, 13860, 27720, 1, 60, 660, 4620, 13860, 27720, 1, 60, 780, 8580, 60060, 180180, 360360
Offset: 1
The first fifteen rows of table are:
1;
1, 2;
1, 3, 6;
1, 4, 12;
1, 6, 30, 60;
1, 6, 30, 60;
1, 12, 84, 420;
1, 15, 120, 840;
1, 20, 180, 1260, 2520;
1, 30, 210, 840, 2520;
1, 30, 420, 4620, 13860, 27720;
1, 60, 660, 4620, 13860, 27720;
1, 60, 780, 8580, 60060, 180180, 360360;
1, 84, 1260, 16380, 180180, 360360;
1, 105, 4620, 60060, 180180, 360360;
Cf.
A225634 (length of n-th row),
A000793 (n>=2 gives the second column).
Cf.
A225629 (second largest/rightmost term of n-th row).
Cf.
A003418 (largest/rightmost term of n-th row).
Cf.
A225642 (row n starts from n instead of 1).
Cf.
A225638 (distance to that first common term from the beginning of the row n).
Cf.
A226056 (number of trailing terms common with
A225642 on the n-th row).
-
b:= proc(n, i) option remember; `if`(n=0, {1},
`if`(i<1, {}, {seq(map(x->ilcm(x, `if`(j=0, 1, i)),
b(n-i*j, i-1))[], j=0..n/i)}))
end:
T:= proc(n) option remember; local d, h, l, ll;
l:= b(n$2); ll:= NULL; d:=1; h:=0;
while d<>h do ll:= ll, d; h:= d;
d:= max(seq(ilcm(h, i), i=l))
od; ll
end:
seq(T(n), n=1..20); # Alois P. Heinz, May 29 2013
-
b[n_, i_] := b[n, i] = If[n==0, {1}, If[i<1, {}, Table[Map[Function[{x}, LCM[x, If[j==0, 1, i]]], b[n-i*j, i-1]], {j, 0, n/i}]]]; T[n_] := T[n] = Module[{d, h, l, ll}, l=b[n, n]; ll={}; d=1; h=0; While[d != h, AppendTo[ll, d]; h=d; d = Max[ Table[LCM[h, i], {i, l}]]]; ll]; Table[T[n], {n, 1, 20}] // Flatten (* Jean-François Alcover, Jul 29 2015, after Alois P. Heinz *)
A225640
Array A(n,k) of iterated Landau-like functions, where on the row n=0 A(0,0)=1 and A(0,k>=1)=k, and the successive rows A(n,k) give a maximum value lcm(p1,p2,...,pj,A(n-1,k)) for all partitions {p1+p2+...+pj} of k; square array A(n,k), n>=0, k>=0, read by antidiagonals.
Original entry on oeis.org
1, 1, 1, 2, 1, 1, 3, 2, 1, 1, 4, 6, 2, 1, 1, 5, 12, 6, 2, 1, 1, 6, 30, 12, 6, 2, 1, 1, 7, 30, 60, 12, 6, 2, 1, 1, 8, 84, 60, 60, 12, 6, 2, 1, 1, 9, 120, 420, 60, 60, 12, 6, 2, 1, 1, 10, 180, 840, 420, 60, 60, 12, 6, 2, 1, 1, 11, 210, 1260, 840, 420, 60, 60, 12, 6, 2, 1, 1
Offset: 0
The top-left corner of the array:
1, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, ...
1, 1, 2, 6, 12, 30, 30, 84, 120, 180, 210, 330, 420, ...
1, 1, 2, 6, 12, 60, 60, 420, 840, 1260, 840, 4620, 4620, ...
1, 1, 2, 6, 12, 60, 60, 420, 840, 2520, 2520, 13860, 13860, ...
1, 1, 2, 6, 12, 60, 60, 420, 840, 2520, 2520, 27720, 27720, ...
...
Rows converge towards
A003418 (main diagonal of this array).
See
A225630 for a variant employing a similar process, but which uses 1 in column n as the initial seed for that column, instead of n.
A226056
a(n) = Number of common trailing terms on the row n of tables A225632 and A225642.
Original entry on oeis.org
1, 1, 1, 2, 2, 2, 3, 2, 2, 3, 3, 3, 3, 5, 1, 1, 2, 4, 1, 5, 2, 2, 4, 5, 2, 2, 1, 2, 4, 6, 1, 5, 2, 4, 1, 4, 3, 5, 1, 4, 1, 7, 6, 8, 4, 4, 4, 9, 3, 2, 1, 5, 4, 9, 2, 2, 2, 3, 2, 8, 6, 9, 1, 1, 1, 2, 4, 8, 3, 1, 4, 7, 8, 8, 2, 3, 3, 3, 1, 8, 1, 2, 3, 10, 10
Offset: 0
Row 7 of A225632 is: 1, 12, 84, 420;
Row 7 of A225642 is: 7, 84, 420;
the last two terms (84 and 420) are common to them, thus a(7)=2.
Row 14 of A225632 is: 1, 84, 1260, 16380, 180180, 360360;
Row 14 of A225642 is: 14, 630, 8190, 90090, 360360;
they have no common term until as the last term of those rows (which is A003418(14)=360360), thus a(14)=1.
Showing 1-10 of 15 results.
Comments