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.

Showing 1-7 of 7 results.

A002415 4-dimensional pyramidal numbers: a(n) = n^2*(n^2-1)/12.

Original entry on oeis.org

0, 0, 1, 6, 20, 50, 105, 196, 336, 540, 825, 1210, 1716, 2366, 3185, 4200, 5440, 6936, 8721, 10830, 13300, 16170, 19481, 23276, 27600, 32500, 38025, 44226, 51156, 58870, 67425, 76880, 87296, 98736, 111265, 124950, 139860, 156066, 173641, 192660, 213200, 235340
Offset: 0

Views

Author

Keywords

Comments

Also number of ways to legally insert two pairs of parentheses into a string of m := n-1 letters. (There are initially 2C(m+4,4) (A034827) ways to insert the parentheses, but we must subtract 2(m+1) for illegal clumps of 4 parentheses, 2m(m+1) for clumps of 3 parentheses, C(m+1,2) for 2 clumps of 2 parentheses and (m-1)C(m+1,2) for 1 clump of 2 parentheses, giving m(m+1)^2(m+2)/12 = n^2*(n^2-1)/12.) See also A000217.
E.g., for n=2 there are 6 ways: ((a))b, ((a)b), ((ab)), (a)(b), (a(b)), a((b)).
Let M_n denote the n X n matrix M_n(i,j)=(i+j); then the characteristic polynomial of M_n is x^(n-2) * (x^2-A002378(n)*x - a(n)). - Benoit Cloitre, Nov 09 2002
Let M_n denote the n X n matrix M_n(i,j)=(i-j); then the characteristic polynomial of M_n is x^n + a(n)x^(n-2). - Michael Somos, Nov 14 2002 [See A114327 for the infinite matrix M in triangular form. - Wolfdieter Lang, Feb 05 2018]
Number of permutations of [n] which avoid the pattern 132 and have exactly 2 descents. - Mike Zabrocki, Aug 26 2004
Number of tilings of a <2,n,2> hexagon.
a(n) is the number of squares of side length at least 1 having vertices at the points of an n X n unit grid of points (the vertices of an n-1 X n-1 chessboard). [For a proof, see Comments in A051602. - N. J. A. Sloane, Sep 29 2021] For example, on the 3 X 3 grid (the vertices of a 2 X 2 chessboard) there are four 1 X 1 squares, one (skew) sqrt(2) X sqrt(2) square, and one 3 X 3 square, so a(3)=6. On the 4 X 4 grid (the vertices of a 3 X 3 chessboard) there are 9 1 X 1 squares, 4 2 X 2 squares, 1 3 X 3 square, 4 sqrt(2) X sqrt(2) squares, and 2 sqrt(5) X sqrt(5) squares, so a(4) = 20. See also A024206, A108279. [Comment revised by N. J. A. Sloane, Feb 11 2015]
Kekulé numbers for certain benzenoids. - Emeric Deutsch, Jun 12 2005
Number of distinct components of the Riemann curvature tensor. - Gene Ward Smith, Apr 24 2006
a(n) is the number of 4 X 4 matrices (symmetrical about each diagonal) M = [a,b,c,d;b,e,f,c;c,f,e,b;d,c,b,a] with a+b+c+d=b+e+f+c=n+2; (a,b,c,d,e,f natural numbers). - Philippe Deléham, Apr 11 2007
If a 2-set Y and an (n-2)-set Z are disjoint subsets of an n-set X then a(n-3) is the number of 5-subsets of X intersecting both Y and Z. - Milan Janjic, Sep 19 2007
a(n) is the number of Dyck (n+1)-paths with exactly n-1 peaks. - David Callan, Sep 20 2007
Starting (1,6,20,50,...) = third partial sums of binomial transform of [1,2,0,0,0,...]. a(n) = Sum_{i=0..n} C(n+3,i+3)*b(i), where b(i)=[1,2,0,0,0,...]. - Borislav St. Borisov (b.st.borisov(AT)abv.bg), Mar 05 2009
4-dimensional square numbers. - Borislav St. Borisov (b.st.borisov(AT)abv.bg), Mar 05 2009
Equals row sums of triangle A177877; a(n), n > 1 = (n-1) terms in (1,2,3,...) dot (...,3,2,1) with additive carryovers. Example: a(4) = 20 = (1,2,3) dot (3,2,1) with carryovers = (1*3) + (2*2 + 3) + (3*1 + 7) = (3 + 7 + 10).
Convolution of the triangular numbers A000217 with the odd numbers A004273.
a(n+2) is the number of 4-tuples (w,x,y,z) with all terms in {0,...,n} and w-x=max{w,x,y,z}-min{w,x,y,z}. - Clark Kimberling, May 28 2012
The second level of finite differences is a(n+2) - 2*a(n+1) + a(n) = (n+1)^2, the squares. - J. M. Bergot, May 29 2012
Because the differences of this sequence give A000330, this is also the number of squares in an n+1 X n+1 grid whose sides are not parallel to the axes.
a(n+2) gives the number of 2*2 arrays that can be populated with 0..n such that rows and columns are nondecreasing. - Jon Perry, Mar 30 2013
For n consecutive numbers 1,2,3,...,n, the sum of all ways of adding the k-tuples of consecutive numbers for n=a(n+1). As an example, let n=4: (1)+(2)+(3)+(4)=10; (1+2)+(2+3)+(3+4)=15; (1+2+3)+(2+3+4)=15; (1+2+3+4)=10 and the sum of these is 50=a(4+1)=a(5). - J. M. Bergot, Apr 19 2013
If P(n,k) = n*(n+1)*(k*n-k+3)/6 is the n-th (k+2)-gonal pyramidal number, then a(n) = P(n,k)*P(n-1,k-1) - P(n-1,k)*P(n,k-1). - Bruno Berselli, Feb 18 2014
For n > 1, a(n) = 1/6 of the area of the trapezoid created by the points (n,n+1), (n+1,n), (1,n^2+n), (n^2+n,1). - J. M. Bergot, May 14 2014
For n > 3, a(n) is twice the area of a triangle with vertices at points (C(n,4),C(n+1,4)), (C(n+1,4),C(n+2,4)), and (C(n+2,4),C(n+3,4)). - J. M. Bergot, Jun 03 2014
a(n) is the dimension of the space of metric curvature tensors (those having the symmetries of the Riemann curvature tensor of a metric) on an n-dimensional real vector space. - Daniel J. F. Fox, Dec 15 2018
Coefficients in the terminating series identity 1 - 6*n/(n + 5) + 20*n*(n - 1)/((n + 5)*(n + 6)) - 50*n*(n - 1)*(n - 2)/((n + 5)*(n + 6)*(n + 7)) + ... = 0 for n = 1,2,3,.... Cf. A000330 and A005585. - Peter Bala, Feb 18 2019

