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 A378117 #8 Nov 17 2024 06:31:41 %S A378117 0,1,1,2,1,3,2,3,2,4,2,5,2,5,3,5,4,5,4,5,5,5,6,5,6,5,6,6,6,7,6,7,6,7, %T A378117 7,7,7,8,7,8,7,8,8,8,8,8,9,8,9,8,9,9,9,9,9,10,9,10,9,10,10,10,10,10, %U A378117 10,11,10,11,10,11,11,11,11,11,11,11,12,11,12 %N A378117 Lexicographically earliest sequence of nonnegative integers a(0), a(1), ..., such that a(n) is the number of pairs of adjacent terms whose sum is n. %H A378117 Rémy Sigrist, <a href="/A378117/b378117.txt">Table of n, a(n) for n = 0..10032</a> %H A378117 Rémy Sigrist, <a href="/A378117/a378117.png">Colored scatterplot of the first 65000 terms</a> (where the color denotes the parity of n) %H A378117 Rémy Sigrist, <a href="/A378117/a378117.txt">C++ program</a> %e A378117 We can take a(0) = 0. %e A378117 We cannot take a(1) = 0 as there are no pairs of consecutive terms summing to 0. %e A378117 We can take a(1) = 1. %e A378117 We cannot take a(2) = 0 as we already have one pair of consecutive terms summing to 1. %e A378117 We can take a(2) = 1. %e A378117 We cannot take a(3) = 0 as we already have one pair of consecutive terms summing to 1. %e A378117 We cannot take a(3) = 1 as we already have one pair of consecutive terms summing to 2. %e A378117 We can take a(3) = 2. %o A378117 (C++) // See Links section. %Y A378117 Cf. A001462, A307707. %K A378117 nonn %O A378117 0,4 %A A378117 _Rémy Sigrist_ and _N. J. A. Sloane_, Nov 17 2024