login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A358510
Positions of zeros in A342991.
3
3, 6, 8, 9, 10, 11, 13, 20, 22, 23, 24, 25, 26, 27, 28, 29, 31, 42, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 57, 72, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 91, 110, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124
OFFSET
1,1
MATHEMATICA
A358510[i_]:=Module[{pos=1}, Flatten[Array[{pos+=2, pos+=4#-1, Range[pos+=2, pos+=4#-1]}&, i]]]; (* i-th iteration adds 2+4*i terms *)
PROG
(PARI)
A358510(i)=my(a=List(), pos=1, r); for(j=1, i, r=j<<2; listput(a, [pos+=2, pos+=r-1]); pos++; listput(a, vector(r, x, x+pos)); pos+=r); concat(Vec(a)); \\ i-th iteration adds 2+4*i terms
(Python)
def A358510(i): # i-th iteration adds 2+4*i terms
a, pos = [], 2
for j in range(1, i + 1):
a.extend([pos := pos + 1, pos := pos + (j<<2) - 1])
a.extend(range(pos := pos + 2, pos := pos + (j<<2)))
return a
print(A358510(10))
CROSSREFS
Cf. A342991, A358511 (complement).
Sequence in context: A188544 A163463 A137386 * A344952 A153307 A265227
KEYWORD
nonn,easy
AUTHOR
Paolo Xausa, Nov 20 2022
STATUS
approved