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

A238549 a(n) is one fourth of the total number of free ends of 4 line segments expansion at n iterations (see Comments lines for definition).

Original entry on oeis.org

1, 2, 6, 8, 16, 20, 36, 44, 76, 92, 156, 188, 316, 380, 636, 764, 1276, 1532, 2556, 3068, 5116, 6140, 10236, 12284, 20476, 24572, 40956, 49148, 81916, 98300, 163836, 196604, 327676, 393212, 655356, 786428, 1310716, 1572860, 2621436, 3145724, 5242876, 6291452, 10485756
Offset: 1

Views

Author

Kival Ngaokrajang, May 01 2015

Keywords

Comments

The initial pattern consists of 4 straight line segments which are the radii of a square. The next generations are scaled down by a factor of 1/sqrt(2) and rotated by an angle of Pi/4. Their free ends are the ends of elements that do not contact or cross the other ones. Overlaps among different generations are prohibited. See illustration in the links.
We take the official definition to be that provided by the PARI program. From this the assertions in the Formula section follow (they were formerly stated as conjectures). - N. J. A. Sloane, Feb 24 2019
From Georg Fischer, Feb 20 2019: (Start)
The following pattern can be seen for a(n) in base 2:
n a(n)
== ==================
1 1 = 1_2
2 2 = 10_2
3 6 = 110_2
4 8 = 1000_2
5 16 = 10000_2
6 20 = 10100_2
7 36 = 100100_2
8 44 = 101100_2
9 76 = 1001100_2
10 92 = 1011100_2
11 156 = 10011100_2
12 188 = 10111100_2
13 316 = 100111100_2
14 380 = 101111100_2
15 636 = 1001111100_2
16 764 = 1011111100_2
(End)

Examples

			The first numbers of free ends (4*a(n)) are 4, 8, 24, 32, 64, 80, 144, 176, 304, 368, 624, ...
		

Crossrefs

