login
((-1)^n - 1 + 2*(n^floor((n + 1)/2)))/4
2

%I #8 Aug 10 2016 00:28:10

%S 0,1,4,8,62,108,1200,2048,29524,50000,885780,1492992,31374258,

%T 52706752,1281445312,2147483648,59293938248,99179645184,3065533128900,

%U 5120000000000

%N ((-1)^n - 1 + 2*(n^floor((n + 1)/2)))/4

%C Number of 2-r stable discrete function classes on [n] under reversal and complement to n+1.

%C f(n) == 2 (mod 4) if n == 5 mod 8, otherwise (except for n=2) f(n) == 0 (mod 4). - _Robert Israel_, Aug 09 2016

%H Robert Israel, <a href="/A275574/b275574.txt">Table of n, a(n) for n = 1..700</a>

%p f:= n -> ((-1)^n - 1 + 2*(n^floor((n + 1)/2)))/4:

%p map(f, [$1..30]); # _Robert Israel_, Aug 09 2016

%t Table[1/4 ((-1)^ n-1+2 (n)^Floor[(n+1)/2]),{n,1,20}]

%Y Cf. A275550.

%K nonn,easy

%O 1,3

%A _Olivier GĂ©rard_, Aug 02 2016