cp's OEIS Frontend

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.

A274687 Sequence and first differences (A274688) together list every integer except zero exactly once.

This page as a plain text file.
%I A274687 #25 Nov 23 2019 04:08:30
%S A274687 1,-1,2,-3,4,-4,5,-6,6,-7,8,-9,10,-10,11,-12,13,-14,14,-15,16,-16,17,
%T A274687 -18,18,-19,20,-21,22,-22,23,-24,24,-25,26,-26,27,-28,29,-30,30,-31,
%U A274687 32,-33,34,-34,35,-36,37,-38,38,-39,40,-40,41,-42,42,-43,44,-45,46
%N A274687 Sequence and first differences (A274688) together list every integer except zero exactly once.
%C A274687 This is the lexicographically earliest sequence that together with its first differences (A274688) contains every integer except 0 exactly once.
%C A274687 Each term is chosen so that |a(n)| is minimal such that neither a(n) nor (a(n) - a(n-1)) has occurred previously in either this sequence or this sequence's first differences.
%e A274687 a(1) = 1; the next number with the lowest possible absolute value that has not occurred yet is -1. -1 - (1) = -2, which also has not yet occurred, so a(2) = -1. The next available term is 2. 2 - (-1) = 3, which is also available, so a(3) = 2.
%Y A274687 Cf. A005228, A274688.
%K A274687 sign
%O A274687 1,3
%A A274687 _Max Barrentine_, Jul 02 2016