login
A170804
Partial sums of (A006899, prefixed by a 1).
3
1, 2, 4, 7, 11, 19, 28, 44, 71, 103, 167, 248, 376, 619, 875, 1387, 2116, 3140, 5188, 7375, 11471, 18032, 26224, 42608, 62291, 95059, 154108, 219644, 350716, 527863, 790007, 1314295, 1845736, 2894312, 4488635, 6585787, 10780091, 15563060, 23951668, 38300575
OFFSET
1,2
COMMENTS
a(n) is the minimum number of three-in-a-rows passing through any cell in n-dimensional tic-tac-toe = the minimum value in the n-th row of A352419. - Ben Orlin, Mar 22 2022
PROG
(Python)
from sympy import integer_log
def A170804(n): return 1 if n == 1 else ((a:=1<<k+1)<<1)-1+(3**integer_log(a, 3)[0]*3-1>>1) if 6**(k:=integer_log(m:=3**(n-2), 6)[0])<<1<m else ((a:=3**integer_log(1<<n-1, 6)[0])*3-1>>1)+(1<<a.bit_length())-1 # Chai Wah Wu, Feb 05 2025
CROSSREFS
Cf. A006899.
Equals A170803 + 1.
Minimum value in the n-th row of A352419.
Sequence in context: A308996 A326471 A326596 * A024622 A034337 A083024
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Dec 12 2009
STATUS
approved