The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A183063 Number of even divisors of n. 59

%I #107 Dec 16 2023 15:00:07

%S 0,1,0,2,0,2,0,3,0,2,0,4,0,2,0,4,0,3,0,4,0,2,0,6,0,2,0,4,0,4,0,5,0,2,

%T 0,6,0,2,0,6,0,4,0,4,0,2,0,8,0,3,0,4,0,4,0,6,0,2,0,8,0,2,0,6,0,4,0,4,

%U 0,4,0,9,0,2,0,4,0,4,0,8,0,2,0,8,0,2

%N Number of even divisors of n.

%C Number of divisors of n that are divisible by 2. More generally, it appears that the sequence formed by starting with an initial set of k-1 zeros followed by the members of A000005, with k-1 zeros between every one of them, can be defined as "the number of divisors of n that are divisible by k", (k >= 1). For example if k = 1 we have A000005 by definition, if k = 2 we have this sequence. Note that if k >= 3 the sequences are not included in the OEIS because the usual OEIS policy is not to include sequences like this where alternate terms are zero; this is an exception. - _Omar E. Pol_, Oct 18 2011

%C Number of zeros in n-th row of triangle A247795. - _Reinhard Zumkeller_, Sep 28 2014

%C a(n) is also the number of partitions of n into equal parts, minus the number of partitions of n into consecutive parts. - _Omar E. Pol_, May 04 2017

%C a(n) is also the number of partitions of n into an even number of equal parts. - _Omar E. Pol_, May 14 2017

%H Charles R Greathouse IV, <a href="/A183063/b183063.txt">Table of n, a(n) for n = 1..10000</a>

%H Mircea Merca, <a href="http://dx.doi.org/10.1016/j.jnt.2015.08.014">Combinatorial interpretations of a recent convolution for the number of divisors of a positive integer</a>, Journal of Number Theory, Volume 160, March 2016, Pages 60-75, function tau_e(n).

%F a(n) = A000005(n) - A001227(n).

%F a(2n-1) = 0; a(2n) = A000005(n).

%F G.f.: Sum_{d>=1} x^(2*d)/(1 - x^(2*d)) and generally for the number of divisors that are divisible by k: Sum_{d>=1} x^(k*d)/(1 - x^(k*d)). - _Geoffrey Critzer_, Apr 15 2014

%F Dirichlet g.f.: zeta(s)^2/2^s and generally for the number of divisors that are divisible by k: zeta(s)^2/k^s. - _Geoffrey Critzer_, Mar 28 2015

%F From _Ridouane Oudra_, Sep 02 2019: (Start)

%F a(n) = Sum_{i=1..n} (floor(n/(2*i)) - floor((n-1)/(2*i))).

%F a(n) = 2*A000005(n) - A000005(2n). (End)

%F Conjecture: a(n) = lim_{x->n} f(Pi*x), where f(x) = sin(x)*Sum_{k>0} (cot(x/(2*k))/(2*k) - 1/x). - _Velin Yanev_, Dec 16 2019

%F a(n) = A000005(A000265(n))*A007814(n) - _Chai Wah Wu_, Jul 16 2022

%F Sum_{k=1..n} a(k) ~ n*log(n)/2 + (gamma - 1/2 - log(2)/2)*n, where gamma is Euler's constant (A001620). - _Amiram Eldar_, Nov 27 2022

%F Limit_{m->oo} (1/m) * Sum_{k=1..m} a(k)/A000005(k) = 1-log(2) (A244009). - _Amiram Eldar_, Mar 01 2023

%e For n = 12, set of even divisors is {2, 4, 6, 12}, so a(12) = 4.

%e On the other hand, there are six partitions of 12 into equal parts: [12], [6, 6], [4, 4, 4], [3, 3, 3, 3], [2, 2, 2, 2, 2, 2] and [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]. And there are two partitions of 12 into consecutive parts: [12] and [5, 4, 3], so a(12) = 6 - 2 = 4, equaling the number of even divisors of 12. - _Omar E. Pol_, May 04 2017

%p A183063 := proc(n)

%p if type(n,'even') then

%p numtheory[tau](n/2) ;

%p else

%p 0;

%p end if;

%p end proc: # _R. J. Mathar_, Jun 18 2015

%t Table[Length[Select[Divisors[n], EvenQ]], {n, 90}] (* _Alonso del Arte_, Jan 10 2012 *)

%t a[n_] := (e = IntegerExponent[n, 2]) * DivisorSigma[0, n / 2^e]; Array[a, 100] (* _Amiram Eldar_, Jul 06 2022 *)

%o (PARI) a(n)=if(n%2,0,numdiv(n/2)) \\ _Charles R Greathouse IV_, Jul 29 2011

%o (Haskell)

%o a183063 = sum . map (1 -) . a247795_row

%o -- _Reinhard Zumkeller_, Sep 28 2014, Jan 15 2013, Jan 10 2012

%o (Sage)

%o def A183063(n): return len([1 for d in divisors(n) if is_even(d)])

%o [A183063(n) for n in (1..80)] # _Peter Luschny_, Feb 01 2012

%o (Magma) [IsOdd(n) select 0 else #[d:d in Divisors(n)|IsEven(d)]:n in [1..100]]; // _Marius A. Burtea_, Dec 16 2019

%o (Python)

%o from sympy import divisor_count

%o def A183063(n): return divisor_count(n>>(m:=(~n&n-1).bit_length()))*m # _Chai Wah Wu_, Jul 16 2022

%Y Cf. A000005, A000265, A001227, A007814, A000593, A183064, A136655, A125911, A320111.

%Y Column 2 of A195050. - _Omar E. Pol_, Oct 19 2011

%Y Cf. A001620, A027750, A083910, A244009.

%Y Cf. A247795.

%K nonn,easy

%O 1,4

%A _Jaroslav Krizek_, Dec 22 2010

%E Formula corrected by _Charles R Greathouse IV_, Jul 29 2011

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 May 13 21:51 EDT 2024. Contains 372523 sequences. (Running on oeis4.)