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-10 of 16 results. Next

A092098 Number of regions that the line segments in A091908(n) cut the equilateral triangle into.

Original entry on oeis.org

1, 6, 19, 30, 61, 78, 127, 150, 217, 246, 331, 366, 469, 510, 625, 678, 817, 870, 1027, 1080, 1261, 1326, 1519, 1566, 1801, 1878, 2107, 2190, 2437, 2520, 2791, 2886, 3169, 3270, 3559, 3678, 3997, 4110, 4447, 4548, 4921, 5034, 5419, 5550, 5899, 6078, 6487
Offset: 1

Views

Author

Hugo Pfoertner, Feb 19 2004

Keywords

Comments

Number of chambers in an n-sected triangle. That is, n sectors are extended from each vertex to the opposite edge of the triangle. - Eric Gottlieb, Jun 26 2005
How many chambers does the edge n-sected simplex with m vertices have? We have given just the first few terms of the case m = 3. This question is natural in the context of central hyperplane arrangements as it generalizes the braid arrangement. Mike Ackerman, Sul-Young Choi, Peter Coughlin, Japheth Wood and I originally encountered the question in the context of voting theory, where we were exploring ways to tabulate votes when voters' preferences are partially ordered. Unfortunately, it turns out that the chambers of the 3-sected simplex with n vertices are not in correspondence with the set of posets on n letters as the chain with three elements and a fourth incomparable element illustrates. - Eric Gottlieb, Jun 26 2005
"Equilateral" is not needed: the sequence counts regions correctly for any triangle with n-sected sides. Ceva's Theorem is used to deduct vanishing regions from the naive count. The first deduction is at n=15 for n odd and n=20 for n even. - Len Smiley and Brian Wick (mathclub(AT)math.uaa.alaska.edu), Jul 04 2005

Examples

			E.g. the number of chambers in the bisected triangle is six, the number of permutations on 3 letters. The number of chambers in the trisected triangle is equal to 19, the number of posets on 3 elements. - _Eric Gottlieb_, Jun 26 2005
a(2)=6: The 3 line segments cut the equilateral triangle into 6 triangles.
a(3)=19: The 3*2 line segments form 12 triangles, 3 quadrilaterals, 3 pentagons and 1 central non-regular hexagon. See pictures at Pfoertner link.
		

Crossrefs

Cf. A091908 (number of intersections), A091910 (radial locations of intersection points), A006533.

Programs

  • Maple
    regions:=proc(n::nonnegint)
       local j,k,l,a;
       a:=0;
       if (n mod 2<>0) then
          a:=3*n^2-3*n+1
       else
          a:=3*n^2-6*n+6
       fi;
       for l from 1 to floor(n/2)-1 do
          for k from 1 to floor(n/2)-1 do
             for j from 1 to floor(n/2)-1 do
                if((n-k)*l*j=k*(n-l)*(n-j)) then
                   a:=a-6
                fi
             od
          od
       od;
       return a
    end proc;
    seq(regions(i),i=1..100);  # Len Smiley and Brian Wick, Jun 30 2005
  • Mathematica
    regions[n_]:=
    If[Mod[n,2] == 0, 3n^2-6n+6, 3n^2-3n+1]-
       6*Count[
      Flatten@
       Table[
        Abs[(n-k)l*j - k(n-l)(n-j)],
        {j,1,Floor[n/2]-1},
        {k,1,Floor[n/2]-1},
        {l,1,Floor[n/2]-1}],
      0] (* Ethan Beihl, Oct 13 2016 *)
  • PARI
    for(n=1,100,regions=0;if(n%2!=0,regions=3*n^2-3*n+1,regions=3*n^2-6*n+6);for(l=1,floor(n/2)-1,for(k=1,floor(n/2)-1,for(j=1,floor(n/2)-1,if((n-k)*l*j==k*(n-l)*(n-j),regions-=6))));print1(regions,",")) \\ Herman Jamke (hermanjamke(AT)fastmail.fm), Oct 27 2006

Formula

Note that 3 divides a(2k) and a(2k+1)-1. - T. D. Noe, Jun 29 2005

Extensions

