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!)
A005088 Number of primes = 1 mod 3 dividing n. 11
0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 1, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 1, 0, 1, 0, 1, 0, 0, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 2 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,91
COMMENTS
The first instance of a(n)=2 is for n=91; the first instance of a(n)=3 is for n=1729. 1729 is famously Ramanujan's taxi cab number -- see A001235. - Harvey P. Dale, Jun 25 2013
LINKS
S. R. Finch and Pascal Sebah, Squares and Cubes Modulo n, arXiv:math/0604465 [math.NT], 2006-2016.
FORMULA
Additive with a(p^e) = 1 if p = 1 (mod 3), 0 otherwise.
From Antti Karttunen, Jul 10 2017: (Start)
a(1) = 0; for n > 1, ((A020639(n) mod 3) mod 2) + a(A028234(n)).
a(n) = A001221(n) - A005090(n) - A079978(n).
(End)
MAPLE
A005088 := proc(n)
local a, pe;
a := 0 ;
for pe in ifactors(n)[2] do
if modp(op(1, pe), 3)= 1 then
a := a+1 ;
end if;
end do:
a ;
end proc: # R. J. Mathar, May 19 2020
MATHEMATICA
Join[{0}, Table[Count[Transpose[FactorInteger[n]][[1]], _?(Mod[#-1, 3] == 0&)], {n, 2, 100}]] (* Harvey P. Dale, Sep 22 2021 *)
Array[DivisorSum[#, 1 &, And[PrimeQ@ #, Mod[#, 3] == 1] &] &, 91] (* Michael De Vlieger, Jul 11 2017 *)
PROG
(PARI) a(n)=my(f=factor(n)[, 1]); sum(i=1, #f, f[i]%3==1) \\ Charles R Greathouse IV, Jan 16 2017
(Scheme) (define (A005088 n) (if (= 1 n) 0 (+ (modulo (modulo (A020639 n) 3) 2) (A005088 (A028234 n))))) ;; Antti Karttunen, Jul 10 2017
CROSSREFS
Cf. A121940 (first number having n such factors).
Sequence in context: A110515 A355437 A071936 * A076142 A084904 A084928
KEYWORD
nonn
AUTHOR
STATUS
approved

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 18 06:24 EDT 2024. Contains 371769 sequences. (Running on oeis4.)