

A193564


In A014675, replace the nth occurrence of 1 with n1 and also replace the nth occurrence of 2 with n1.


2



0, 0, 1, 2, 1, 3, 2, 4, 5, 3, 6, 7, 4, 8, 5, 9, 10, 6, 11, 7, 12, 13, 8, 14, 15, 9, 16, 10, 17, 18, 11, 19, 20, 12, 21, 13, 22, 23, 14, 24, 15, 25, 26, 16, 27, 28, 17, 29, 18, 30, 31, 19, 32, 20, 33, 34, 21, 35, 36, 22, 37, 23, 38, 39, 24, 40, 41, 25, 42
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,4


COMMENTS

An infinite sequence of Langford pairs.


REFERENCES

D. E. Knuth, The Art of Computer Programming, Vol. 4A, Section 7, p. 36.


LINKS

Table of n, a(n) for n=1..69.


MAPLE

A000201 := proc(n) option remember; floor(n*(1+sqrt(5))/2) ; end proc:
A014675 := proc(n) A000201(n+2)A000201(n+1) ; end proc:
A193564aux := proc(n, piv) local oc, j ; oc := 0 ; for j from 0 to n do if A014675(j) = piv then oc := oc+1 ; end if; end do: oc ; end proc:
A193564 := proc(n) local piv, oc ; piv := A014675(n1) ; oc := A193564aux(n1, piv) ; oc1 ; end proc:
seq(A193564(n), n=1..80) ; # R. J. Mathar, Aug 18 2011


CROSSREFS

Cf. A014552, A014675.
Sequence in context: A214370 A227859 A026272 * A022447 A117194 A340647
Adjacent sequences: A193561 A193562 A193563 * A193565 A193566 A193567


KEYWORD

nonn


AUTHOR

N. J. A. Sloane, Aug 04 2011


STATUS

approved



