login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A293497 Triangular array read by rows: row n >= 1 is the list of integers from 0 to 2n-1. 1
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, 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, 9, 10, 11, 12, 13, 14, 15, 0, 1, 2, 3, 4, 5, 6, 7, 8 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,5
COMMENTS
a(n) = the least nonnegative n - 2 * T, where T is a triangular number.
a(n) = the least nonnegative n - k * (k + 1), where k is a nonnegative integer.
This sequence shares several properties with A053186 (square excess of n):
- same recursion formula a(n) = f(n,1) with f(n,m) = if n < m then n, otherwise f(n-m,m+2);
- 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;
- similar graphic representation (arithmetically increasing sawtooth shape);
- both sequences appear to intertwine into A288969.
Odd-indexed rows of A002262. - Omar E. Pol, Oct 10 2017
LINKS
FORMULA
a(n) = n - g(floor(f(n))), with f(x) = (sqrt(1+4x)-1)/2 and g(x) = x(x+1).
a(n) = f(n,1) with f(n,m) = if n < m then n, otherwise f(n-m,m+2).
a(n) = t - t^2 + n, where t = floor(sqrt(n+1) + 1/2). - Ridouane Oudra, May 03 2019
EXAMPLE
Triangle begins:
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;
...
MATHEMATICA
FOdd[x_] := x*(x + 1)
InvFOdd[x_] := (Sqrt[1 + 4 x] - 1)/2
GOdd[n_] := n - FOdd[Floor[InvFOdd[n]]]
Table[GOdd[n], {n, 0, 80}]
CROSSREFS
Sequence in context: A242305 A049263 A014588 * A278164 A328480 A279681
KEYWORD
nonn,tabf
AUTHOR
Luc Rousseau, Oct 10 2017
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified August 15 10:59 EDT 2024. Contains 375173 sequences. (Running on oeis4.)