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.

A014973 a(n) = n / gcd(n, (n-1)!).

Original entry on oeis.org

1, 2, 3, 2, 5, 1, 7, 1, 1, 1, 11, 1, 13, 1, 1, 1, 17, 1, 19, 1, 1, 1, 23, 1, 1, 1, 1, 1, 29, 1, 31, 1, 1, 1, 1, 1, 37, 1, 1, 1, 41, 1, 43, 1, 1, 1, 47, 1, 1, 1, 1, 1, 53, 1, 1, 1, 1, 1, 59, 1, 61, 1, 1, 1, 1, 1, 67, 1, 1, 1, 71, 1, 73, 1, 1, 1, 1, 1, 79, 1, 1, 1, 83, 1, 1, 1, 1
Offset: 1

Views

Author

Keywords

Comments

Denominator in n!/n^2. Also denominator in Taylor series expansion of dilog function (also called Li_2). - Ralf Stephan, Mar 28 2004

Crossrefs

Cf. A092043.

Programs

  • Magma
    [Denominator(Factorial(n)/n^2): n in [1..80]]; // Vincenzo Librandi, Apr 15 2014
    
  • Maple
    seq(n / igcd(n, (n-1)!), n = 1..88);  # Peter Luschny, Nov 02 2022
  • Mathematica
    Table[n/GCD[n,(n-1)!],{n,90}] (* Harvey P. Dale, Mar 16 2012 *)
    Table[Denominator[n!/n^2], {n, 1, 100}] (* Vincenzo Librandi, Apr 15 2014 *)
  • PARI
    a(n)=numerator(polcoeff((x+1)*exp(x+x*O(x^(n-1))), n-1)); \\ Gerry Martens, Aug 12 2015
    
  • PARI
    a(n) = { my(f = factor(n), res = n); for(i = 1, #f~, res /= f[i, 1]^(min(f[i, 2], val(n-1, f[i, 1]))) ); res }
    val(n, p) = my(r=0); while(n, r+=n\=p); r \\ David A. Corneth, Oct 27 2022
    
  • PARI
    a(n) = if(n == 4, return(2), return(n^isprime(n))) \\ David A. Corneth, Oct 27 2022

Formula

a(4) = 2; otherwise a(n) = 1 unless n is a prime in which case a(n) = n. - Ola Veshta (olaveshta(AT)my-deja.com), May 30 2001
a(n) = denominator((n-1)! * Sum_{i=1..n} (1 - 1/i)). - Mohammed Bouayoun (bouyao(AT)wanadoo.fr), Mar 16 2004
a(n+1) equals the numerator of the coefficient of x^n in the expansion of (1 + x)*exp(x), with denominator A092043(n+1), for n >= 0. - Wolfdieter Lang, Oct 26 2022
a(n) = denominator((-1)^n*n!/(1+n)). - Stefano Spezia, Jun 24 2024