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.

A293497 Triangular array read by rows: row n >= 1 is the list of integers from 0 to 2n-1.

This page as a plain text file.
%I A293497 #26 May 03 2019 21:22:25
%S A293497 0,1,0,1,2,3,0,1,2,3,4,5,0,1,2,3,4,5,6,7,0,1,2,3,4,5,6,7,8,9,0,1,2,3,
%T A293497 4,5,6,7,8,9,10,11,0,1,2,3,4,5,6,7,8,9,10,11,12,13,0,1,2,3,4,5,6,7,8,
%U A293497 9,10,11,12,13,14,15,0,1,2,3,4,5,6,7,8
%N A293497 Triangular array read by rows: row n >= 1 is the list of integers from 0 to 2n-1.
%C A293497 a(n) = the least nonnegative n - 2 * T, where T is a triangular number.
%C A293497 a(n) = the least nonnegative n - k * (k + 1), where k is a nonnegative integer.
%C A293497 This sequence shares several properties with A053186 (square excess of n):
%C A293497 - same recursion formula a(n) = f(n,1) with f(n,m) = if n < m then n, otherwise f(n-m,m+2);
%C A293497 - same formula pattern a(n) = n - g(floor(f(n))), with f and g each other's inverse function: f(x)=sqrt(x) and g(x)=x^2 in the case of A053186, f(x)=(sqrt(1+4x)-1)/2 and g(x)=x(x+1) in the case of this sequence;
%C A293497 - similar graphic representation (arithmetically increasing sawtooth shape);
%C A293497 - both sequences appear to intertwine into A288969.
%C A293497 Odd-indexed rows of A002262. - _Omar E. Pol_, Oct 10 2017
%F A293497 a(n) = n - g(floor(f(n))), with f(x) = (sqrt(1+4x)-1)/2 and g(x) = x(x+1).
%F A293497 a(n) = f(n,1) with f(n,m) = if n < m then n, otherwise f(n-m,m+2).
%F A293497 a(n) = t - t^2 + n, where t = floor(sqrt(n+1) + 1/2). - _Ridouane Oudra_, May 03 2019
%e A293497 Triangle begins:
%e A293497 0, 1;
%e A293497 0, 1, 2, 3;
%e A293497 0, 1, 2, 3, 4, 5;
%e A293497 0, 1, 2, 3, 4, 5, 6, 7;
%e A293497 0, 1, 2, 3, 4, 5, 6, 7, 8, 9;
%e A293497 ...
%t A293497 FOdd[x_] := x*(x + 1)
%t A293497 InvFOdd[x_] := (Sqrt[1 + 4 x] - 1)/2
%t A293497 GOdd[n_] := n - FOdd[Floor[InvFOdd[n]]]
%t A293497 Table[GOdd[n], {n, 0, 80}]
%Y A293497 Cf. A002262, A053186, A288969.
%K A293497 nonn,tabf
%O A293497 0,5
%A A293497 _Luc Rousseau_, Oct 10 2017