login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A354034 a(n) = 1 if n is an even number or a square, otherwise 0. 1
1, 1, 1, 0, 1, 0, 1, 0, 1, 1, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 1, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 1, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 1, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 1
(list; graph; refs; listen; history; text; internal format)
OFFSET
0
LINKS
FORMULA
a(n) = A059841(n) + A098108(n).
For n >= 1, a(n) = 1 - A324908(n).
MATHEMATICA
a[n_] := If[EvenQ[n] || IntegerQ[Sqrt[n]], 1, 0]; Array[a, 100, 0] (* Amiram Eldar, May 16 2022 *)
PROG
(PARI) A354034(n) = (!(n%2) || issquare(n));
CROSSREFS
Characteristic function of A176693.
Cf. A059841, A098108, A324908 (binary complement).
Sequence in context: A359779 A373834 A132194 * A174897 A316441 A190938
KEYWORD
nonn
AUTHOR
Antti Karttunen, May 16 2022
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | 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 September 19 11:33 EDT 2024. Contains 376010 sequences. (Running on oeis4.)