More terms from T. D. Noe, Jun 29 2005
Further terms from Brian Wick (mathclub(AT)math.uaa.alaska.edu), Jun 30 2005
More terms from Herman Jamke (hermanjamke(AT)fastmail.fm), Oct 27 2006

A332378 Odd numbers k such that A091908(k) < 3*(k-1)^2.

Original entry on oeis.org

15, 35, 45, 55, 63, 65, 75, 77, 85, 91, 99, 105, 117, 119, 135, 143, 153, 161, 165, 171, 175, 187, 189, 195, 203, 207, 209, 221, 225, 231, 245, 247, 255, 259, 261, 273, 275, 285, 297, 299, 315, 319, 323, 325, 333, 341, 345, 351, 357, 369, 375, 377, 385, 387, 391
Offset: 1

Views

Author

N. J. A. Sloane, Feb 14 2020

Keywords

Comments

These are the odd numbers k such that A331423(k) != 0.
If k is even then always A091908(k) < 3*(k-1)^2.

Crossrefs

Extensions

More terms from Jinyuan Wang, Feb 17 2020

A091910 Number of distinct distances between the intersection points in A091908 measured from the center of the equilateral triangle.

Original entry on oeis.org

1, 3, 4, 10, 11, 21, 20, 36, 36, 55, 56, 78, 79, 103, 103, 136, 135
Offset: 2

Views

Author

Hugo Pfoertner, Feb 19 2004

Keywords

Examples

			a(2)=1: The 3 line segments intersect each other at the triangle center (r=0).
a(3)=3: There are 3 intersection points at r=0.2, 3 at r=0.25 and 6 at r=0.3779645, i.e. 3 different radii. See pictures given at link.
		

Crossrefs

Programs

  • Fortran
    ! Program given at link.

A309360 Numbers n such that the number of interior intersection points A091908(n) of the n-intersected triangle decreases when the subdivision of the triangle is refined from n-1 to n cutting line segments.

Original entry on oeis.org

19, 23, 29, 39, 41, 47, 59, 65, 69, 71, 79, 83, 87, 89, 95, 103, 109, 111, 119, 125, 129, 131, 139, 143, 149, 151, 153, 155, 159, 167, 169, 179, 181, 191, 197, 199, 203, 207, 209, 215, 219, 223, 227, 229, 233, 237, 239, 251, 259, 263, 265, 269
Offset: 1

Views

Author

Hugo Pfoertner, Jul 26 2019

Keywords

Comments

A091908(a(n)) < A091908(a(n)+1).

Examples

			a(1) = 19 because A091908(20)=961 < A091908(19)=972 is the first occurrence of a decrease in A091908.
		

Crossrefs

A309361 Numbers n such that the number of interior intersection points A091908(n) of the n-intersected triangle increases exactly by 1 when the subdivision of the triangle is refined from n-1 to n cutting line segments.

Original entry on oeis.org

1, 3, 5, 7, 9, 11, 13, 17, 21, 25, 27, 31, 33, 37, 43, 49, 51, 53, 55, 57, 61, 67, 73, 81, 93, 97, 101, 107, 113, 115, 121, 123, 127, 133, 137, 141, 145, 147, 157, 163, 173, 177, 183, 185, 193, 201, 205, 211, 213, 217, 235, 241, 243, 249, 253, 257
Offset: 1

Views

Author

Hugo Pfoertner, Jul 26 2019

Keywords

Examples

			a(1) = 1 corresponds to change from the triangle without cutting line segments and correspondingly A091908(1)=0 interior intersection points to the triangle where the sides are divided into 2 equal pieces and the 3 line segments connecting the midpoints of the sides with the opposite vertices cutting each other in one common point, the center of gravity. (A091908(2)=1). Thus A091908(2) - A091908(1) = 1 -> a(1) = 1.
a(2) = 3 because the trisected triangle has one less interior intersection point (A091908(3) = 12) than the 4-sected triangle (A091908(4) = 13) -> a(2) = 3.
		

Crossrefs

Formula

A091908(a(n) + 1) = A091908(a(n)) + 1.

A030662 Number of combinations of n things from 1 to n at a time, with repeats allowed.

