[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
login
Search: a027434 -id:a027434
     Sort: relevance | references | number | modified | created      Format: long | short | data
n appears 2n times, for n >= 1; also nearest integer to square root of n.
+10
71
0, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10
OFFSET
0,4
COMMENTS
Define the oblong root obrt(x) to be the (larger) solution of y * (y+1) = x; i.e., obrt(x) = sqrt(x+1/4) - 1/2. So obrt(x) is an integer iff x is an oblong number (A002378). Then a(n) = ceiling(obrt(n)). - Franklin T. Adams-Watters, Jun 24 2015
From Wolfdieter Lang, Mar 12 2019: (Start)
The general Pell equation is related to the non-reduced form F(n) = Xvec^T A(n) Xvec = x^2 - D(n)*y^2 with D(n) = A000037(n) (D not a square), Xvec = (x,y)^T (T for transposed) and A(n) = matrix[[1,0], [0,-D(n)]]. The discriminant of F(n) = [1, 0, -D(n)] is 4*D(n).
The first reduced form appears after two applications of an equivalence transformation A' = R^T A R obtained with R = R(t) = matrix([0, -1], [1, t]), namely first with t = 0, leading to the still not reduced form [-D, 0, 1], and then with t = ceiling(f(4*D(n))/2 - 1), where f(4*D(n)) = ceiling(2*sqrt(D(n))). This can be shown to be a(n), which is also D(n) - n, for n >= 1 (see a formula below).
This leads to the reduced form FR(n) = [1, 2*a(n), -(D(n) - a(n)^2)] = [1, 2*a(n), -(n - a(n)*(a(n) - 1))]. Example: n = 5, a(5) = 2: D(5) = 7 and FR(5) = [1, 4, -3]. (End)
REFERENCES
Titu Andreescu, Dorin Andrica, and Zuming Feng, 104 Number Theory Problems, Birkhäuser, 2006, 59-60.
B. C. Berndt, Ramanujan's Notebooks Part IV, Springer-Verlag, see p. 78, Entry 24.
LINKS
Jonathan M. Borwein and others, Nearest Integer Zeta Functions, solution to Problem 10212, The American Mathematical Monthly, Vol. 101, No. 6 (1994), pp. 579-580.
G. Gutin, Problem 913 (BCC20.5), Mediated digraphs, in Research Problems from the 20th British Combinatorial Conference, Discrete Math., 308 (2008), 621-630.
M. A. Nyblom, Some curious sequences involving floor and ceiling functions, Am. Math. Monthly 109 (#6, 2002), 559-564.
Eric Weisstein's World of Mathematics, Ramanujan Theta Functions.
FORMULA
a(n) = A000037(n) - n.
G.f.: x * f(x^2, x^6)/(1-x) where f(,) is Ramanujan's two-variable theta function. - Michael Somos, May 31 2000
a(n) = a(n - 2*a(n - a(n-1))) + 1. - Benoit Cloitre, Oct 27 2002
a(n+1) = a(n) + A005369(n).
a(n) = floor((1/2)*(1 + sqrt(4*n - 3))). - Zak Seidov, Jan 18 2006
a(n) = A000037(n) - n. - Jaroslav Krizek, Jun 14 2009
a(n) = floor(A027434(n)/2). - Gregory R. Bryant, Apr 17 2013
From Mikael Aaltonen, Jan 17 2015: (Start)
a(n) = floor(sqrt(n) + 1/2).
a(n) = sqrt(A053187(n)). (End)
a(0) = 0, and a(n) = k for k from the closed interval [k^2 - k + 1, k*(k+1)] = [A002061(k), A002378(k)], for k >= 1. See A053187. - Wolfdieter Lang, Mar 12 2019
a(n) = floor(2*sqrt(n)) - floor(sqrt(n)). - Ridouane Oudra, Jun 08 2020
Sum_{n>=1} 1/a(n)^s = 2*zeta(s-1), for s > 2 (Borwein, 1994). - Amiram Eldar, Oct 31 2020
EXAMPLE
G.f. = x + x^2 + 2*x^3 + 2*x^4 + 2*x^5 + 2*x^6 + 3*x^7 + 3*x^8 + 3*x^9 + 3*x^10 + ...
MAPLE
Digits := 100; f := n->round(evalf(sqrt(n))); [ seq(f(n), n=0..100) ];
# More efficient:
a := n -> isqrt(n): seq(a(n), n=0..98); # Peter Luschny, Mar 13 2019
MATHEMATICA
A000194[n_] := Floor[(1 + Sqrt[4 n - 3])/2]; (* Enrique Pérez Herrero, Apr 14 2010 *)
Flatten[Table[PadRight[{}, 2 n, n], {n, 10}]] (* Harvey P. Dale, Nov 16 2011 *)
CoefficientList[Series[x QPochhammer[-x^2, x^4] QPochhammer[x^8, x^8]/(1 - x), {x, 0, 50}], x] (* Eric W. Weisstein, Jan 10 2024 *)
PROG
(PARI) {a(n) = ceil( sqrtint(4*n) / 2)}; /* Michael Somos, Feb 11 2004 */
(PARI) a(n)=(sqrtint(4*n) + 1)\2 \\ Charles R Greathouse IV, Jun 08 2020
(PARI) apply( {A000194(n)=sqrtint(4*n)\/2}, [0..99]) \\ M. F. Hasler, Jun 22 2024
(Haskell)
a000194 n = a000194_list !! (n-1)
a000194_list = concat $ zipWith ($) (map replicate [2, 4..]) [1..]
-- Reinhard Zumkeller, Mar 18 2011
(Python)
from math import isqrt
def A000194(n): return (m:=isqrt(n))+int(n-m*(m+1)>=1) # Chai Wah Wu, Jul 30 2022
CROSSREFS
Partial sums of A005369.
Cf. A000196 (floor(sqrt(n))), A003059 (ceiling(sqrt(n))).
KEYWORD
nonn,easy,nice,changed
EXTENSIONS
Additional comments from Michael Somos, May 31 2000
Edited by M. F. Hasler, Mar 01 2014
Initial 0 added by N. J. A. Sloane, Nov 13 2017
STATUS
approved
Minimal perimeter of polyomino with n square cells.
+10
17
0, 4, 6, 8, 8, 10, 10, 12, 12, 12, 14, 14, 14, 16, 16, 16, 16, 18, 18, 18, 18, 20, 20, 20, 20, 20, 22, 22, 22, 22, 22, 24, 24, 24, 24, 24, 24, 26, 26, 26, 26, 26, 26, 28, 28, 28, 28, 28, 28, 28, 30, 30, 30, 30, 30, 30, 30, 32, 32, 32, 32, 32, 32, 32, 32, 34, 34, 34, 34, 34, 34
OFFSET
0,2
REFERENCES
F. Harary and H. Harborth, Extremal Animals, Journal of Combinatorics, Information & System Sciences, Vol. 1, No 1, 1-8 (1976).
W. C. Yang, Optimal polyform domain decomposition (PhD Dissertation), Computer Sciences Department, University of Wisconsin-Madison, 2003.
LINKS
Greg Malen, Érika Roldán, and Rosemberg Toalá-Enríquez, Extremal {p, q}-Animals, Ann. Comb. (2023). See Corollary 1.9 at p. 8.
Henri Picciotto, Geometry Labs, Labs 8.1-8.3.
J. Yackel, R. R. Meyer and I. Christou, Minimum-perimeter domain assignment, Mathematical Programming, vol. 78 (1997), pp. 283-303.
Jason R. Zimba, Solution to Perimeter Problem, Jan 23 2015
FORMULA
a(n) = 2*ceiling(2*sqrt(n)).
a(n) = 2*A027434(n) for n > 0. - Tanya Khovanova, Mar 04 2008
EXAMPLE
a(5) = 10 because we can arrange 5 squares into 2 rows, with 2 squares in the top row and 3 squares in the bottom row. This shape has perimeter 10, which is minimal for 5 squares.
MAPLE
interface(quiet=true); for n from 0 to 100 do printf("%d, ", 2*ceil(2*sqrt(n))) od;
MATHEMATICA
Table[2*Ceiling[2*Sqrt[n]], {n, 0, 100}] (* Wesley Ivan Hurt, Mar 01 2014 *)
PROG
(Haskell)
a027709 0 = 0
a027709 n = a027434 n * 2 -- Reinhard Zumkeller, Mar 23 2013
(Magma) [2*Ceiling(2*Sqrt(n)): n in [0..100]]; // Vincenzo Librandi, May 11 2015
(Python)
from math import isqrt
def A027709(n): return 1+isqrt((n<<2)-1)<<1 if n else 0 # Chai Wah Wu, Jul 28 2022
CROSSREFS
Cf. A000105, A067628 (analog for triangles), A075777 (analog for cubes).
Cf. A135711.
Number of such polyominoes is in A100092.
KEYWORD
easy,nonn
AUTHOR
Jonathan Custance (jevc(AT)atml.co.uk)
EXTENSIONS
Edited by Winston C. Yang (winston(AT)cs.wisc.edu), Feb 02 2002
STATUS
approved
Complement of quarter-squares (A002620).
+10
10
3, 5, 7, 8, 10, 11, 13, 14, 15, 17, 18, 19, 21, 22, 23, 24, 26, 27, 28, 29, 31, 32, 33, 34, 35, 37, 38, 39, 40, 41, 43, 44, 45, 46, 47, 48, 50, 51, 52, 53, 54, 55, 57, 58, 59, 60, 61, 62, 63, 65, 66, 67, 68, 69, 70, 71, 73, 74, 75, 76, 77, 78, 79, 80, 82, 83, 84, 85, 86, 87
OFFSET
1,1
COMMENTS
Intersection of A000037 and A078358. - Reinhard Zumkeller, May 08 2012
Numbers k such that floor(sqrt(k)+1/2) does not divide k. - Wesley Ivan Hurt, Dec 01 2020
LINKS
FORMULA
a(n) = n + A027434(n).
Other identities and observations. For all n >= 1:
A237347(a(n)) = 2. - Reinhard Zumkeller, Mar 18 2014
A240025(a(n)) = 0. - Reinhard Zumkeller, Jul 05 2014
a(n) = A080037(n) - 1. - Peter Kagey, Dec 08 2015
G.f.: x/(1-x)^2 + Sum_{k>=0} (x^(1+k^2)*(1+x^k))/(1-x)
= (x*Theta3(x)+ x^(3/4)*Theta2(x))/(2-2*x) + (3-x)*x/(2*(1-x)^2) where Theta3 and Theta2 are Jacobi Theta functions. - Robert Israel, Dec 09 2015
a(n) = A000037(A000037(n)). - Gerald Hillier, Dec 01 2017
MAPLE
A049068:=n->n + ceil(2*sqrt(n)); seq(A049068(n), n=1..100); # Wesley Ivan Hurt, Mar 01 2014
MATHEMATICA
max = 100; Complement[Range[0, max], Table[Quotient[n^2, 4], {n, 0, 2*Sqrt[max]}]] (* Jean-François Alcover, Apr 18 2013 *)
Table[n + Ceiling[2 * Sqrt[n]], {n, 100}] (* Wesley Ivan Hurt, Mar 01 2014 *)
PROG
(PARI) {a(n) = if( n<1, 0, n+1 + sqrtint(4*n - 3))} /* Michael Somos, Oct 16 2006 */
(Haskell)
a049068 n = a049068_list !! (n-1)
a049068 = filter ((== 0) . a240025) [0..]
-- Reinhard Zumkeller, Jul 05 2014, Mar 18 2014, May 08 2012
(Magma) [n+Ceiling(2*Sqrt(n)): n in [1..70]]; // Vincenzo Librandi, Dec 09 2015
(Python)
from math import isqrt
def A049068(n): return n+1+isqrt((n<<2)-1) # Chai Wah Wu, Jul 27 2022
CROSSREFS
KEYWORD
nonn,nice,easy
AUTHOR
Michael Somos, Aug 06 1999
STATUS
approved
Minimal number of steps for a Racetrack car (using von Neumann neighborhood) to go around a circle of radius n.
+10
10
9, 12, 13, 16, 17, 19, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 32, 32, 34, 34, 36, 36, 37
OFFSET
1,1
COMMENTS
The car moves according to the rules of the game of Racetrack with von Neumann neighborhood, i.e., if P, Q, and R are three successive positions of the car, one coordinate of the second difference (acceleration vector) P - 2Q + R must be 0, and the other 1, 0, or -1. The car starts with zero velocity at a point (x,0) for some integer x >= n, and finishes when it passes, or lands on, the positive x-axis after a complete counterclockwise lap around the origin. The line segments between successive positions must be outside or on the circle with center in (0,0) and radius n.
FORMULA
a(n) = min {k >= 8; A351351(k)/A351352(k) >= n^2}.
a(n) >= A351041(n).
EXAMPLE
The following diagrams show examples of optimal trajectories for n = 1, 2, 3. The origin is marked with an asterisk.
.
a(1) = 9:
. 3 2 . .
4 . . 1 .
5 . * 0 9
. 6 7 8 .
.
a(2) = 12:
. 4 3 2 . .
5 . . . 1 .
6 . * . 0 12
7 . . . 11 .
. 8 9 10 . .
.
a(3) = 13:
. . . 4 . 3 . . . .
. 5 . . . . . 2 . .
6 . . . . . . . 1 .
7 . . . * . . . 0 13
8 . . . . . . . . .
. 9 . . . . . 12 . .
. . . 10 . 11 . . . .
CROSSREFS
KEYWORD
nonn,more
AUTHOR
STATUS
approved
Smallest number of sticks of length 1 needed to construct n squares with sides of length 1.
+10
8
4, 7, 10, 12, 15, 17, 20, 22, 24, 27, 29, 31, 34, 36, 38, 40, 43, 45, 47, 49, 52, 54, 56, 58, 60, 63, 65, 67, 69, 71, 74, 76, 78, 80, 82, 84, 87, 89, 91, 93, 95, 97, 100, 102, 104, 106, 108, 110, 112, 115, 117, 119, 121, 123, 125, 127, 130, 132, 134, 136, 138, 140, 142
OFFSET
1,1
COMMENTS
A182834(a(n)) mod 2 = 0, or, where even terms occur in A182834. - Reinhard Zumkeller, Aug 05 2014
LINKS
Ralph H. Buchholz and Warwick De Launey, The square, the triangle and the hexagon, 1996.
Douglas A. Torrance, Enumeration of planar Tangles, arXiv:1906.01541 [math.CO], 2019.
Douglas A. Torrance, Enumeration of planar Tangles, Proc. Math. Sci. 130 (50 (2020)
FORMULA
a(n) = 2*n + ceiling(2*sqrt(n)) = 2*n + A027434(n).
a(n) = (4*n + A027709(n))/2. - Tanya Khovanova, Mar 07 2008
EXAMPLE
a(2)=7 because we have following construction:
_ _
|_|_|
MATHEMATICA
Table[2n+Ceiling[2Sqrt[n]], {n, 70}] (* Harvey P. Dale, Jun 20 2011 *)
PROG
(Haskell)
a078633 n = 2 * n + ceiling (2 * sqrt (fromIntegral n))
-- Reinhard Zumkeller, Aug 05 2014
(PARI) a(n) = 2*n + ceil(2*sqrt(n)); \\ Michel Marcus, Mar 26 2018
(Python)
from math import isqrt
def A078633(n): return (m:=n<<1)+1+isqrt((m<<1)-1) # Chai Wah Wu, Jul 28 2022
CROSSREFS
KEYWORD
nonn,easy,nice
AUTHOR
Mambetov Timur and Takenov Nurdin (timur_teufel(AT)mail.ru), Dec 12 2002
STATUS
approved
The natural numbers with all terms of A033638 inserted.
+10
8
0, 1, 1, 1, 2, 2, 3, 3, 4, 5, 5, 6, 7, 7, 8, 9, 10, 10, 11, 12, 13, 13, 14, 15, 16, 17, 17, 18, 19, 20, 21, 21, 22, 23, 24, 25, 26, 26, 27, 28, 29, 30, 31, 31, 32, 33, 34, 35, 36, 37, 37, 38, 39, 40, 41, 42, 43, 43, 44, 45, 46, 47, 48, 49, 50, 50, 51, 52, 53, 54, 55, 56, 57, 57
OFFSET
0,5
COMMENTS
Row n of A049597 has a(n+1) nonzero values.
When considering the set of nested parabolas defined by -(x^2) + p*x for integer values of p, a(n) tells us how many parabolas are intersected by the line from (1,n) to (n,n). - Gregory R. Bryant, Apr 01 2013
Number of distinct perimeters for polyominoes with n square cells. - Wesley Prosser, Sep 06 2017
LINKS
FORMULA
a(n) = (n+2) - ceiling(sqrt(4*n)), for n > 0. - Gregory R. Bryant, Apr 01 2013
From Wesley Prosser, Sep 06 2017: (Start)
a(n) = (n+2) - A027709(n)/2.
a(n) = (n+2) - A027434(n).
a(n) = (2n+2) - A049068(n).
a(n) = (2n+3) - A080037(n).
(End)
EXAMPLE
There are three 1's, one from the natural numbers and two from A033638.
When viewed as an array the sequence begins:
0
1
1 1
2 2
3 3 4
5 5 6
7 7 8 9
10 10 11 12
13 13 14 15 16
17 17 18 19 20
21 21 22 23 24 25
26 26 27 28 29 30
...
MATHEMATICA
Table[(n + 2) - Ceiling@ Sqrt[4 n] - 2 Boole[n == 0], {n, 0, 73}] (* Michael De Vlieger, Sep 05 2017 *)
PROG
(Haskell)
a083479 n = a083479_list !! n
a083479_list = m [0..] a033638_list where
m xs'@(x:xs) ys'@(y:ys) | x <= y = x : m xs ys'
| otherwise = y : m xs' ys
-- Reinhard Zumkeller, Apr 06 2012
(Maxima)
a(n):=((n+2)-ceiling(sqrt(4*n))); /* Gregory R. Bryant, Apr 01 2013 */
(Python)
from math import isqrt
def A083479(n): return n+1-isqrt((n<<2)-1) if n else 0 # Chai Wah Wu, Jul 28 2022
(Magma) [n eq 0 select 0 else (n+2)-Ceiling(Sqrt(4*n)): n in [0..100]]; // G. C. Greubel, Feb 17 2024
(SageMath) [(n+2)-ceil(sqrt(4*n)) -2*int(n==0) for n in range(101)] # G. C. Greubel, Feb 17 2024
KEYWORD
easy,nonn,tabf
AUTHOR
Alford Arnold, Jun 08 2003
EXTENSIONS
Edited and extended by David Wasserman, Nov 16 2004
STATUS
approved
Minimal number of steps for a Racetrack car (using Moore neighborhood) to go around a circle of radius n.
+10
8
7, 9, 12, 13, 15, 16, 18, 18, 19, 21, 22, 22, 24, 24, 25, 26, 27, 27, 28, 28, 30, 31, 31, 31, 32, 33, 33, 34, 35, 35, 36, 36, 37, 37, 37
OFFSET
1,1
COMMENTS
The car moves according to the rules of the game of Racetrack, i.e., if P, Q, and R are three successive positions of the car, both coordinates of the second difference (acceleration vector) P - 2Q + R must be 1, 0, or -1. The car starts with zero velocity at a point (x,0) for some integer x >= n, and finishes when it passes, or lands on, the positive x-axis after a complete counterclockwise lap around the origin. The line segments between successive positions must be outside or on the circle with center in (0,0) and radius n.
FORMULA
a(n) = min {k >= 6; A351349(k)/A351350(k) >= n^2}.
a(n) <= A351042(n).
a(n) >= A027434(n) + A027434(2*n) + A002024(n). This can be seen by looking at the y-coordinate only: First, the car must go up to at least y = n and reduce the speed in the y-direction to zero in order to turn downwards; this requires at least A027434(n) steps. Then down to y = -n or below with speed reduced to zero; this requires at least A027434(2*n) steps. Finally, up to at least y = 0 (not necessarily reducing the speed); this requires at least A002024(n) steps.
It appears that a(n) = A027434(n) + A027434(2*n) + A002024(n) + 1 if n is a triangular number (A000217), otherwise a(n) = A027434(n) + A027434(2*n) + A002024(n).
EXAMPLE
The following diagrams show examples of optimal trajectories for n = 1, 2, 3. The origin is marked with an asterisk.
.
a(1) = 7:
. 2 . 1 . .
3 . * . 0 7
. 5 . 6 . .
(The car stands still on the fourth step.)
.
a(2) = 9:
. 3 . 2 . .
4 . . . 1 .
. . * . 0 9
5 . . . 8 .
. 6 . 7 . .
.
a(3) = 12:
. . . 4 3 . . . .
. 5 . . . . 2 . .
. . . . . . . . .
6 . . . . . . 1 .
7 . . . * . . 0 12
. . . . . . . . .
. 8 . . . . . 11 .
. . . 9 . 10 . . .
KEYWORD
nonn,more
AUTHOR
STATUS
approved
a(n) = smallest number of unit squares required to enclose n units of area.
+10
7
4, 8, 10, 12, 12, 14, 14, 16, 16, 16, 18, 18, 18, 20, 20, 20, 20, 22, 22, 22, 22, 24, 24, 24, 24, 24, 26, 26, 26, 26, 26, 28, 28, 28, 28, 28, 28, 30, 30, 30, 30, 30, 30, 32, 32, 32, 32, 32, 32, 32, 34, 34, 34, 34, 34, 34, 34, 36, 36, 36, 36, 36
OFFSET
0,1
COMMENTS
Result attributed to the students Daring, et al., in the links section.
LINKS
Charles R Greathouse IV, Table of n, a(n) for n = 0..10000
E. Daring, I. Guadarrama, S. Sprague, and C. Winterer, WhaleConjecture.
E. Daring, I. Guadarrama, S. Sprague, and C. Winterer, The Whale Theorem. (PDF contains incomplete proof.)
FORMULA
a(n) = 2*ceiling(2*sqrt(n)) + 4.
a(n) = A027709(n) + 4.
a(n) = 2*A027434(n) + 4, n>0.
MATHEMATICA
Table[2 Ceiling[2 Sqrt[n]] + 4, {n, 0, 49}] (* Michael De Vlieger, Jul 21 2016 *)
PROG
(PARI) a(n)=if(n, 2*sqrtint(4*n-1)+6, 4) \\ Charles R Greathouse IV, Jan 09 2014
(Magma) [2*Ceiling(2*Sqrt(n))+4: n in [0..70]]; // Vincenzo Librandi, Jul 27 2016
(Python)
from math import isqrt
def A235382(n): return 3+isqrt((n<<2)-1)<<1 if n else 4 # Chai Wah Wu, Jul 28 2022
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
L. Edson Jeffery, Jan 08 2014
STATUS
approved
Irregular triangle read by rows: row n begins with n and decreases by 2 until 0 or 1 is reached, for n >= 0.
+10
6
0, 1, 2, 0, 3, 1, 4, 2, 0, 5, 3, 1, 6, 4, 2, 0, 7, 5, 3, 1, 8, 6, 4, 2, 0, 9, 7, 5, 3, 1, 10, 8, 6, 4, 2, 0, 11, 9, 7, 5, 3, 1, 12, 10, 8, 6, 4, 2, 0, 13, 11, 9, 7, 5, 3, 1, 14, 12, 10, 8, 6, 4, 2, 0, 15, 13, 11, 9, 7, 5, 3, 1, 16, 14, 12, 10, 8, 6, 4, 2, 0, 17, 15, 13, 11, 9, 7, 5, 3, 1, 18, 16, 14
OFFSET
0,3
COMMENTS
As a sequence, a(n) = A025644(n+1) for n <= 142.
The length of row n is given by A008619(n) = 1 + floor(n/2).
From Wolfdieter Lang, Feb 17 2020: (Start)
This table T(n, m) can be used for the conversion identity
2*cos(Pi*k/N) = 2*sin((Pi/(2*N))*(N - 2*k)) = 2*sin((Pi/(2*N))*T(N-2, k-1)), here for N = n+2 >= 2, and k = m + 1 = 1, 2, ..., floor(N/2).
2*cos((Pi/N)*k) = R(k, rho(N)), where R is a monic Chebyshev polynomial from A127672 and rho(N) = 2*cos(Pi/N), gives part of the roots of the polynomial S(N-1, x), for k = 1, 2, ..., floor(N/2), with the Chebyshev S polynomials from A049310.
2*sin((Pi/(2*N))*q) = d^{(2*N)}_q/r, for q = 1, 2, ..., N, with the length ratio (q-th diagonal)/r, where r is the radius of the circle circumscribing a regular (2*N)-gon. The counting q starts with the diagonal d^{(2*N)}_1 = s(2*N) (in units of r), the side of the (2*N)-gon. The next diagonal is d^{(2*N)}_2 = rho(2*N)*s(2*N) (in units of r).
For the instances N = 4 (n = 2) and 5 (n = 3) see the example section. (End)
If b > 0 and c > 0 are the integer coefficients of a monic quadratic x^2 + b*x + c, it has integer roots if its discriminant d^2 = b^2 - 4c is a perfect square. This sequence is the values of d for increasing b sorted by b then c. The first pair of (b, c) = (2, 1) and has d = a(0) = 0. The n-th pair of (b, c) = (A027434(n), A350634(n)) and has d = a(n-1). - Frank M Jackson, Jan 20 2024
LINKS
FORMULA
T(n, m) = n - 2*m, m = 0, 1, ..., floor(n/2), n >= 0 (see the name and programs). - Wolfdieter Lang, Feb 17 2020
a(n) = A199474(n+1) - A122197(n+1). - Wesley Ivan Hurt, Jan 09 2022
a(n) = sqrt((A027434(n+1))^2 - 4*A350634(n+1)). - Frank M Jackson, Jan 20 2024
EXAMPLE
The irregular triangle T(n, m) begins:
n\m 0 1 2 3 4 5 ...
0: 0
1: 1
2: 2 0
3: 3 1
4: 4 2 0
5: 5 3 1
6: 6 4 2 0
7: 7 5 3 1
8: 8 6 4 2 0
9: 9 7 5 3 1
10: 10 8 6 4 2 0
... reformatted by Wolfdieter Lang, Feb 15 2020
From Wolfdieter Lang, Feb 17 2020: (Start)
Conversion identity:
N = n+2 = 4: k = m+1 = 1, 2*cos(Pi*1/4) = 2*sin(Pi*2/8) = sqrt(2); k=2, 2*cos(Pi*2/4) = 2*sin(Pi*0/8) = 0.
N = 5:(n=3) k=1 (m=0), 2*cos(Pi*1/5) = 2*sin(Pi*3/10) = (1 + sqrt(5))/2 = rho(5) = A001622; k=2: 2*cos(Pi*2/5) = 2*sin(Pi*1/10) = rho(5) - 1. (End)
MATHEMATICA
Flatten[Table[Range[n, 0, -2], {n, 0, 20}]] (* Harvey P. Dale, Apr 03 2019 *)
lst = {}; Do[If[IntegerQ[d=Sqrt[b^2-4c]], AppendTo[lst, d]], {b, 1, 20}, {c, 1, b^2/4}]; lst (* Frank M Jackson, Jan 20 2024 *)
PROG
(PARI) a(n)=local(m); if(n<0, 0, m=sqrtint(1+4*n); m-1-(1+4*n-m^2)\2)
KEYWORD
nonn,tabf
AUTHOR
Michael Somos, Apr 09 2003
STATUS
approved
Smallest number of moves needed to win Integer Lunar Lander with starting position (0,n).
+10
4
0, 2, 3, 4, 4, 5, 5, 6, 6, 6, 7, 7, 7, 8, 8, 8, 8, 9, 9, 9, 9, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 16, 16, 16, 16, 16, 16, 16, 16, 17, 17, 17, 17, 17, 17, 17, 17, 18, 18, 18
OFFSET
0,2
COMMENTS
See A360923 for game rules.
Data provided by Tom Karzes.
It appears that a(n) = 1 + floor(sqrt(4*n-3)) for n>0 (which is essentially A000267 and A027434). - N. J. A. Sloane, Feb 25 2023 [This is proved by Casteigts, Raffinot, and Schoeters (2020) in the form a(n) = ceiling(2*sqrt(n)). - Pontus von Brömssen, Mar 01 2023]
LINKS
Arnaud Casteigts, Mathieu Raffinot, and Jason Schoeters, VectorTSP: A Traveling Salesperson Problem with Racetrack-like acceleration constraints, arXiv:2006.03666 [cs.DS], 2020. See Lemma 7.
EXAMPLE
From (0,6), a 5-move solution is (-1,5), (-2,3), (-2,1), (-1,0), (0,0). There is no shorter solution, so a(6) = 5.
CROSSREFS
Top row of table A360923. Cf. A360925, A360926.
See also A000267 and A027434.
KEYWORD
nonn
AUTHOR
Allan C. Wechsler, Feb 25 2023
STATUS
approved

Search completed in 0.012 seconds