OFFSET
1,3
COMMENTS
The following sequences all have the same parity: A004737, A006590, A027052, A071028, A071797, A078358, A078446.
This is also a triangle read by rows in which row n lists the first 2*n-1 positive integers, n >= 1 (see example). - Omar E. Pol, May 29 2012
a(n) mod 2 = A071028(n). - Boris Putievskiy, Jul 24 2013
The triangle in the example is the triangle used by Kircheri in 1664. See the link "Mundus Subterraneus". - Charles Kusniec, Sep 11 2022
LINKS
Reinhard Zumkeller, Table of n, a(n) for n = 1..1000
Glen Joyce C. Dulatre, Jamilah V. Alarcon, Vhenedict M. Florida, Daisy Ann A. Disu, On Fractal Sequences, DMMMSU-CAS Science Monitor (2016-2017) Vol. 15 No. 2, 109-113.
C. Kimberling, Numeration systems and fractal sequences, Acta Arithmetica 73 (1995) 103-117.
Athanasii Kircheri, Mundus Subterraneus, (1664), pg. 24.
F. Smarandache, Only Problems, Not Solutions!, Phoenix,AZ: Xiquan,1993.
Michael Somos, Sequences used for indexing triangular or square arrays
FORMULA
a(n) = 1 + A053186(n-1).
a(n) = n - 1 - ceiling(sqrt(n))*(ceiling(sqrt(n))-2); n > 0.
a(n) = n - floor(sqrt(n-1))^2, distance between n and the next smaller square. - Marc LeBrun, Jan 14 2004
EXAMPLE
a(1)=1; a(9)=5; a(10)=1;
From Omar E. Pol, May 29 2012: (Start)
Written as a triangle the sequence begins:
1;
1, 2, 3;
1, 2, 3, 4, 5;
1, 2, 3, 4, 5, 6, 7;
1, 2, 3, 4, 5, 6, 7, 8, 9;
1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11;
1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13;
1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15;
Row n has length 2*n - 1 = A005408(n-1). (End)
MAPLE
MATHEMATICA
Array[Range[2# - 1]&, 10] // Flatten (* Jean-François Alcover, Jan 30 2018 *)
PROG
(PARI) a(n)=if(n<1, 0, n-sqrtint(n-1)^2)
(Haskell)
import Data.List (inits)
a071797 n = a071797_list !! (n-1)
a071797_list = f $ tail $ inits [1..] where
f (xs:_:xss) = xs ++ f xss
-- Reinhard Zumkeller, Apr 14 2014
CROSSREFS
KEYWORD
easy,nonn,tabf
AUTHOR
Antonio Esposito, Jun 06 2002
STATUS
approved