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!)
A287812 Number of octonary sequences of length n such that no two consecutive terms have distance 1. 0
1, 8, 50, 314, 1972, 12386, 77796, 488636, 3069120, 19277130, 121079578, 760500364, 4776699874, 30002433636, 188445170924, 1183623397912, 7434334035874, 46695023649050, 293291264969380, 1842161313673506, 11570608166423524, 72674945645197500 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
LINKS
FORMULA
For n>4, a(n) = 7*a(n-1) - 3*a(n-2) - 10*a(n-3) + 3*a(n-2), a(0)=1, a(1)=8, a(2)=50, a(3)=314, a(4)=1972.
G.f.: (-1 - x + 3 x^2 + 2 x^3 - x^4)/(-1 + 7 x - 3 x^2 - 10 x^3 + 3 x^4).
EXAMPLE
For n=2 the a(2) = 64 - 14 = 50 sequences contain every combination except these fourteen: 01,10,12,21,23,32,34,43,45,54,56,65,67,76.
MATHEMATICA
LinearRecurrence[{7, -3, -10, 3}, {1, 8, 50, 314, 1972}, 40]
PROG
(Python)
def a(n):
.if n in [0, 1, 2, 3, 4]:
..return [1, 8, 50, 314, 1972][n]
.return 7*a(n-1)-3*a(n-2)-10*a(n-3)+3*a(n-4)
CROSSREFS
Sequence in context: A061801 A240050 A221478 * A180029 A357479 A133129
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 24 08:09 EDT 2024. Contains 371922 sequences. (Running on oeis4.)