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.

A083039 Number of divisors of n that are <= 3.

Original entry on oeis.org

1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3
Offset: 1

Views

Author

Daniele A. Gewurz (gewurz(AT)mat.uniroma1.it) and Francesca Merola (merola(AT)mat.uniroma1.it), May 06 2003

Keywords

Comments

Periodic of period 6. Parker vector of the wreath product of S_3 and S, the symmetric group of a countable set.

Examples

			The divisors of 6 are 1, 2, 3 and 6. Of those divisors, 1, 2 and 3 are <= 3. That's three divisors, therefore, a(6) = 3. - _David A. Corneth_, Sep 30 2017
		

Crossrefs

Programs

  • Mathematica
    LinearRecurrence[{-1, 0, 1, 1},{1, 2, 2, 2},90] (* Ray Chandler, Aug 26 2015 *)
  • PARI
    a(n)=[3,1,2,2,2,1][n%6+1];

Formula

G.f.: x/(1-x) + x^2/(1-x^2) + x^3/(1-x^3).
a(n) = a(n-6) = a(-n).
a(n) = 11/6 - (1/2)*(-1)^n - (1/3)*cos(2*Pi*n/3) - (1/3)*3^(1/2)*sin(2*Pi*n/3). - Richard Choulet, Dec 12 2008
a(n) = Sum_{k=1..1} cos(n*(k - 1)/1*2*Pi)/1 + Sum_{k=1..2} cos(n*(k - 1)/2*2*Pi)/2 + Sum_{k=1..3} cos(n*(k - 1)/3*2*Pi)/3. - Mats Granvik, Sep 09 2012
a(n) = log_2(gcd(n,2) + gcd(n,6)). - Gary Detlefs, Feb 15 2014
a(n) = Sum_{d|n, d<=3} 1. - Wesley Ivan Hurt, Oct 30 2023