Examples

			a(7) = 6*21 - (6*0 + 4*1 + 2*3 + 0*6 - 2*10 - 4*15) = 196. - _Bruno Berselli_, Jun 22 2013
G.f. = x^2 + 6*x^3 + 20*x^4 + 50*x^5 + 105*x^6 + 196*x^7 + 336*x^8 + ...
		

References

  • O. D. Anderson, Find the next sequence, J. Rec. Math., 8 (No. 4, 1975-1976), 241.
  • A. H. Beiler, Recreations in the Theory of Numbers, Dover, NY, 1964, p. 195.
  • S. J. Cyvin and I. Gutman, Kekulé structures in benzenoid hydrocarbons, Lecture Notes in Chemistry, No. 46, Springer, New York, 1988 (p.165).
  • R. Euler and J. Sadek, "The Number of Squares on a Geoboard", Journal of Recreational Mathematics, 251-5 30(4) 1999-2000 Baywood Pub. NY
  • S. Mukai, An Introduction to Invariants and Moduli, Cambridge, 2003; see p. 238.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

a(n) = ((-1)^n)*A053120(2*n, 4)/8 (one-eighth of fifth unsigned column of Chebyshev T-triangle, zeros omitted). Cf. A001296.
Second row of array A103905.
Third column of Narayana numbers A001263.
Partial sums of A000330.
The expression binomial(m+n-1,n)^2-binomial(m+n,n+1)*binomial(m+n-2,n-1) for the values m = 2 through 14 produces sequences A000012, A000217, A002415, A006542, A006857, A108679, A134288, A134289, A134290, A134291, A140925, A140935, A169937.
Cf. A220212 for a list of sequences produced by the convolution of the natural numbers (A000027) with the k-gonal numbers.