Programs

  • PARI
    {print1(1,", "); for (n=1,100,s=1; for (i=0,n-1,s=s+(5-3*(-1)^i)*2^(1/4*(2*i-1+(-1)^i))/2); print1(s,", "))}
    
  • Sage
    def a():
        s, n = 2, 1
        yield 1
        while True:
            yield s
            s += (5-3*(-1)^n)*2^((2*n-1+(-1)^n)//4)//2
            n += 1
    A238549 = a(); [next(A238549) for  in range(43)] # _Peter Luschny, Feb 24 2019

Formula

a(n) = 1 + Sum_{i=1..n-1} A143095(i).
G.f.: x*(2*x^2+x+1) / ((x-1)*(2*x^2-1)). - Colin Barker, May 02 2015
From Georg Fischer, Feb 20 2019: (Start)
With p = floor((n + 2) / 2) for n >= 4: if n even then a(n) = 2^p + 4 * (2^(p - 4) - 1); if n odd then a(n) = 2^p + 4 * (2^(p - 3) - 1).
a(n) = a(n - 1) + 2 * a(n - 2) - 2 * a(n - 3).
(End)

A256940 a(n) is the total number of free ends of a certain configuration of line segments after n iterations (see Comments lines for definition).

Original entry on oeis.org

2, 4, 8, 12, 12, 12, 20, 20, 16, 24, 28, 48, 52, 36, 44, 36, 16, 24, 40, 56, 72, 72, 76, 80, 60, 64, 80, 124, 132, 88, 100, 68, 16, 24, 40, 56, 72, 80, 88, 104, 112, 128, 176, 216, 244, 212, 168, 148, 84, 64, 104, 152, 200, 200, 212, 216, 148, 144, 176, 276, 296, 192, 212, 136, 16
Offset: 0

Views

Author

Kival Ngaokrajang, Apr 19 2015

Keywords

Comments

The initial pattern is a straight line segment which has 2 free ends: a(0)=2.
The construction rules for the following generations are:
(i) add 2 line segments (all line segments are of equal length) at each free end of previous generation by arranging them in a "V" shape at angle Pi/2 and symmetrically placed at the free end,
(ii) overlaps among different generations are prohibited (if, for a given free end, any of the two new segments from its "V" touch or cross a segment from an earlier generation, then the entire "V" is not added, and that free end is just declared non-free),
(iii) the {a(n)} free ends are the ends of elements that do not touch or cross the others (if a new segment is touched by another segment only at the endpoint which it shares with its parent, then this doesn't count as an intersection and its other end is considered free).
It seems that a(n) drop to 16 for n = 8, 16, 32, 64,... . See illustration in the links.
The structure of the illustration of initial terms is very similar to the structure of A194270 and A220500. - Omar E. Pol, Apr 19 2015

Crossrefs

Programs

  • Mathematica
    new2[{{s_, t_}, a_}] := Simplify@Table[{{t, AngleVector[t, {1, a + si Pi/4}]}, a + si Pi/4}, {si, {1, -1}}];
    xx[l1_, l2_] := SquaredEuclideanDistance[First@l1, First@l2] <= 4 && With[{int = Simplify@RegionIntersection[Line@l1, Line@l2]}, int =!= EmptyRegion[2] && int =!= Point[{First@l2}] && int =!= Point[{First@l1}]];
    {nonfree, free} = {{}, {{{{1/2, 0}, {1, 0}}, 0}, {{{1/2, 0}, {0, 0}}, Pi}}};
    a = {2};
    next[] := ({oldnonfree, oldfree, nonfree, free} = {nonfree, free, Join[free, nonfree], {}};
      Do[n2 = new2[f]; If[And @@ Table[AllTrue[oldnonfree, ! xx[First@#, First@new] &], {new, n2}], Do[
        tt = GroupBy[free, xx[First@#, First@new] &];
        free = Lookup[tt, False, {}];
        If[KeyExistsQ[tt, True], nonfree = Join[nonfree, tt[True], {new}], AppendTo[free, new]];
      , {new, n2}]], {f, oldfree}];
      AppendTo[a, Length@free];);
    Do[next[], {10}];
    a (* Andrey Zabolotskiy, Mar 09 2025 *)

Extensions

a(1) = 2 prepended and a(3) = 8 corrected by Omar E. Pol, Apr 19 2015
Partially edited by Kival Ngaokrajang, as Omar E. Pol suggestion, Apr 26 2015
Terms a(12), a(13), a(59) corrected by Kival Ngaokrajang, Apr 26 2015
Terms a(27), a(60), a(63) corrected, other terms verified, description clarified by Andrey Zabolotskiy, Mar 09 2025

A256941 a(n) is the number of free ends of a certain configuration of line segments after n iterations (see Comments lines for definition).

Original entry on oeis.org

2, 4, 8, 12, 16, 24, 28, 32, 32, 24, 32, 48, 60, 64, 68, 72, 48, 24, 32, 56, 88, 120, 120, 120, 104, 76, 80, 120, 140, 144, 148, 152, 80, 24, 32, 56, 88, 128, 168, 224, 256, 256, 212, 216, 232, 244, 224, 240, 188, 92, 80, 144, 232, 296, 296, 296, 256, 180, 176, 264, 300, 304, 308, 312, 144, 24
Offset: 0

Views

Author

Kival Ngaokrajang, Apr 19 2015

Keywords

Comments

All line segments are equal length. The initial pattern is a straight line segment. It has 2 free ends, so a(0)=2. The construction rules for generation n >= 1 are:
(i) subject to rule ii, add 2 line segments at each free end by arranging in a "V" shape with angle Pi/3 and connecting symmetrically to the free end (nearly like a 3-handed clock showing 07:00:25);
(ii) a "V" is not added if either of its segments would cross a line segment drawn in an earlier generation;
(iii) when generation n is complete, each new line segment clearly touches 2 line segments where it was initially attached; the other end of the new line segment counts as being free if the segment does not touch or cross any more line segments.
a(n) is the number of free ends created in generation n.
It seems that a(n) drops to 24 for n = 5, 9, 17, 33, 65, ... . See illustrations in the links.
The terms of this sequence should be checked! - Omar E. Pol, Apr 23 2015

Crossrefs

Extensions

First term suggested by Omar E. Pol, Apr 23 2015
Author's comments edited by Peter Munn, May 11 2021

A257082 a(n) is one sixth of the total number of free ends of 6 line segments expansion at n iterations (see Comments lines for definition).

Original entry on oeis.org

1, 2, 8, 12, 28, 52, 108, 216, 448
Offset: 1

Views

Author

Kival Ngaokrajang, May 06 2015

Keywords

Comments

The initial pattern consists of 6 straight line segments which are the radii of a hexagon. The next generations are scaled down by a factor of tan(Pi/6) and rotated by an angle of Pi/6. Their free ends are the ends of elements that do not contact or cross the other ones. Overlaps among different generations are prohibited. See illustration in the links.

Crossrefs

Showing 1-4 of 4 results.