This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A330779 #19 Jan 06 2020 09:14:53 %S A330779 1,2,2,3,3,3,4,4,4,5,4,6,5,5,6,5,5,7,6,6,7,6,6,8,7,7,7,8,7,7,8,8,8,10, %T A330779 9,8,8,9,8,10,10,9,11,9,9,11,9,9,10,9,9,12,10,11,11,11,12,10,13,10,10, %U A330779 13,10,10,12,11,11,12,11,11,11,14,11,13,12,13 %N A330779 Lexicographically earliest sequence of positive integers such that for any v > 0, the value v appears up to v times, and the associate function f defined by f(n) = Sum_{k = 1..n} a(k) * i^k for n >= 0 is injective (where i denotes the imaginary unit). %C A330779 The variant of this sequence where each value can only appear up to once, twice or three times corresponds to A000027, A008619 and A008620 respectively. %C A330779 Graphically, the representation of f resembles a windmill; the variant of f where we allow the value v to appear 3*v times resembles a butterfly (see illustrations in Links section). %H A330779 Rémy Sigrist, <a href="/A330779/b330779.txt">Table of n, a(n) for n = 1..10000</a> %H A330779 Rémy Sigrist, <a href="/A330779/a330779_4.png">Illustration of first steps</a> %H A330779 Rémy Sigrist, <a href="/A330779/a330779.png">Colored representation of f(n) for n = 0..1000000 in the complex plane</a> (where the color is function of n) %H A330779 Rémy Sigrist, <a href="/A330779/a330779_1.png">Colored representation of the variant where the value v can appear up to 3*v times</a> %H A330779 Rémy Sigrist, <a href="/A330779/a330779_2.png">Colored representation of the variant where the value v can appear up to A000265(v) times</a> %H A330779 Rémy Sigrist, <a href="/A330779/a330779_3.png">Colored representation of the variant where the value v can appear up to prime(v) times</a> %H A330779 Rémy Sigrist, <a href="/A330779/a330779.gp.txt">PARI program for A330779</a> %e A330779 The first terms, alongside the corresponding values of f(n), are: %e A330779 n a(n) f(n) %e A330779 -- ---- ------ %e A330779 0 N/A 0 %e A330779 1 1 i %e A330779 2 2 -2+i %e A330779 3 2 -2-i %e A330779 4 3 1-i %e A330779 5 3 1+2*i %e A330779 6 3 -2+2*i %e A330779 7 4 -2-2*i %e A330779 8 4 2-2*i %e A330779 9 4 2+2*i %e A330779 10 5 -3+2*i %e A330779 11 4 -3-2*i %e A330779 12 6 3-2*i %e A330779 See also illustration in Links section. %o A330779 (PARI) See Links section. %Y A330779 See A331002 and A331003 for the real and imaginary parts of f, respectively. %Y A330779 See A330780 for another variant. %Y A330779 Cf. A000265. %K A330779 nonn %O A330779 1,2 %A A330779 _Rémy Sigrist_, Dec 31 2019