A277796 Erroneous version of A130131.
1, 1, 1, 1, 2, 3, 6, 11, 23, 47, 105, 231, 537
Offset: 0
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.
For n = 1, there is only one room to search, so a(1) = 1. For n = 2, the prince searches room 1 on the first night. If the princess is not there that means she was in room 2. If the prince searches room 1 again then he is guaranteed to see the princess as she has to move from room 2 to room 1 (she cannot stay in the same room). So a(2) = 2. For n = 3, the prince searches room 2 on the first night. If the princess is not there that means she was either in room 1 or 3. On the second night she must go to room 2 and this is where the prince will find her. So a(3) = 2. For n = 4, a solution that guarantees to find the princess in a(4)=4 nights is to search rooms (2,3,3,2). For n = 5, a solution that guarantees to find the princess in a(5)=6 nights is to search rooms (2,3,4,4,3,2). In the general case for n >= 3, a solution guaranteeing success in the minimum number of nights is to search rooms (2,3,...,n-1,n-1,...,3,2), so a(n) = 2*n - 4.
CoefficientList[ Series[(2x^3 - x^2 + 1)/(x - 1)^2, {x, 0, 62}], x] (* Robert G. Wilson v, Mar 12 2018 *) Join[{1,2},Range[2,200,2]] (* Harvey P. Dale, Jan 25 2019 *)
The a(6) = 1 tree is: o o | | o---o---o---o
seq(n)=my(p=1/(eta(x + O(x^(n-3))))); Vec(((x*(p - 1/(1-x)))^2 + x^2*(subst(p,x,x^2) - 1/(1-x^2)))/(2*(1-x)), -n) \\ Andrew Howroyd, Dec 17 2020
seq(n)={my(p=1/(eta(x + O(x^(n-5))))); Vec(x^3*(p-1)*((p - 1/(1-x))^2/(1-x)^2 + (subst(p,x,x^2) - 1/(1-x^2))/(1-x^2))/2, -n)} \\ Andrew Howroyd, Dec 17 2020
seq(n)={my(A=O(x^(n-5)), p=1/eta(x + A), p2=1/eta(x^2 + A)); Vec(((p - 1/(1-x))^2*(p - 1)^2/(1 - x)^3 + (p2 - 1/(1 - x^2))*(p2 - 1)/((1 - x^2)*(1 - x)))/2, -n)} \\ Andrew Howroyd, Jan 26 2025
Triangle begins: 1; 1; 1; 1; 1, 1; 1, 2; 1, 4, 1; 1, 7, 3; 1, 11, 10, 1; 1, 17, 24, 5; 1, 25, 56, 22, 1; 1, 36, 114, 74, 6; 1, 50, 224, 219, 37, 1; 1, 70, 411, 576, 158, 8; 1, 94, 733, 1394, 591, 58, 1; 1, 127, 1252, 3150, 1896, 304, 9; ...
The graph 1---2---3 is a Tom graph: Tom can follow the sequence 2, 2 to guarantee that he catches Jerry. The graph 1 / \ 2---3 is not a Tom graph: Jerry always has 2 vertices to go to, and whatever vertex Tom picks, Jerry can choose another to evade Tom.
The 4 open quipus with 6 nodes are: ._._._._._. ._._._._. ._._._._. ._._._. | | | | The smallest interesting nonexample, a 3-valent tree where the nodes of degree 3 do not lie on a path, is: . . | | ._._._._. | ._._.
LinearRecurrence[{2,3,-5,-3,-1,3,7,0,-1,-6,-2,4},{1,1,1,1,2,2,4,6,11,18,36,64,127},50] (* Paolo Xausa, Aug 13 2023 *)
Comments