Original entry on oeis.org

1, 5, 19, 69, 251, 923, 3431, 12869, 48619, 184755, 705431, 2704155, 10400599, 40116599, 155117519, 601080389, 2333606219, 9075135299, 35345263799, 137846528819, 538257874439, 2104098963719, 8233430727599, 32247603683099, 126410606437751, 495918532948103
Offset: 1

Views

Author

Donald Mintz (djmintz(AT)home.com)

Keywords

Comments

Add terms of an increasingly bigger diamond-shaped part of Pascal's triangle:
.......................... 1
............ 1 .......... 1 1
.. 1 ...... 1 1 ........ 1 2 1
. 1 1 =5 . 1 2 1 =19 .. 1 3 3 1 =69
.. 2 ...... 3 3 ........ 4 6 4
............ 6 ......... 10 10
.......................... 20
- Ralf Stephan, May 17 2004
The prime p divides a((p-1)/2) for p in A002144 (Pythagorean primes). - Alexander Adamchuk, Jul 04 2006
Also, number of square submatrices of a square matrix. - Jono Henshaw (jjono(AT)hotmail.com), Apr 22 2008
Partial sums of A051924. - J. M. Bergot, Jun 22 2013
Number of partitions with Ferrers diagrams that fit in an n X n box (excluding the empty partition of 0). - Michael Somos, Jun 02 2014
Also number of non-descending sequences with length and last number are less or equal to n, and also the number of integer partitions (of any positive integer) with length and largest part are less or equal to n. - Zlatko Damijanic, Dec 06 2024

Examples

			G.f. = x + 5*x^2 + 19*x^3 + 69*x^4 + 251*x^5 + 923*x^6 + 3431*x^7 + ...
		

Crossrefs

Column k=2 of A047909.
Central column of triangle A014473.
Right-hand column 2 of triangle A102541.

Programs

  • Magma
    [(n+1)*Catalan(n)-1: n in [1..40]]; // G. C. Greubel, Apr 07 2024
  • Maple
    seq(sum((binomial(n,m))^2,m=1..n),n=1..23); # Zerinvary Lajos, Jun 19 2008
    f:=n->add( add( binomial(i+j,i), i=0..n),j=0..n); [seq(f(n),n=0..12)]; # N. J. A. Sloane, Jan 31 2009
  • Mathematica
    Table[Sum[Sum[(2n-i-j)!/(n-i)!/(n-j)!,{i,1,n}],{j,1,n}],{n,1,20}] (* Alexander Adamchuk, Jul 04 2006 *)
    a[n_] := 2*(2*n-1)!/(n*(n-1)!^2)-1; Table[a[n], {n, 1, 26}] (* Jean-François Alcover, Oct 11 2012, from first formula *)
  • PARI
    a(n)=binomial(2*n,n)-1 \\ Charles R Greathouse IV, Jun 26 2013
    
  • Python
    from math import comb
    def a(n): return comb(2*n, n) - 1
    print([a(n) for n in range(1, 27)]) # Michael S. Branicky, Jul 11 2023
    
  • Sage
    def a(n) : return binomial(2*n,n) - 1
    [a(n) for n in (1..26)] # Peter Luschny, Apr 21 2012
    

Formula