Programs

  • GAP
    List([0..45],n->Binomial(n^2,2)/6); # Muniru A Asiru, Dec 15 2018
  • Magma
    [n^2*(n^2-1)/12: n in [0..50]]; // Wesley Ivan Hurt, May 14 2014
    
  • Maple
    A002415 := proc(n) binomial(n^2,2)/6 ; end proc: # Zerinvary Lajos, Jan 07 2008
  • Mathematica
    Table[(n^4 - n^2)/12, {n, 0, 40}] (* Zerinvary Lajos, Mar 21 2007 *)
    LinearRecurrence[{5,-10,10,-5,1},{0,0,1,6,20},40] (* Harvey P. Dale, Nov 29 2011 *)
  • PARI
    a(n) = n^2 * (n^2 - 1) / 12;
    
  • PARI
    x='x+O('x^200); concat([0, 0], Vec(x^2*(1+x)/(1-x)^5)) \\ Altug Alkan, Mar 23 2016
    

Formula

G.f.: x^2*(1+x)/(1-x)^5. - Simon Plouffe in his 1992 dissertation
a(n) = Sum_{i=0..n} (n-i)*i^2 = a(n-1) + A000330(n-1) = A000217(n)*A000292(n-2)/n = A000217(n)*A000217(n-1)/3 = A006011(n-1)/3, convolution of the natural numbers with the squares. - Henry Bottomley, Oct 19 2000
a(n)+1 = A079034(n). - Mario Catalani (mario.catalani(AT)unito.it), Feb 12 2003
a(n) = 2*C(n+2, 4) - C(n+1, 3). - Paul Barry, Mar 04 2003
a(n) = C(n+2, 4) + C(n+1, 4). - Paul Barry, Mar 13 2003
a(n) = Sum_{k=1..n} A000330(n-1). - Benoit Cloitre, Jun 15 2003
a(n) = n*C(n+1,3)/2 = C(n+1,3)*C(n+1,2)/(n+1). - Mitch Harris, Jul 06 2006
a(n) = A006011(n)/3 = A008911(n)/2 = A047928(n-1)/12 = A083374(n)/6. - Zerinvary Lajos, May 09 2007
a(n) = (1/2)*Sum_{1 <= x_1, x_2 <= n} (det V(x_1,x_2))^2 = (1/2)*Sum_{1 <= i,j <= n} (i-j)^2, where V(x_1,x_2) is the Vandermonde matrix of order 2. - Peter Bala, Sep 21 2007
a(n) = C(n+1,3) + 2*C(n+1,4). - Borislav St. Borisov (b.st.borisov(AT)abv.bg), Mar 05 2009
a(n) = (1/48)*sinh(2*arccosh(n))^2. - Artur Jasinski, Feb 10 2010
a(n) = n*A000292(n-1)/2. - Tom Copeland, Sep 13 2011
a(n) = 5*a(n-1) - 10*a(n-2) + 10*a(n-3) - 5*a(n-4) + a(n-5), n > 4. - Harvey P. Dale, Nov 29 2011
a(n) = (n-1)*A000217(n-1) - Sum_{i=0..n-2} (n-1-2*i)*A000217(i) for n > 1. - Bruno Berselli, Jun 22 2013
a(n) = C(n,2)*C(n+1,3) - C(n,3)*C(n+1,2). - J. M. Bergot, Sep 17 2013
a(n) = Sum_{k=1..n} ( (2k-n)* k(k+1)/2 ). - Wesley Ivan Hurt, Sep 26 2013
a(n) = floor(n^2/3) + 3*Sum_{k=1..n} k^2*floor((n-k+1)/3). - Mircea Merca, Feb 06 2014
Euler transform of length 2 sequence [6, -1]. - Michael Somos, May 28 2014
G.f. x^2*2F1(3,4;2;x). - R. J. Mathar, Aug 09 2015
Sum_{n>=2} 1/a(n) = 21 - 2*Pi^2 = 1.260791197821282762331... . - Vaclav Kotesovec, Apr 27 2016
a(n) = A080852(2,n-2). - R. J. Mathar, Jul 28 2016
a(n) = A046092(n) * A046092(n-1)/48 = A000217(n) * A000217(n-1)/3. - Bruce J. Nicholson, Jun 06 2017
E.g.f.: (1/12)*exp(x)*x^2*(6 + 6*x + x^2). - Stefano Spezia, Dec 07 2018
Sum_{n>=2} (-1)^n/a(n) = Pi^2 - 9 (See A002388). - Amiram Eldar, Jun 28 2020

