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-2 of 2 results.

A216172 Number of all possible tetrahedra of any size, having reverse orientation to the original regular tetrahedron, formed when intersecting the latter by planes parallel to its sides and dividing its edges into n equal parts.

Original entry on oeis.org

0, 0, 1, 4, 10, 21, 39, 66, 105, 159, 231, 325, 445, 595, 780, 1005, 1275, 1596, 1974, 2415, 2926, 3514, 4186, 4950, 5814, 6786, 7875, 9090, 10440, 11935, 13585, 15400, 17391, 19569, 21945, 24531, 27339, 30381, 33670, 37219, 41041, 45150, 49560, 54285, 59340
Offset: 1

Views

Author

V.J. Pohjola, Sep 03 2012

Keywords

Comments

The number of all possible tetrahedra of any size, having the same orientation as the original regular tetrahedron is given by A000332(n+3).
Create a sequence wherein the sum of three consecutive numbers is a triangular number: 0,0,0,1,2,3,5,7...; then find the partial sums of this sequence: 0,0,0,1,3,6,11,18...; then take the partial sums of this sequence: 0,0,0,1,4,10,21,39,66... and after dropping the first two zeros, you get this sequence. - J. M. Bergot, Apr 14 2016

Examples

			For n=9 the numbers of the reversely oriented tetrahedra, starting from the smallest size, are A000292(7)=84, A000292(4)=20, and A000292(1)=1, the sum being a(9)=105.
		

Crossrefs

Programs

  • Magma
    I:=[0, 0, 1, 4, 10, 21, 39]; [n le 7 select I[n] else 4*Self(n-1)-6*Self(n-2)+5*Self(n-3)-5*Self(n-4)+6*Self(n-5)-4*Self(n-6)+Self(n-7): n in [1..50]]; // Vincenzo Librandi, Sep 12 2012
    
  • Mathematica
    nnn = 100; Tev[n_] := (n - 2) (n - 1) n/6; Table[Sum[Tev[n - nn], {nn, 0, n - 1, 3}], {n, nnn}]
    Table[(1/72) (-6 n - 5 n^2 + 2 n^3 + n^4 + 4 - 4 (-1)^Mod[n, 3]), {n, 50}]
    CoefficientList[Series[x^2 / ((1 - x)^5*(1 + x + x^2)), {x, 0, 50}], x] (* Vincenzo Librandi, Sep 12 2012 *)
    LinearRecurrence[{4,-6,5,-5,6,-4,1},{0,0,1,4,10,21,39},50] (* Harvey P. Dale, Feb 18 2018 *)
  • PARI
    a(n)=(n^4+2*n^3-5*n^2-6*n+4-4*(-1)^(n%3))/72 \\ Charles R Greathouse IV, Sep 12 2012

Formula

a(n) = (1/72)*(-6*n -5*n^2 +2*n^3 +n^4 +4 -4*(-1)^(n mod 3)).
G.f.: x^3/((1-x)^5*(1+x+x^2)). - Bruno Berselli, Sep 11 2012
a(3*n-1) = A000217(A115067(n)); a(3*n) = A000217(A095794(n)); a(3*n+1) = A000217(A143208(n+2)) + A000217(n). - J. M. Bergot, Apr 14 2016
E.g.f.: (1/216)*(8 - 24*x + 24*x^2 + 24*x^3 + 3*x^4)*exp(x) - (1/27)*(cos(sqrt(3)*x/2) - sqrt(3)*sin(sqrt(3)*x/2))*exp(-x/2). - Ilya Gutkovskiy, Apr 14 2016

A376022 a(1) = 1, for n >= 2, a(n) = -1 + floor((n*a(n - 1)) / (n + a(n - 1))).

Original entry on oeis.org

1, -1, -3, -13, 7, 2, 0, -1, -3, -6, -15, 59, 9, 4, 2, 0, -1, -3, -5, -8, -14, -40, 53, 15, 8, 5, 3, 1, -1, -3, -5, -7, -10, -16, -31, -225, 43, 19, 11, 7, 4, 2, 0, -1, -3, -5, -7, -10, -14, -21, -37, -130, 88, 32, 19, 13, 9, 6, 4, 2, 0, -1, -3, -5, -7, -9, -12, -16, -22
Offset: 1

Views

Author

Ctibor O. Zizka, Sep 06 2024

Keywords

Comments

For x =< -2 and for some k, a(3*k*(k - 1)/2 + x) = -(2*x + 4).

Examples

			a(1) = 1.
a(2) = -1 + floor(2*a(1) / (2 + a(1))) = -1 + floor(2/3) = -1.
a(3) = -1 + floor(-3/2) = -3.
a(4) = -1 + floor(-12/1) = -13.
a(5) = -1 + floor(-65/-8) = 7.
and so on.
		

Crossrefs

Programs

  • Mathematica
    a[1] = 1; a[n_] := a[n] = -1 + Floor[n*a[n-1]/(n + a[n-1])]; Array[a, 100] (* Amiram Eldar, Sep 06 2024 *)
  • PARI
    lista(nn)= my(a=-2); vector(nn, n, a=-1+floor(n*a/(n+a))); \\ Ruud H.G. van Tol, Nov 28 2024
  • Python
    from itertools import count, islice
    def a_gen():
        a = 1
        for n in count(2):
            yield a
            b = -1+(n*a)//(n+a)
            a = b
    A376022_list = list(islice(a_gen(), 100)) # John Tyler Rascoe, Sep 17 2024
    

Formula

For x >= 0, k >= 2*x + 3 - floor((sqrt(9 + 8*x) - 1) / 2), a(3*k*(k-1)/2 + x) = -(2*x + 3).
For k >= 2, a(3*k*(k - 1)/2 - 1) = -1.
Showing 1-2 of 2 results.