%I #62 Dec 09 2020 01:46:43
%S 1,2,6,3,12,4,20,5,35,7,56,8,72,9,90,10,110,11,143,13,182,14,210,15,
%T 240,16,272,17,306,18,342,19,399,21,462,22,506,23,552,24,600,25,650,
%U 26,702,27,756,28,812,29,870,30,930,31,992,32,1056,33,1122,34,1224,36
%N a(1)=1, a(2)=2; for n>0, a(2*n+2) = smallest number missing from {a(1), ... ,a(2*n)}, and a(2*n+1) = a(2*n)*a(2*n+2).
%C Let c be the smallest positive constant such that for all permutations {a_n} of the positive integers, lim inf_{n -> infinity} gcd(a_n, a_{n+1})/n <= c. This sequence shows c >= 1/2.
%C The definition implies that if a(n) is prime then n is even. - _N. J. A. Sloane_, May 23 2017
%C a(2n) ~ n+1 ~ n has asymptotic density 1 and a(2n-1) ~ n(n+1) ~ n^2 has asymptotic density zero. - _M. F. Hasler_, May 23 2017
%H Reinhard Zumkeller, <a href="/A064736/b064736.txt">Table of n, a(n) for n = 1..10000</a>
%H Ray Chandler, <a href="/A064736/a064736.txt">Table of n, a(n) for n = 1..200000</a> (large file, 2.8 MB)
%H Ray Chandler, <a href="/A064736/a064736.gz">Table of n, a(n) for n = 1..2000000</a> (large gzipped file)
%H P. Erdős, R. Freud, and N. Hegyvári, <a href="https://users.renyi.hu/~p_erdos/1983-02.pdf">Arithmetical properties of permutations of integers</a>, Acta Mathematica Hungarica 41:1-2 (1983), pp. 169-176.
%H Dana G. Korssjoen, Biyao Li, Stefan Steinerberger, Raghavendra Tripathi, and Ruimin Zhang, <a href="https://arxiv.org/abs/2012.04625">Finding structure in sequences of real numbers via graph theory: a problem list</a>, arXiv:2012.04625, Dec 08, 2020
%H Pierre Mazet, Eric Saias, <a href="https://arxiv.org/abs/1803.10073">Etude du graphe divisoriel 4</a>, arXiv:1803.10073 [math.NT], 2018.
%H <a href="/index/Per#IntegerPermutation">Index entries for sequences that are permutations of the natural numbers</a>
%t A064736 = {a[1]=1, a[2]=2}; a[n_] := a[n] = (an = If[OddQ[n], a[n-1]*a[n+1], First[ Complement[ Range[n], A064736]]]; AppendTo[A064736, an]; an); Table[a[n], {n, 1, 62}] (*_Jean-François Alcover_, Aug 07 2012 *)
%o (Haskell)
%o import Data.List (delete)
%o a064736 n = a064736_list !! (n-1)
%o a064736_list = 1 : 2 : f 1 2 [3..] where
%o f u v (w:ws) = u' : w : f u' w (delete u' ws) where u' = v * w
%o -- _Reinhard Zumkeller_, Mar 23 2012
%Y A064745 gives inverse permutation.
%Y Interleaving of A286290 and A286291. See also A286292, A286293.
%Y Cf. A064764, A210770.
%K nonn,easy,nice
%O 1,2
%A J. C. Lagarias (lagarias(AT)umich.edu), Oct 21 2001
%E More terms from _Vladeta Jovovic_, Oct 21 2001
%E Definition clarified by _N. J. A. Sloane_, May 23 2017