Extensions

Typo in link fixed by Matthew Vandermast, Nov 22 2010
Redundant comment deleted and more detail on relationship with A000330 added by Joshua Zucker, Jan 01 2013

A024206 Expansion of x^2*(1+x-x^2)/((1-x^2)*(1-x)^2).

Original entry on oeis.org

0, 1, 3, 5, 8, 11, 15, 19, 24, 29, 35, 41, 48, 55, 63, 71, 80, 89, 99, 109, 120, 131, 143, 155, 168, 181, 195, 209, 224, 239, 255, 271, 288, 305, 323, 341, 360, 379, 399, 419, 440, 461, 483, 505, 528, 551, 575, 599, 624, 649, 675, 701, 728, 755, 783, 811, 840
Offset: 1

Views

Author

Keywords

Comments

a(n+1) is the number of 2 X n binary matrices with no zero rows or columns, up to row and column permutation.
[ (4th elementary symmetric function of S(n))/(3rd elementary symmetric function of S(n)) ], where S(n) = {first n+3 odd positive integers}.
First differences are 1, 2, 2, 3, 3, 4, 4, 5, 5, ... .
Let M_n denotes the n X n matrix m(i,j) = 1 if i =j; m(i,j) = 1 if (i+j) is odd; m(i,j) = 0 if i+j is even, then a(n) = -det M_(n+1) - Benoit Cloitre, Jun 19 2002
a(n) is the number of squares with corners on an n X n grid, distinct up to translation. See also A002415, A108279.
Starting (1, 3, 5, 8, 11, ...), = row sums of triangle A135841. - Gary W. Adamson, Dec 01 2007
Number of solutions to x+y >= n-1 in integers x,y with 1 <= x <= y <= n-1. - Franz Vrabec, Feb 22 2008
Let A be the Hessenberg matrix of order n, defined by: A[1,j]=1, A[i,i]:=-1, A[i,i-1]=-1, and A[i,j]=0 otherwise. Then, for n>=5, a(n-4)=-coeff(charpoly(A,x),x^2). - Milan Janjic, Jan 26 2010
Equals row sums of a triangle with alternate columns of (1,2,3,...) and (1,1,1,...). - Gary W. Adamson, May 21 2010
Conjecture: if a(n) = p#(primorial)-1 for some prime number p, then q=(n+1) is also a prime number where p#=floor(q^2/4). Tested up to n=10^100000 no counterexamples are found. It seems that the subsequence is very scattered. So far the triples (p,q,a(q-1)) are {(2,3,1), (3,5,5), (5,11,29), (7,29,209), (17,1429,510509)}. - David Morales Marciel, Oct 02 2015
Numbers of an Ulam spiral starting at 0 in which the shape of the spiral is exactly a rectangle. E.g., a(4)=5 the Ulam spiral is including at that moment only the elements 0,1,2,3,4,5 and the shape is a rectangle. The area is always a(n)+1. E.g., for a(4) the area of the rectangle is 2(rows) X 3(columns) = 6 = a(4) + 1. - David Morales Marciel, Apr 05 2016
Numbers of different quadratic forms (quadrics) in the real projective space P^n(R). - Serkan Sonel, Aug 26 2020
a(n+1) is the number of one-dimensional subspaces of (F_3)^n, counted up to coordinate permutation. E.g.: For n=4, there are five one-dimensional subspaces in (F_3)^3 up to coordinate permutation: [1 2 2] [0 2 2] [1 0 2] [0 0 2] [1 1 1]. This example suggests a bijection (which has to be adjusted for the all-ones matrix) with the binary matrices of the first comment. - Álvar Ibeas, Sep 21 2021