a(n) = A000984(n) - 1.
a(n) = 2*A001700(n-1) - 1.
a(n) = 2*(2*n-1)!/(n!*(n-1)!)-1.
a(n) = Sum_{k=1..n} binomial(n, k)^2. - Benoit Cloitre, Aug 20 2002
a(n) = Sum_{j=0..n} Sum_{i=j..n+j} binomial(i, j). - Klaus Strassburger (strass(AT)ddfi.uni-duesseldorf.de), Jul 23 2003
a(n) = Sum_{i=0..n-1} Sum_{j=0..n-1} binomial(i+j, i). - N. J. A. Sloane, Jan 31 2009
Also for n>1: a(n)=(2*n)!/(n!)^2-1. - Hugo Pfoertner, Feb 10 2004
a(n) = Sum_{j=1..n} Sum_{i=1..n} (2n-i-j)!/((n-i)!*(n-j)!). - Alexander Adamchuk, Jul 04 2006
a(n) = A115112(n) + 1. - Jono Henshaw (jjono(AT)hotmail.com), Apr 22 2008
G.f.: Q(0)*(1-4*x)/x - 1/x/(1-x), where Q(k)= 1 + 4*(2*k+1)*x/( 1 - 1/(1 + 2*(k+1)/Q(k+1))); (continued fraction). - Sergei N. Gladkovskii, May 11 2013
D-finite with recurrence: n*a(n) +2*(-3*n+2)*a(n-1) +(9*n-14)*a(n-2) +2*(-2*n+5)*a(n-3)=0. - R. J. Mathar, Jun 25 2013
0 = a(n)*(+16*a(n+1) - 70*a(n+2) + 68*a(n+3) - 14*a(n+4)) + a(n+1)*(-2*a(n+1) + 61*a(n+2) - 96*a(n+3) + 23*a(n+4)) + a(n+2)*(-6*a(n+2) + 31*a(n+3) - 10*a(n+4)) + a(n+3)*(-2*a(n+3) + a(n+4)) for all n in Z. - Michael Somos, Jun 02 2014
From Ilya Gutkovskiy, Jan 25 2017: (Start)
O.g.f.: (1 - x - sqrt(1 - 4*x))/((1 - x)*sqrt(1 - 4*x)).
E.g.f.: exp(x)*(exp(x)*BesselI(0,2*x) - 1). (End)
a(n) = 3*n*Sum_{k=1..n} (-1)^(k+1)/(2*n+k)*binomial(2*n+k,n-k). - Vladimir Kruchinin, Jul 29 2025
a(n) = n * binomial(2*n, n) * Sum_{k = 1..n} 1/(k*binomial(n+k, k)). - Peter Bala, Aug 05 2025

A092866 Number of intersections inside an equilateral triangular figure formed by the straight line segments mutually connecting all vertices and all points that divide the sides into n equal parts. If three or more lines meet at an interior point this intersection is counted only once.

Original entry on oeis.org

0, 4, 49, 166, 543, 1237, 2511, 4762, 7777, 12262, 18933, 28504, 39078, 56065, 73879, 95962, 124653, 164761, 203259, 258646, 311233, 377932, 458793, 560755, 648936, 775258, 908893, 1056520, 1215087, 1428193, 1607871, 1866007, 2111488, 2399545, 2694010, 3040201, 3356433, 3811387, 4253074, 4720102, 5180466, 5806687, 6324906, 7035949, 7690900, 8392036, 9180330, 10136287, 10894551, 11930833
Offset: 1

Views

Author

Hugo Pfoertner, Mar 10 2004

Keywords

Comments

A detailed example for n=5 is given at the Pfoertner link.

Examples

			a(2)=4 because there are 3 intersection points between the triangle medians and the line segments connecting the midpoints of the sides plus the intersection of the 3 medians at the centroid.
		

Crossrefs

Cf. A092867 (regions formed by the diagonals), A274585 (points both inside and on the triangle sides), A274586 (edges).
Cf. A006561 (number of intersections of diagonals of regular n-gon), A091908 (intersections between line segments connecting vertices with subdivision points on opposite side).
If the boundary points are in general position, we get A367117, A213827, A367118, A367119. - N. J. A. Sloane, Nov 09 2023

