login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A190785 Numbers that are congruent to {0, 2, 3, 5, 7, 9, 11} mod 12. 4

%I #49 Jan 26 2023 20:21:04

%S 0,2,3,5,7,9,11,12,14,15,17,19,21,23,24,26,27,29,31,33,35,36,38,39,41,

%T 43,45,47,48,50,51,53,55,57,59,60,62,63,65,67,69,71,72,74,75,77,79,81,

%U 83,84,86,87,89,91,93,95,96,98,99,101,103,105,107,108,110

%N Numbers that are congruent to {0, 2, 3, 5, 7, 9, 11} mod 12.

%C The key-numbers of the pitches of a ascending melodic minor scale on a standard chromatic keyboard, with root = 0 and raised seventh.

%C First differences are period 7: repeat [1,2,2,2,2,1,2]. - _Bruno Berselli_, May 27 2011

%H Vincenzo Librandi, <a href="/A190785/b190785.txt">Table of n, a(n) for n = 1..1000</a>

%H <a href="/index/Rec#order_08">Index entries for linear recurrences with constant coefficients</a>, signature (1,0,0,0,0,0,1,-1).

%F a(n) = a(n-1) + a(n-7) - a(n-8) for n>8; G.f.: ( 2+x+2*x^2+2*x^3+2*x^4+2*x^5+x^6 ) / ( (x^6+x^5+x^4+x^3+x^2+x+1)*(x-1)^2 ). - _R. J. Mathar_, May 26 2011

%F a(n) = 2*n-floor(2*n/7)-floor(((n-4) mod 7)/5). - _Rolf Pleisch_, Jun 11 2011

%F From _Wesley Ivan Hurt_, Jul 21 2016: (Start)

%F a(n) = a(n-7) + 12 for n>7.

%F a(n) = (84*n - 77 - 2*(n mod 7) - 2*((n+1) mod 7) - 2*((n+2) mod 7) - 2*((n+3) mod 7) + 5*((n+4) mod 7) - 2*((n+5) mod 7) + 5*((n+6) mod 7))/49.

%F a(7*k) = 12*k-1, a(7*k-1) = 12*k-3, a(7*k-2) = 12*k-5, a(7*k-3) = 12*k-7, a(7*k-4) = 12*k-9, a(7*k-5) = 12*k-10, a(7*k-6) = 12*k-12. (End)

%p A190785:=n->12*floor(n/7)+[0, 2, 3, 5, 7, 9, 11][(n mod 7)+1]: seq(A190785(n), n=0..100); # _Wesley Ivan Hurt_, Jul 21 2016

%t Union[Flatten[Table[12n + {0, 2, 3, 5, 7, 9, 11}, {n, 0, 8}]]] (* _Alonso del Arte_, Jun 11 2011 *)

%o (Magma) [n: n in [0..110] | n mod 12 in [0, 2, 3, 5, 7, 9, 11]]; // _Bruno Berselli_, May 27 2011

%o (PARI) a(n)=n\7*12+[0,2,3,5,7,9,11][n%7+1] \\ _Charles R Greathouse IV_, Jun 08 2011

%o (Python)

%o def A190785(n):

%o a, b = divmod(n-1,7)

%o return (0,2,3,5,7,9,11)[b]+12*a # _Chai Wah Wu_, Jan 26 2023

%Y Cf. A083028.

%K nonn,easy

%O 1,2

%A _Roberto Bertocco_, May 26 2011

%E Zero prepended by _Wesley Ivan Hurt_, Jul 21 2016

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 01:06 EDT 2024. Contains 371964 sequences. (Running on oeis4.)