Examples

			There are five 2 X 3 binary matrices with no zero rows or columns up to row and column permutation:
   [1 0 0]  [1 0 0]  [1 1 0]  [1 1 0]  [1 1 1]
   [0 1 1]  [1 1 1]  [0 1 1]  [1 1 1]  [1 1 1].
		

References

  • O. Giering, Vorlesungen über höhere Geometrie, Vieweg, Braunschweig, 1982. See p. 59.

Crossrefs

Cf. A014616, A135841, A034856, A005744 (partial sums), A008619 (1st differences).
A row or column of the array A196416 (possibly with 1 subtracted from it).
Cf. A008619.
Second column of A232206.

Programs

  • GAP
    a:=[0,1,3,5];; for n in [5..65] do a[n]:=2*a[n-1]-2*a[n-3]+a[n-4]; od; a; # Muniru A Asiru, Oct 23 2018
    
  • Haskell
    a024206 n = (n - 1) * (n + 3) `div` 4
    a024206_list = scanl (+) 0 $ tail a008619_list
    -- Reinhard Zumkeller, Dec 18 2013
    
  • Magma
    [(2*n^2+4*n-7-(-1)^n)/8 : n in [1..100]]; // Wesley Ivan Hurt, Jul 22 2014
    
  • Maple
    A024206:=n->(2*n^2+4*n-7-(-1)^n)/8: seq(A024206(n), n=1..100);
  • Mathematica
    f[x_, y_] := Floor[ Abs[ y/x - x/y]]; Table[ Floor[ f[2, n^2 + 2 n - 2] /2], {n, 57}] (* Robert G. Wilson v, Aug 11 2010 *)
    LinearRecurrence[{2,0,-2,1},{0,1,3,5},60] (* Harvey P. Dale, Jun 14 2013 *)
    Rest[CoefficientList[Series[x^2 (1 + x - x^2)/((1 - x^2) (1 - x)^2), {x, 0, 70}], x]] (* Vincenzo Librandi, Oct 02 2015 *)
  • PARI
    a(n)=(n-1)*(n+3)\4 \\ Charles R Greathouse IV, Jun 26 2013
    
  • PARI
    x='x+O('x^99); concat(0, Vec(x^2*(1+x-x^2)/ ((1-x^2)*(1-x)^2))) \\ Altug Alkan, Apr 05 2016
    
  • Python
    def A024206(n): return (n+1)**2//4 - 1 # Ya-Ping Lu, Jan 01 2024

Formula

G.f.: x^2*(1+x-x^2)/((1-x^2)*(1-x)^2) = x^2*(1+x-x^2) / ( (1+x)*(1-x)^3 ).
a(n+1) = A002623(n) - A002623(n-1) - 1.
a(n) = A002620(n+1) - 1 = A014616(n-2) + 1.
a(n+1) = A002620(n) + n, n >= 0. - Philippe Deléham, Feb 27 2004
a(0)=0, a(n) = floor(a(n-1) + sqrt(a(n-1)) + 1) for n > 0. - Gerald McGarvey, Jul 30 2004
a(n) = floor((n+1)^2/4) - 1. - Franz Vrabec, Feb 22 2008
a(n) = A005744(n-1) - A005744(n-2). - R. J. Mathar, Nov 04 2008
a(n) = a(n-1) + [side length of the least square > a(n-1) ], that is a(n) = a(n-1) + ceiling(sqrt(a(n-1) + 1)). - Ctibor O. Zizka, Oct 06 2009
For a(1)=0, a(2)=1, a(n) = 2*a(n-1) - a(n-2) + 1 if n is odd; a(n) = 2*a(n-1) - a(n-2) if n is even. - Vincenzo Librandi, Dec 23 2010
a(n) = A181971(n, n-1) for n > 0. - Reinhard Zumkeller, Jul 09 2012
a(n) = 2*a(n-1) - 2*a(n-3) + a(n-4); a(1)=0, a(2)=1, a(3)=3, a(4)=5. - Harvey P. Dale, Jun 14 2013
a(n) = floor( (n-1)*(n+3)/4 ). - Wesley Ivan Hurt, Jun 23 2013
a(n) = (2*n^2 + 4*n - 7 - (-1)^n)/8. - Wesley Ivan Hurt, Jul 22 2014
a(n) = a(-n-2) = n-1 + floor( (n-1)^2/4 ). - Bruno Berselli, Feb 03 2015
a(n) = (1/4)*(n+3)^2 - (1/8)*(1 + (-1)^n) - 1. - Serkan Sonel, Aug 26 2020
a(n) + a(n+1) = A034856(n). - R. J. Mathar, Mar 13 2021
a(2*n) = n^2 + n - 1, a(2*n+1) = n^2 + 2*n. - Greg Dresden and Zijie He, Jun 28 2022
Sum_{n>=2} 1/a(n) = 7/4 + tan(sqrt(5)*Pi/2)*Pi/sqrt(5). - Amiram Eldar, Dec 10 2022
E.g.f.: (4 + (x^2 + 3*x - 4)*cosh(x) + (x^2 + 3*x - 3)*sinh(x))/4. - Stefano Spezia, Aug 06 2024

