login
A188171
The number of divisors d of n of the form d == 5 (mod 8).
10
0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 1, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 1, 0, 1, 1, 0, 1, 0, 0, 2, 0, 0, 0, 0, 1, 0, 1, 1, 0, 1, 0, 0, 1, 0, 1, 1, 0, 1, 0, 2, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 0, 0, 0, 1, 2, 0, 1, 0, 0, 2
OFFSET
1,45
COMMENTS
a(5n) >= 1 as d=5 contributes to the count.
LINKS
Michael D. Hirschhorn, The number of representations of a number by various forms, Discrete Mathematics 298 (2005), 205-211.
R. A. Smith and M. V. Subbarao, The average number of divisors in an arithmetic progression, Canadian Mathematical Bulletin, Vol. 24, No. 1 (1981), pp. 37-41.
FORMULA
A188169(n)+a(n) = A001826(n).
A188169(n)+A188170(n)-a(n)-A188172(n) = A002325(n).
G.f.: Sum_{k>=1} x^(5*k)/(1 - x^(8*k)). - Ilya Gutkovskiy, Sep 11 2019
Sum_{k=1..n} a(k) = n*log(n)/8 + c*n + O(n^(1/3)*log(n)), where c = gamma(5,8) - (1 - gamma)/8 = -0.131189..., gamma(5,8) = -(psi(5/8) + log(8))/8 is a generalized Euler constant, and gamma is Euler's constant (A001620) (Smith and Subbarao, 1981). - Amiram Eldar, Nov 25 2023
EXAMPLE
a(13) = 1 because the divisor d=13 is 8+5 == 5 (mod 8).
MAPLE
sigmamr := proc(n, m, r) local a, d ; a := 0 ; for d in numtheory[divisors](n) do if modp(d, m) = r then a := a+1 ; end if; end do: a; end proc:
A188171 := proc(n) sigmamr(n, 8, 5) ; end proc:
MATHEMATICA
a[n_] := DivisorSum[n, 1 &, Mod[#, 8] == 5 &]; Array[a, 100] (* Amiram Eldar, Nov 25 2023 *)
PROG
(PARI) A188171(n) = sumdiv(n, d, (5==(d%8))); \\ Antti Karttunen, Jul 09 2017
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
R. J. Mathar, Mar 23 2011
STATUS
approved