This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A120766 #3 Mar 30 2012 17:26:55 %S A120766 1,1,2,6,12,36,86,270,746,2554,8032,29716,103482,409242,1550850, %T A120766 6508702,26509428,117368404,508962350,2365560998,10842378698, %U A120766 52685516658,253754085960,1284660919140,6471281910962,34031293950258 %N A120766 Number of ways to seat n people around a circular table such that person i is next to person i-1 or i+1 or both. %F A120766 For n>=3, a(n)=2+2*Sum_{k=2..[n/2]} (C(n-k,k) + C(n-k-1,k-1))*A061714(k) %o A120766 (PARI) { a(n) = if(n<3, 1, 2 + 2*sum(k=2,n\2, (binomial(n-k,k)+binomial(n-k-1,k-1)) * ((-1)^k+sum(i=0,k-1,(-1)^(k-1-i)*binomial(k,i+1)*i!*2^i)) ) ) } %K A120766 nonn %O A120766 1,3 %A A120766 _Max Alekseyev_, Jul 03 2006