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.

A175884 Numbers that are congruent to {0, 2, 4, 7, 9} mod 12.

Original entry on oeis.org

0, 2, 4, 7, 9, 12, 14, 16, 19, 21, 24, 26, 28, 31, 33, 36, 38, 40, 43, 45, 48, 50, 52, 55, 57, 60, 62, 64, 67, 69, 72, 74, 76, 79, 81, 84, 86, 88, 91, 93, 96, 98, 100, 103, 105, 108, 110, 112, 115, 117, 120, 122, 124, 127, 129, 132, 134, 136, 139, 141, 144, 146, 148, 151
Offset: 1

Views

Author

Bill Shillito (DMAshura(AT)gmail.com), Oct 08 2010

Keywords

Comments

Key-numbers of the pitches of a major pentatonic scale on a standard chromatic keyboard, with root = 0.
The pentatonic scale can also be obtained by omitting the 4th and 7th notes from the diatonic scale, so a(n) = A083026(A032796(n)). - Federico Provvedi, Sep 10 2022

Crossrefs

Subset of A083026 with exact index A032796.

Programs

  • GAP
    Filtered([0..151],n->n mod 12 = 0 or n mod 12 = 2 or n mod 12 = 4 or n mod 12 = 7 or n mod 12 = 9); # Muniru A Asiru, Oct 24 2018
  • Magma
    [Floor(12*(n-1)/5): n in [1..100]]; // G. C. Greubel, Oct 23 2018
    
  • Maple
    seq(floor(12*(n-1)/5),n=1..65); # Muniru A Asiru, Oct 24 2018
  • Mathematica
    fQ[n_] := MemberQ[{0, 2, 4, 7, 9}, Mod[n, 12]]; Select[ Range[0, 152], fQ] (* Robert G. Wilson v, Oct 09 2010 *)
    Table[2n-1+Floor[(n-4)/5]+Floor[(n-1)/5],{n, 100}] (* Federico Provvedi, Jan 13 2018 *)
    Quotient[12(Range[100]-1), 5] (* Federico Provvedi, Oct 19 2018 *)
  • PARI
    a(n)=([0,1,0,0,0,0; 0,0,1,0,0,0; 0,0,0,1,0,0; 0,0,0,0,1,0; 0,0,0,0,0,1; -1,1,0,0,0,1]^n*[0;2;4;7;9;12])[1,1] \\ for offset 0; Charles R Greathouse IV, Jul 06 2017
    
  • PARI
    vector(100, n, floor(12*(n-1)/5)) \\ G. C. Greubel, Oct 23 2018
    

Formula

G.f.: x^2*(2 + 2*x + 3*x^2 + 2*x^3 + 3*x^4) / ((x^4 + x^3 + x^2 + x + 1)*(x-1)^2). - R. J. Mathar, Jul 10 2015
a(n) = 2*n - 1 + floor((n-4)/5) + floor((n-1)/5). - Federico Provvedi, Jan 13 2018
a(n) = floor(12*(n-1)/5). - Federico Provvedi, Oct 19 2018
a(n) = A005843(n) + A057354(n). - Federico Provvedi, Sep 10 2022

Extensions

Offset change by G. C. Greubel, Oct 23 2018