Extensions

Corrected and extended by Vladeta Jovovic, Jun 02 2000

A098928 Number of cubes that can be formed from the points of a cubical grid of n X n X n points.

Original entry on oeis.org

0, 1, 9, 36, 100, 229, 473, 910, 1648, 2795, 4469, 6818, 10032, 14315, 19907, 27190, 36502, 48233, 62803, 80736, 102550, 128847, 160271, 197516, 241314, 292737, 352591, 421764, 501204, 592257, 696281, 814450, 948112, 1098607, 1267367
Offset: 1

Views

Author

Ignacio Larrosa Cañestro, Oct 19 2004, Sep 29 2009

Keywords

Comments

Skew cubes are allowed.

Examples

			For n = 3 there are 8 cubes of volume 1 and 1 cube of volume 8; thus a(3)=9. - _José María Grau Ribas_, Mar 15 2014
a(6)=229 because we can place 15^2 cubes in a 6 X 6 X 6 cubical grid with their edges parallel to the faces of the grid, plus 4 cubes of edge 3 with a vertex in each face of the lattice and the other two vertices on a diagonal.
		

Crossrefs

Cf. A103158.
Cf. A000537 (without skew cubes), A002415 (number of squares with corners on an n X n grid), A108279, A102698.

Programs

  • Mathematica
    Needs["Quaternions`"];
    (* Initialize variables *)
    R = 20;
    NN = 1010;
    (* Quaternion operations *)
    test[q_Quaternion] :=
      Module[{unit, res, a, b, c, u, v, w, p},
       If[Round[Norm[q]] > R, Return[]];
       If[q == Quaternion[0, 0, 0, 0], Return[]];
       unit = Quaternion[0, 1, 0, 0];
       res = q ** unit ** Conjugate[q];
       a = Abs[res[[2]]] + Abs[res[[3]]] + Abs[res[[4]]];
       unit = Quaternion[0, 0, 1, 0];
       res = q ** unit ** Conjugate[q];
       b = Abs[res[[2]]] + Abs[res[[3]]] + Abs[res[[4]]];
       unit = Quaternion[0, 0, 0, 1];
       res = q ** unit ** Conjugate[q];
       c = Abs[res[[2]]] + Abs[res[[3]]] + Abs[res[[4]]];
       For[i = 1, i <= (R - 1)/Max[a, b, c], i++,
        If[SquareFreeQ[i], {u = a*i;
          v = b*i;
          w = c*i;
          p = Max[u, v, w] + 1;
          coe[[p + 1, 4]] += (1);
          coe[[p + 1, 3]] -= (u + v + w);
          coe[[p + 1, 2]] += (u*v + v*w + w*u);
          coe[[p + 1, 1]] -= (u*v*w)}]]];
    (* Set up coefficient matrix *)
    coe = ConstantArray[0, {NN, 4}];
    (* Loop through quaternions *)
    rt = Ceiling[Sqrt[R]] + 1;
    For[s = -rt, s <= rt, s++,
      For[x = -rt, x <= rt, x++,
       For[y = -rt, y <= rt, y++,
        For[z = -rt, z <= rt, z++, test[Quaternion[s, x, y, z]];
         test[Quaternion[s + 0.5, x + 0.5, y + 0.5, z + 0.5]];]]]];
    newCoe = coe;
    newCoe[[2 ;; ;; 2]] = coe[[2 ;; ;; 2]]/2;
    (* Calculate and output results *)
    For[i = 2, i <= R + 1, i++, ans = 0;
      For[j = 4, j >= 1, j--, newCoe[[i, j]] += newCoe[[i - 1, j]];
       ans = ans*(i - 1) + newCoe[[i, j]];
       ];
      Print[i - 1, " ", ans/24];];
    (* Haomin Yang, Aug 29 2023 *)

