login
A396614
a(n) is the number of 4-ary sequences of length n with characteristic value 2.
3
1, 4, 12, 36, 96, 248, 608, 1504, 3648, 8608, 19392, 43712, 98304, 222208, 498560, 1118784, 2511872, 5607296, 12138496, 25944960, 55059456
OFFSET
1,2
COMMENTS
A 4-ary sequence is a sequence in which every term is 0, 1, 2 or 3.
Define the difference sequence of a 4-ary sequence (x(1), ..., x(n)) as (|x(1) - x(2)|, |x(2) - x(3)|, ..., |x(n-1) - x(n)|). The difference operation is similar to the Ducci game, except that there is no |x(n) - x(1)| term.
For a 4-ary sequence S of length n, take its difference sequence n-1 times, and the remaining number is the characteristic value of S.
FORMULA
a(n) = 2*4^(n-1) - A396251(n).
a(n) <= n^2 * 2^n.
EXAMPLE
For n = 2, the a(2) = 4 sequences are (0, 2), (1, 3), (2, 0) and (3, 1).
CROSSREFS
Sequence in context: A320967 A261584 A347990 * A396638 A002842 A051041
KEYWORD
nonn,more,new
AUTHOR
Yifan Xie, May 31 2026
EXTENSIONS
a(21) from Sean A. Irvine, Jun 15 2026
STATUS
approved