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!)
A174088 Number of pairs (i,j) such that i*j == 0 (mod k), 0 <= i <= j < k. 2

%I #24 Apr 28 2023 08:17:09

%S 1,2,3,5,5,8,7,11,12,14,11,21,13,20,23,26,17,33,19,37,33,32,23,51,35,

%T 38,42,53,29,68,31,58,53,50,59,87,37,56,63,91,41,98,43,85,96,68,47,

%U 122,70,100,83,101,53,123,95,131,93,86,59,181,61,92,138,132,113,158,67,133,113

%N Number of pairs (i,j) such that i*j == 0 (mod k), 0 <= i <= j < k.

%C a(p) = p for p prime, since gcd(k,p) = 1 for 1 <= k < p, the product of k is also coprime to p, but multiples n*p for n >= 1 are plainly divisible by p. - _Michael De Vlieger_, Nov 22 2019

%H Amiram Eldar, <a href="/A174088/b174088.txt">Table of n, a(n) for n = 1..10000</a> (terms 1..1000 from Michael De Vlieger)

%F a(n) = ( A018804(n) + A000188(n) ) / 2. - _Max Alekseyev_, Sep 05 2010

%t Table[If[PrimeQ@ b, b, Count[Flatten@ Array[# Range@ # &, b], _?(Mod[#, b] == 0 &)]], {b, 69}] (* _Michael De Vlieger_, Nov 22 2019 *)

%t f1[p_, e_] := (e*(p - 1)/p + 1)*p^e; f2[p_, e_] := p^Floor[e/2]; a[n_] := (Times @@ f1 @@@ (fct = FactorInteger[n]) + Times @@ f2 @@@ fct)/2; Array[a, 100] (* _Amiram Eldar_, Apr 28 2023 *)

%o (PARI) a(n)={ my(ct=0); for(i=0,n-1,for(j=0,i, ct+=(Mod(i*j,n)==0) ) ); ct; } \\ _Joerg Arndt_, Aug 03 2013

%Y Cf. A000188, A018804.

%K nonn

%O 1,2

%A _Russell Easterly_, Mar 06 2010

%E More terms from _Max Alekseyev_, Sep 05 2010

%E Better name from _Joerg Arndt_, Aug 03 2013

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 03:15 EDT 2024. Contains 371964 sequences. (Running on oeis4.)