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.

A038610 Least common multiple of integers less than and prime to n.

Original entry on oeis.org

1, 1, 2, 3, 12, 5, 60, 105, 280, 63, 2520, 385, 27720, 6435, 8008, 45045, 720720, 85085, 12252240, 2909907, 3695120, 1322685, 232792560, 37182145, 1070845776, 128707425, 2974571600, 717084225, 80313433200, 215656441, 2329089562800
Offset: 1

Views

Author

Keywords

Comments

If n is a prime power, tau(a(n)) is the number of times n occurs in A034699. (If n is not a prime power, it does not occur in A034699.) - Franklin T. Adams-Watters, Apr 01 2008
a(n) = lcm(A038566(n,k): k = 1..A000010(n)). - Reinhard Zumkeller, Sep 21 2013

Examples

			Since 1, 5, 7, and 11 are relatively prime to 12, a(12) = LCM(1,5,7,11) = 385.
		

Crossrefs

Programs

  • Haskell
    a038610 = foldl lcm 1 . a038566_row
    -- Reinhard Zumkeller, Sep 21 2013, Oct 04 2011
  • Maple
    A038610 := n -> ilcm(op(select(k->igcd(n,k)=1,[$1..n]))); # Peter Luschny, Jun 25 2011
  • Mathematica
    Table[ LCM@@ Flatten[ Position[ GCD[ n, # ]& /@ Range[ n ], 1 ] ], {n, 32} ]
    Join[{1},Table[LCM@@Select[Range[n-1],CoprimeQ[#,n]&],{n,2,40}]] (* Harvey P. Dale, Mar 05 2016 *)
  • PARI
    a(n) = local(r); r=1;for(i=1,n-1,if(gcd(i,n)==1,r=lcm(r,i)));r \\ Franklin T. Adams-Watters, Apr 01 2008
    

Formula

a(n) = e^[Sum_{k=1..n} (1-floor(n^k/k)+floor((n^k -1)/k))*Mangoldt(k)] where Mangoldt is the Mangoldt function. - Anthony Browne, Jun 16 2016