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!)
A091396 a(n) = Product_{ p | n } (1 + Legendre(2,p) ). 5
1, 1, 0, 1, 0, 0, 2, 1, 0, 0, 0, 0, 0, 2, 0, 1, 2, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 2, 0, 0, 2, 1, 0, 2, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 2, 2, 0, 2, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 2, 0, 1, 0, 0, 0, 2, 0, 0, 2, 0, 2, 0, 0, 0, 0, 0, 2, 0, 0, 2, 0, 0, 0, 0, 0, 0, 2, 0, 0, 2, 0, 2, 0, 0, 2, 2, 0, 0, 0, 0, 2, 0, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,7
LINKS
FORMULA
Multiplicative with a(2^e)=1, a(p^e)=0 if p mod 8=3 or p mod 8=5 and a(p^e)=2 if p mod 8=1 or p mod 8=7. - Vladeta Jovovic, Mar 02 2004
Asymptotic mean: Limit_{m->oo} (1/m) * Sum_{k=1..m} a(k) = 4*sqrt(2) * log(1+sqrt(2))/Pi^2 = 0.505167... . - Amiram Eldar, Oct 17 2022
MAPLE
with(numtheory); L := proc(n, N) local i, t1, t2; t1 := ifactors(n)[2]; t2 := mul((1+legendre(N, t1[i][1])), i=1..nops(t1)); end; [seq(L(n, 2), n=1..120)];
MATHEMATICA
a[n_] := If[n == 1, 1, Product[1 + KroneckerSymbol[2, p], {p, FactorInteger[n][[All, 1]]}]];
a /@ Range[1, 100] (* Jean-François Alcover, Sep 20 2019 *)
PROG
(PARI) a(n)={my(f=factor(n)[, 1]); prod(i=1, #f, 1 + kronecker(2, f[i]))} \\ Andrew Howroyd, Jul 23 2018
CROSSREFS
Sequence in context: A127843 A350750 A154234 * A173677 A219480 A277627
KEYWORD
nonn,mult
AUTHOR
N. J. A. Sloane, Mar 02 2004
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 24 14:32 EDT 2024. Contains 371960 sequences. (Running on oeis4.)