Extensions

Edited by Ray Chandler, Apr 05 2010
Further edited by N. J. A. Sloane, Mar 31 2016

A190309 Number of acute isosceles triangles, distinct up to congruence, on an n X n grid (or geoboard).

Original entry on oeis.org

0, 0, 2, 5, 11, 19, 29, 40, 58, 74, 94, 113, 141, 168, 201, 227, 267, 304, 348, 390, 438, 483, 537, 590, 657, 709, 776, 837, 913, 979, 1057, 1130, 1225, 1299, 1396, 1472, 1576, 1663, 1768, 1863, 1974
Offset: 1

Views

Author

Martin Renner, May 08 2011

Keywords

Crossrefs

Formula

a(n) = A189978(n) - A190310(n) - A108279(n).

A190310 Number of obtuse isosceles triangles, distinct up to congruence, on an n X n grid (or geoboard).

Original entry on oeis.org

0, 0, 0, 1, 3, 5, 9, 12, 19, 24, 32, 37, 51, 57, 69, 80, 99, 107, 127, 136, 161, 176, 196, 207, 246, 262, 286, 306, 343, 357, 399, 414, 460, 485, 517, 544, 605, 623, 659, 689, 757
Offset: 1

Views

Author

Martin Renner, May 08 2011

Keywords

Crossrefs

Formula

a(n) = A189978(n) - A190309(n) - A108279(n).

A328787 Number of distinct sizes of equilateral triangles with vertices in an equilateral triangular array of points with n rows.

Original entry on oeis.org

1, 2, 4, 6, 8, 11, 14, 17, 21, 25, 28, 33, 38, 43, 49, 54, 59, 66, 73, 80, 87, 93, 100, 109, 116, 124, 133, 142, 150, 161, 172, 181, 191, 201, 211, 224, 234, 246, 258, 271, 282, 295, 307, 319, 333, 346, 359, 375, 389, 403, 420, 435, 448, 465, 482, 499, 514
Offset: 2

Views

Author

Peter Kagey, Oct 27 2019

Keywords

Comments

a(n) <= A024610(n-1) - 1.

Examples

			For n = 4, the a(4) = 4 sizes of equilateral triangles are 1, sqrt(3), 2, and 3. For example,
     *         o         *              *
    * *       * o       o o            o o
   o o o     o o *     * o *          o o o
  o o o o,  o * o o,  o o o o,  and  * o o *.
For n = 7, the a(7) = 11 equilateral triangles have side lengths 1, sqrt(3), 2, sqrt(7), 3, sqrt(12), sqrt(13), 4, sqrt(21), 5, and 6.
		

Crossrefs

A108279 is the analog for squares on square grids.

A328801 Least k such that there exists a square of side length sqrt(A001481(n)) with vertices in a k X k square array of points.

Original entry on oeis.org

2, 3, 3, 4, 5, 4, 5, 6, 5, 6, 7, 7, 6, 7, 8, 9, 9, 7, 8, 9, 10, 10, 8, 9, 11, 10, 11, 12, 9, 10, 11, 13, 12, 13, 13, 10, 11, 12, 14, 13, 14, 15, 11, 12, 13, 15, 14, 16, 15, 16, 12, 13, 14, 17, 15, 17, 16, 13, 14, 17, 15, 18, 16, 18, 17, 19, 19, 14, 15, 16, 17
Offset: 2

Views

Author

Peter Kagey, Oct 27 2019

Keywords

Examples

			For n = 8, there is a square with side length sqrt(A001481(8)) = sqrt(10) and vertices in the a(8) X a(8) = 5 X 5 square array of points.
o o o * o
* o o o o
o o o o o
o o o o *
o * o o o
However, there is no square with side length sqrt(10) and vertices in a smaller square array points.
		

Crossrefs

A328793 is the analog for a triangular grid.

Formula

a(n) = A328803(n) + 1.
Showing 1-7 of 7 results.