Programs

  • Maple
    Inter:= proc(p1x,p1y,p2x,p2y,q1x,q1y,q2x,q2y)
      local det,x,y;
      det:= p1x*q1y-p1x*q2y-p1y*q1x+p1y*q2x-p2x*q1y+p2x*q2y+p2y*q1x-p2y*q2x;
      if det = 0 then return NULL fi;
      x:= (p1x*p2y*q1x-p1x*p2y*q2x-p1x*q1x*q2y+p1x*q1y*q2x-p1y*p2x*q1x+p1y*p2x*q2x+p2x*q1x*q2y-p2x*q1y*q2x)/det;
      y:= (p1x*p2y*q1y-p1x*p2y*q2y-p1y*p2x*q1y+p1y*p2x*q2y-p1y*q1x*q2y+p1y*q1y*q2x+p2y*q1x*q2y-p2y*q1y*q2x)/det;
      if x >0 and y > 0 and x + y < 1 then [x,y]
      else NULL
      fi
    end proc:
    F:= proc(n) local A,B,C,Pairs,Pts;
         A:= [seq([j/n,0],j=0..n)];
         B:= [seq([0,j/n],j=0..n)];
         C:= [seq([j/n,1-j/n],j=0..n)];
         Pairs:= [seq(seq([A[i],B[j]],i=2..n+1),j=2..n+1),
                  seq(seq([A[i],C[j]],i=1..n),j=1..n),
                  seq(seq([B[i],C[j]],i=1..n),j=2..n+1)];
         Pts:= {seq(seq(Inter(op(Pairs[i][1]),op(Pairs[i][2]),op(Pairs[j][1]),op(Pairs[j][2])),j=1..i-1),i=2..nops(Pairs))};
         nops(Pts);
    end proc:
    map(F, [$1..20]); # Robert Israel, Jun 30 2016
  • Mathematica
    Inter[{p1x_, p1y_}, {p2x_, p2y_}, {q1x_, q1y_}, {q2x_, q2y_}] := Module[ {det, x, y}, det = p1x q1y - p1x q2y - p1y q1x + p1y q2x - p2x q1y + p2x q2y + p2y q1x - p2y q2x; If[det == 0, Return[Nothing]]; x = (p1x p2y q1x - p1x p2y q2x - p1x q1x q2y + p1x q1y q2x - p1y p2x q1x + p1y p2x q2x + p2x q1x q2y - p2x q1y q2x)/det; y = (p1x p2y q1y - p1x p2y q2y - p1y p2x q1y + p1y p2x q2y - p1y q1x q2y + p1y q1y q2x + p2y q1x q2y - p2y q1y q2x)/det; If[x > 0 && y > 0 && x + y < 1, {x, y}, Nothing]];
    F[n_] := F[n] = Module[{A, B, K, Pairs, Pts}, A = Table[{j/n, 0}, {j, 0, n}]; B = Table[{0, j/n}, {j, 0, n}]; K = Table[{j/n, 1 - j/n}, {j, 0, n}]; Pairs = {Table[Table[{A[[i]], B[[j]]}, {i, 2, n+1}], {j, 2, n+1}], Table[Table[{A[[i]], K[[j]]}, {i, 1, n}], {j, 1, n}], Table[Table[ {B[[i]], K[[j]]}, {i, 1, n}], {j, 2, n+1}]} // Flatten[#, 2]&; Pts = Table[Table[Inter[Pairs[[i, 1]], Pairs[[i, 2]], Pairs[[j, 1]], Pairs[[j, 2]]], {j, 1, i-1}], {i, 2, Length[Pairs]}]; Flatten[Pts, 1] // Union // Length];
    Table[Print[n, " ", F[n]]; F[n], {n, 1, 20}] (* Jean-François Alcover, Apr 11 2019, after Robert Israel *)

Formula

a(n) = A274585(n) - 3n.

Extensions

a(1) = 0 prepended by Max Alekseyev, Jun 29 2016
a(4) corrected and a(6)-a(20) added by Cynthia Miaina Rasamimanananivo, Jun 28 2016
a(20) corrected by Robert Israel, Jun 30 2016
a(21)-a(50) from Cynthia Miaina Rasamimanananivo, Jun 30 - Aug 23, 2016
"Equilateral" added to definition by N. J. A. Sloane, May 13 2020

A331782 Total number of vertices in graph formed by the straight line segments connecting the edges of an equilateral triangle with the n-1 points resulting from a subdivision of the sides into n equal pieces, counting coinciding intersection points only once.

Original entry on oeis.org

3, 7, 21, 25, 63, 67, 129, 133, 219, 223, 333, 337, 471, 475, 621, 637, 819, 823, 1029, 1021, 1263, 1267, 1521, 1477, 1803, 1807, 2109, 2113, 2439, 2431, 2793, 2797, 3171, 3175, 3549, 3577, 3999, 4003, 4449, 4417, 4923, 4903, 5421, 5425, 5859, 5947, 6489, 6397, 7059, 7063, 7653, 7657, 8271, 8275, 8889
Offset: 1

Views

Author

N. J. A. Sloane, Feb 13 2020

Keywords

Comments

a(n) <= 3*(n^2-n+1), with equality iff n is odd and not a member of A332378. A331423 gives the difference between a(n) and the upper bound.

Crossrefs

Cf. A091908, A092098 (number of cells), A332376 (number of edges), A332378, A331423.

Formula

a(n) = A091908(n) + 3*n.

A365929 Number of intersections formed within a triangle by placing n points "in general position" on each of the three sides and connecting each point to each of the points on the other two sides using straight lines.

Original entry on oeis.org

0, 0, 15, 108, 396, 1050, 2295, 4410, 7728, 12636, 19575, 29040, 41580, 57798, 78351, 103950, 135360, 173400, 218943, 272916, 336300, 410130, 495495, 593538, 705456, 832500, 975975, 1137240, 1317708, 1518846, 1742175, 1989270, 2261760, 2561328, 2889711, 3248700, 3640140, 4065930, 4528023
Offset: 0

Views

Author

Vijay Srinivas Balaji, Sep 23 2023

Keywords

Comments

There are n points on each of the three sides (not counting the vertices of the triangle). Each point must be connected to every point on the other two sides. A033428(n) = 3*n^2 gives the number of lines.
Comments from N. J. A. Sloane, Oct 29 2023: (Start)
"In general position" means that all interior intersection points are simple. No three-way or higher intersections are permitted.
If the 3*n+3 boundary points are included in the count, there are 3*A366478 points.
For the configurations where the boundary points are equally spaced and every pair of boundary points is joined by a chord, see A091908, A092098, A331782.
(End)

Examples

			a(5) = (3/4) * 5^2 * (3*5^2 - 4*5 + 1) = 1050.
		

References

  • Vijay Srinivas Balaji, Formulating A Conjecture For Intersections Created From Crossing Lines Within Different Polygons, International School of Helsingborg, 2023.

Crossrefs

Cf. A367015 (number of regions), A366932 (number of edges), A366478 (vertices including boundary points), A033428 (number of chords).
See also A091908, A092098, A331782.

Programs

  • Maple
    p__3 := n -> 9/4*n^4 - 3*n^3 + 3/4*n^2; for n from 0 to 55 do p__3(n); end do;
  • Mathematica
    LinearRecurrence[{5,-10,10,-5,1},{0,0,15,108,396},50] (* or *)
    A365929[n_]:=3n^2(n-1)(3n-1)/4;Array[A365929,50,0] (* Paolo Xausa, Nov 07 2023 *)

Formula

a(n) = (3/4)*n^2*(n-1)*(3*n-1). [Proof: For intersection points defined by two points on two opposite sides, the number is 3*C(n,2)^2; for intersection points defined by two points on one side and one point on each of the other two sides, the number is 3*C(n,2)*n^2. - N. J. A. Sloane, Nov 07 2023]
G.f.: 3*x^2*(5 + 11*x + 2*x^2)/(1 - x)^5. - Stefano Spezia, Sep 24 2023

A332376 Total number of edges in graph formed by the straight line segments connecting the edges of an equilateral triangle with the n-1 points resulting from a subdivision of the sides into n equal pieces.

Original entry on oeis.org

3, 12, 39, 54, 123, 144, 255, 282, 435, 468, 663, 702, 939, 984, 1245, 1314, 1635, 1692, 2055, 2100, 2523, 2592, 3039, 3042, 3603, 3684, 4215, 4302, 4875, 4950, 5583, 5682, 6339, 6444, 7107, 7254, 7995, 8112, 8895, 8964, 9843, 9936, 10839, 10974
Offset: 1

Views

Author

N. J. A. Sloane, Feb 13 2020

Keywords

Crossrefs

Cf. A091908, A092098 (number of cells), A331782 (number of vertices).
Equals three times A332377.

Formula

a(n) = A092098(n) + A331782(n) - 1 (Euler's formula).
Showing 1-10 of 16 results. Next