login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A287814 Number of octonary sequences of length n such that no two consecutive terms have distance 3. 0
1, 8, 54, 366, 2482, 16834, 114178, 774426, 5252642, 35626714, 241642738, 1638972746, 11116542082, 75399367194, 511405842898, 3468675479466, 23526734684322, 159573084361274, 1082324835734258, 7341006503296586, 49791314679463362, 337715954398900954 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
LINKS
FORMULA
For n>3, a(n) = 7*a(n-1) - 10*a(n-3), a(0)=1, a(1)=8, a(2)=54, a(3)=366.
G.f.: (1 + x - 2 x^2 - 2 x^3)/(1 - 7 x + 10 x^3).
EXAMPLE
For n=2 the a(2) = 64 - 10 = 54 sequences contain every combination except these ten: 03,30,14,41,25,52,36,63,47,74.
MATHEMATICA
LinearRecurrence[{7, 0, -10}, {1, 8, 54, 366}, 40]
PROG
(Python)
def a(n):
.if n in [0, 1, 2, 3]:
..return [1, 8, 54, 366][n]
.return 7*a(n-1)-10*a(n-3)
CROSSREFS
Sequence in context: A208310 A154235 A289796 * A201640 A263885 A002775
KEYWORD
nonn,easy
AUTHOR
David Nacin, Jun 02 2017
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 03:15 EDT 2024. Contains 371964 sequences. (Running on oeis4.)