A178938 Min{ n | A094348(n) element of {A096179(n,k) | 1 <= k <= n}}.
1, 2, 4, 3, 4, 8, 18, 16, 5, 9, 8, 18, 16, 9, 7, 16, 15, 21, 16, 9, 16
Offset: 1
Keywords
Links
- Enrique Pérez Herrero, The triangle A096179.
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.
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
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
72 is a multiple of seven of the first nine positive integers (namely, 1, 2, 3, 4, 6, 8 and 9). It is the smallest positive integer for which this is true.
\\ Computes the first 50 terms of A094348 A094348() = {local(n,i,R,A,len,count,change,high,lim); lim = 7208000; R = vector(500); A = vector(50); A[1]=1; A[2]=2; A[3]=4; A[4]=6; A[5]=12; count=5; high=0; n=12; while(n < lim, d=divisors(n); len=length(d); change=0; for(i=1,min(len,high),if(R[i]>d[i],R[i]=d[i];change=1)); if(len>high,for(i=high+1,len,R[i]=d[i]); high=len); if(change, count++; A[count] = n); n += 12; ); write("A094348.txt", vector(count, i, A[i])); } \\ Peter Luschny, Dec 29 2010
[0] 1 [1] 1 1 [2] 1 3 2 [3] 1 6 11 6 [4] 1 10 31 34 12 [5] 1 15 81 189 182 60 [6] 1 21 141 393 494 282 60
with(combstruct): a181853_row := proc(n) local k,L,l,R,comb; R := NULL; for k from 0 to n do L := 0; comb := iterstructs(Combination(n),size=k): while not finished(comb) do l := nextstruct(comb); L := L + ilcm(op(l)); od; R := R,L; od; R end: # second Maple program: b:= proc(n, k) option remember; `if`(k=0, [1], [`if`(kadd(c, c=b(n, k)): seq(seq(T(n, k), k=0..n), n=0..10); # Alois P. Heinz, Jul 29 2013 # third Maple program: b:= proc(n, m) option remember; expand(`if`(n=0, m, b(n-1, ilcm(m, n))*x+b(n-1, m))) end: T:= n-> (p-> seq(coeff(p, x, i), i=0..n))(b(n, 1)): seq(T(n), n=0..10); # Alois P. Heinz, Sep 05 2023
t[, 0] = 1; t[n, k_] := Sum[LCM @@ c, {c, Subsets[Range[n], {k}]}]; Table[t[n, k], {n, 0, 8}, {k, 0, n}] // Flatten (* Jean-François Alcover, Jul 29 2013 *)
# (After Alois P. Heinz) @CachedFunction def b(n, k): if k == 0: return [1] w = b(n-1, k) if kPeter Luschny, Jul 29 2013
[0] 1 [1] 1 2 [2] 1 4 6 [3] 1 7 18 24 [4] 1 11 42 76 88 [5] 1 16 97 286 468 528 [6] 1 22 163 556 1050 1332 1392
with(combstruct): a181854_row := proc(n) local k,L,l,R,comb; R := NULL; L := 0; for k from 0 to n do comb := iterstructs(Combination(n),size=k): while not finished(comb) do l := nextstruct(comb); L := L + ilcm(op(l)); od; R := R,L; od; R end:
t[, 0] = 1; t[n, k_] := Sum[LCM @@ c, {c, Subsets[Range[n], {k}]}]; row[n_] := Table[t[n, k], {k, 0, n}] // Accumulate; Table[row[n], {n, 0, 8}] // Flatten (* Jean-François Alcover, Jul 30 2013 *)
Triangle begins: [ 1 ], [ 2, 2 ], [ 3, 6, 6 ], [ 4, 12, 12, 12 ], [ 5, 20, 60, 60, 60 ], [ 6, 30, 60, 60, 60, 60 ].
A179661:=func< n, k | Max([ LCM(s): s in Subsets({1..n}, k) ]) >; z:=12; [ A179661(n, k): k in [1..n], n in [1..z] ]; // Klaus Brockhaus, Jan 16 2011
A179661[n_,k_]:=Max[LCM@@@Subsets[Range[n],{k}]]; A002260[n_]:=n-Binomial[Floor[1/2+Sqrt[2*n]],2]; A002024[n_]:=Floor[1/2+Sqrt[2*n]]; A179661[n_]:=A179661[A002024[n],A002260[n]]
1 [1] 2 [2] 4 [4] 6 [3, 6] 12 [12] 24 [8, 24] 36 [9, 18, 36] 48 [16, 48] 60 [5, 10, 15, 20, 30, 60] 72 [72] 120 [40, 120] 180 [45, 90, 180] 240 [80, 240] 360 [360] 420 [7, 14, 21, 28, 35, 42, 70, 84, 105, 140, 210, 420] 720 [144, 720] 840 [56, 168, 280, 840] 1260 [63, 126, 252, 315, 630, 1260] 1680 [112, 336, 560, 1680] 2520 [504, 2520] 5040 [1008, 5040]
Comments