%I #37 Jun 13 2021 03:19:48
%S 1,0,1,5,6,1,140,183,36,1,7479,9982,2536,162,1,636944,880738,267664,
%T 28381,672,1,79661322,113973276,39717471,5860934,285078,2718,1,
%U 13781863080,20321795499,7893750308,1475570241,113442968,2712595,10908,1
%N Triangle read by rows: T(n,k) is the number of polygons formed by connecting the vertices of a regular {2*n+1}-gon such that they make k turns around the center point.
%C Polygons that differ by rotation or reflection are counted separately.
%C By "2*n+1-sided polygons" we mean the polygons that can be drawn by connecting 2*n+1 equally spaced points on a circle.
%C T(0,0)=1 by convention.
%C T(n,k) is the number of polygons with 2*n+1 sides whose winding number around the center point is k.
%C Only polygons with an odd number of sides are considered, since even-sided polygons may have diagonals passing through the center point.
%H Andrew Howroyd, <a href="/A330660/b330660.txt">Table of n, a(n) for n = 0..54</a>
%H Ludovic Schwob, <a href="/A330660/a330660.pdf">Illustration of T(3,k), 0 <= k <= 3</a>
%H Dan Sunday, <a href="http://geomalgorithms.com/a03-_inclusion.html">Inclusion of a Point in a Polygon</a>, (2001).
%H Wikipedia, <a href="https://en.wikipedia.org/wiki/Winding_number">Winding number</a>
%F T(n,n)=1 for all n >= 0: The only solution is the polygon with Schläfli symbol {2n*1/n}.
%e Triangle begins:
%e 1;
%e 0, 1;
%e 5, 6, 1;
%e 140, 183, 36, 1;
%e 7479, 9982, 2536, 162, 1;
%o (PARI)
%o T(n)={
%o local(Cache=Map());
%o my(dir(p, q)=if(p<=n, if(q>n&&q<=p+n, 'x, 1), if(q<=n&&q>=p-n, 1/'x, 1)));
%o my(recurse(k, p, b) = my(hk=[k, p, b], z); if(!mapisdefined(Cache, hk, &z),
%o z = if(k==0, 1, sum(q=1, 2*n, if(!bittest(b, q), dir(p, q)*self()(k-1, q, b+(1<<q)) )));
%o mapput(Cache, hk, z)); z);
%o my(p=recurse(2*n, 0, 0));
%o if(n==0, [1], vector(n+1, i, polcoef(p, i-1)/if(i==1, 2, 1)))
%o }
%o { for(n=0, 6, print(T(n))) } \\ _Andrew Howroyd_, May 16 2021
%Y Row sums give A001710(2*n) (number of polygons with 2*n+1 sides).
%Y Cf. A343369.
%K nonn,tabl
%O 0,4
%A _Ludovic Schwob_, Dec 23 2019
%E Terms a(21) and beyond from _Andrew Howroyd_, May 16 2021
|