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!)
A080146 Binary encoding of quadratic residue set for each prime. a(n) = A055094(A000040(n)). 3
1, 2, 9, 52, 738, 2829, 53643, 162438, 4023888, 166236537, 921787428, 48034254669, 935251837851, 2558696229078, 68055676507664, 2655011771373417, 210067141980993186, 831463105466530077, 42882922858578320598 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
LINKS
FORMULA
a(A080148(n)) = A080117(A080148(n)).
MAPLE
with(numtheory, ithprime); A080146 := n -> A055094(ithprime(n));
MATHEMATICA
A055094[n_] := With[{rr = Table[Mod[k^2, n], {k, 1, n-1}] // Union}, Boole[MemberQ[rr, #]]& /@ Range[n-1]] // FromDigits[#, 2]&;
a[n_] := A055094[Prime[n]];
Table[a[n], {n, 1, 20}] (* Jean-François Alcover, Sep 20 2022 *)
PROG
(PARI) a(n) = my(p=prime(n)); sum(k=1, p-1, 2^(k-1)*(0<sum(i=1, p-1, i^2%p==p-k))); \\ Michel Marcus, Sep 20 2022; after A055094
CROSSREFS
Sequence in context: A266469 A371226 A367390 * A074602 A192131 A326287
KEYWORD
nonn
AUTHOR
Antti Karttunen, Feb 11 2003
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 23 02:23 EDT 2024. Contains 371906 sequences. (Running on oeis4.)