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 A004737 #120 Feb 16 2025 08:32:28 %S A004737 1,1,2,1,1,2,3,2,1,1,2,3,4,3,2,1,1,2,3,4,5,4,3,2,1,1,2,3,4,5,6,5,4,3, %T A004737 2,1,1,2,3,4,5,6,7,6,5,4,3,2,1,1,2,3,4,5,6,7,8,7,6,5,4,3,2,1,1,2,3,4, %U A004737 5,6,7,8,9,8,7,6,5,4,3,2,1,1,2,3,4,5,6,7,8,9,10,9,8,7,6,5,4,3,2,1,1,2,3,4,5 %N A004737 Concatenation of sequences (1,2,...,n-1,n,n-1,...,1) for n >= 1. %C A004737 The following sequences all have the same parity: A004737, A006590, A027052, A071028, A071797, A078358, A078446. - _Jeremy Gardiner_, Mar 16 2003 %C A004737 The ordinal transform of a sequence b_0, b_1, b_2, ... is the sequence a_0, a_1, a_2, ... where a_n is the number of times b_n has occurred in {b_0 ... b_n}. %C A004737 From _Artur Jasinski_, Mar 07 2010: (Start) %C A004737 This sequence is the even subset of A003983 for odd p=2,4,6,8,.... %C A004737 For the odd subset of A003983 see A004739. (End) %C A004737 From _Gary W. Adamson_, Mar 30 2010: (Start) %C A004737 Given the triangle rows: (1; 1,2,1; 1,2,3,2,1; ...) as polcoeff with offset 0: %C A004737 q = (1 + 2x + x^2), r = (1 + 2x + 3x^2 + 2x^3 +x^4), etc.; then %C A004737 (1 + 2x + 3x^2 + ...) = q(x) * q(x^2) * q(x^4) * q(x^8) * ... %C A004737 ..................... = r(x) * r(x^3) * r(x^9) * r(x^27) * ... %C A004737 ..................... = s(x) * s(x^4) * s(x^16)* s(x^64) * ... %C A004737 ... (End) %C A004737 From _L. Edson Jeffery_, Jan 13 2012: (Start) %C A004737 Let U_1(t)=1, U_2(t)=2*t, and U_r(t)=2*t*U_(r-1)(t)-U(r-2)(t), r>2, be Chebyshev polynomials of the second kind. For q>1 an integer, let N=2*q and x_k=cos((2*k-1)*Pi/N), and define the ordered column vectors V_k=[U_k(x_1), U_k(x_2), ..., U_k(x_q)]^T, k=1,...,q, where A^T denotes the transpose of matrix A. Let E_N=[V_1, V_2, ..., V_q] be the q X q matrix formed from the ordered components of the V_k. E_N contains the joint spectra of the Danzer basis (see [Jeffery]) associated with N. Let M_N=(1/q)*[E_N]^T*E_N. For the trivial case q=1, let M_2=[1]. CONJECTURE: E_N and M_N are always integral and symmetric, with M_N having diagonal entries {1,2,...} beginning at entries 1,j (j odd) in the first row and i,1 (i odd) in the first column and with zeros elsewhere. If N is allowed to increase without bound, and assuming the conjecture is true, then triangle A004737 emerges in its entirety from the successive antidiagonals containing those entries [M_N]_(i,j) such that i+j=2*v, for each v in {1,2,...,floor((q+1)/2)}. For example, for N=18 and q=9 (omitting the zeros for clarity), %C A004737 M_18=[ %C A004737 (1 1 1 1 1); %C A004737 ( 2 2 2 2 ); %C A004737 (1 3 3 3 3); %C A004737 ( 2 4 4 4 ); %C A004737 (1 3 5 5 5); %C A004737 ( 2 4 6 6 ); %C A004737 (1 3 5 7 7); %C A004737 ( 2 4 6 8 ); %C A004737 (1 3 5 7 9)], %C A004737 from which the first five rows of the sequence can be read off in succession. (End) %C A004737 T(n,k) = min(n,k). The order of the list T(n,k) is by sides of squares from T(1,n) to T(n,n), then from T(n,n) to T(n,1). - _Boris Putievskiy_, Jan 13 2013 %C A004737 Expanded form of T(2,k) k=0,1,...,2m for ascending m-nomial triangles. - _Bob Selcoe_, Feb 07 2014 %C A004737 Terms in the first nine rows of the triangle can be duplicated by performing (111...)^2 with <= nine ones. By way of example, (11111)^2 = 123454321. - _Gary W. Adamson_, Mar 27 2015 %D A004737 Miklós Laczkovich, Conjecture and Proof, TypoTex, Budapest, 1998. See Chapter 10. %D A004737 F. Smarandache, "Numerical Sequences", University of Craiova, 1975. %H A004737 Reinhard Zumkeller, <a href="/A004737/b004737.txt">Table of n, a(n) for n = 1..10000</a> %H A004737 Jerry Brown et al., <a href="http://dx.doi.org/10.1111/j.1949-8594.1997.tb17373.x">Problem 4619</a>, School Science and Mathematics, USA, Vol. 97 (4), 1997, pp. 221-222. %H A004737 L. E. Jeffery, <a href="/wiki/User:L._Edson_Jeffery/Unit-Primitive_Matrices">Danzer matrices (definitions)</a> %H A004737 Boris Putievskiy, <a href="http://arxiv.org/abs/1212.2732">Transformations [of] Integer Sequences And Pairing Functions</a> arXiv:1212.2732 [math.CO], 2012. %H A004737 F. Smarandache, <a href="http://www.gallup.unm.edu/~smarandache/CP2.pdf">Collected Papers, Vol. II</a>, Tempus Publ. Hse., Bucharest, 1996. %H A004737 F. Smarandache, <a href="http://www.gallup.unm.edu/~smarandache/Sequences-book.pdf">Sequences of Numbers Involved in Unsolved Problems</a>, Hexis, Phoenix, 2006. %H A004737 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/SmarandacheSequences.html">Smarandache Sequences.</a> %F A004737 a(A002061(n)) = n; a(A000290(n)) = a(A002522(n)) = 1. - _Reinhard Zumkeller_, Mar 10 2006 %F A004737 a(n) = if n<3 then 1 else (if a(n-1)=1 then 1 + 0^(a(n-2)-1) else a(n-1) - 0^X + (a(n-1)-a(n-2))*(1 - 0^X)), where X = A003059(n-1)-a(n-1). - _Reinhard Zumkeller_, Mar 10 2006 %F A004737 Let b(n) = floor(sqrt(n-1)). Then a(n) = min(n - b(n)^2, (b(n)+1)^2 - n + 1). - _Franklin T. Adams-Watters_, Jun 09 2006 %F A004737 Ordinal transform of A004741. - _Franklin T. Adams-Watters_, Aug 28 2006 %F A004737 If the sequence is read as a triangular array, beginning [1]; [1,2,1]; [1,2,3,2,1]; ..., then the o.g.f. is (1+qx)/((1-x)(1-qx)(1-q^2x)) = 1 + x(1 + 2q + q^2) + x^2(1 + 2q + 3q^2 + 2q^3 +q^4) + .... The row polynomials for this triangle are (1 + q + ... + q^n)^2 =[n,2]_q + q[n-1,2]_q, where [n,2]_q are Gaussian polynomials (see A008967). - _Peter Bala_, Sep 23 2007 %F A004737 a(n) = floor(sqrt(n-1)) - |n - floor(sqrt(n-1))^2 - floor(sqrt(n-1)) - 1| + 1. - _Boris Putievskiy_, Jan 13 2013 %F A004737 Read as a triangular array, then T(n,k) = n - |n-k-1|; T(n,0) = 1; T(n,n-1) = n. - _Juan Pablo Herrera P._, Oct 17 2016 %e A004737 From _Boris Putievskiy_, Jan 13 2013: (Start) %e A004737 The start of the sequence as a table: %e A004737 1 1 1 1 1 1 ... %e A004737 1 2 2 2 2 2 ... %e A004737 1 2 3 3 3 3 ... %e A004737 1 2 3 4 4 4 ... %e A004737 1 2 3 4 5 5 ... %e A004737 1 2 3 4 5 6 ... %e A004737 ... %e A004737 The start of the sequence as an irregular triangle array read by rows: %e A004737 1; %e A004737 1,2,1; %e A004737 1,2,3,2,1; %e A004737 1,2,3,4,3,2,1; %e A004737 1,2,3,4,5,4,3,2,1; %e A004737 1,2,3,4,5,6,5,4,3,2,1; %e A004737 ... %e A004737 Row number k contains 2*k-1 numbers: 1,2,...,k-1,k,k-1,...,1. (End) %e A004737 The sequence of fractions A196199/A004737 = 0/1, -1/1, 0/2, 1/1, -2/1, -1/2, 0/3, 1/2, 2/1, -3/1, -2/2, -1/3, 0/4, 1/3, 2/2, 3/1, -4/4. -3/2, ... contains every rational number (infinitely often) [Laczkovich]. - _N. J. A. Sloane_, Oct 09 2013 %t A004737 Table[Min[n - #^2, (# + 1)^2 - n + 1] &@ Floor[Sqrt[n - 1]], {n, 105}] (* or *) %t A004737 Table[Floor@ # - Abs[n - Floor[#]^2 - Floor@ # - 1] + 1 &@ Sqrt[n - 1], {n, 105}] (* _Michael De Vlieger_, Oct 21 2016 *) %t A004737 Table[Join[Range[n],Range[n-1,1,-1]],{n,20}]//Flatten (* _Harvey P. Dale_, Dec 27 2019 *) %o A004737 (Haskell) %o A004737 import Data.List (inits) %o A004737 a004737 n = a004737_list !! (n-1) %o A004737 a004737_list = concatMap f $ tail $ inits [1..] %o A004737 where f xs = xs ++ tail (reverse xs) %o A004737 -- _Reinhard Zumkeller_, May 11 2014, Mar 26 2011 %o A004737 (PARI) a(n) = n--;my(m=sqrtint(n));m+1-abs(n-m^2-m) \\ _David A. Corneth_, Oct 18 2016 %Y A004737 Cf. A004738, A008967, A003983, A196199. %Y A004737 Cf. A242357, A000290 (row sums). %K A004737 nonn,frac,easy,tabf %O A004737 1,3 %A A004737 R. Muller %E A004737 More terms from _Patrick De Geest_, Jun 15 1998