%I #11 Feb 21 2026 09:09:43
%S 1,2,90,19089,16173999,1414293534,2802869044173,22551947376101055,
%T 213300662882056463637,4552155569894863857602445,
%U 6356674411068592198597993830,112761457122054803122314301920246
%N a(n) is the hafnian of the 2n X 2n symmetric matrix whose generic element M[i,j] is equal to the digit reversal of i*j.
%H Wikipedia, <a href="https://en.wikipedia.org/wiki/Hafnian">Hafnian</a>.
%H Wikipedia, <a href="https://en.wikipedia.org/wiki/Symmetric_matrix">Symmetric matrix</a>.
%e a(2) = 90:
%e [1, 2, 3, 4]
%e [2, 4, 6, 8]
%e [3, 6, 9, 21]
%e [4, 8, 21, 61]
%t M[i_, j_, n_] :=IntegerReverse[i*j ]; a[n_] := Sum[Product[M[Part[PermutationList[s, 2 n], 2 i - 1], Part[PermutationList[s, 2 n], 2 i], 2 n], {i, n}], {s, SymmetricGroup[2 n] // GroupElements}]/(n!*2^n); Array[a, 6, 0]
%o (PARI) tm(n) = matrix(n, n, i, j, fromdigits(Vecrev(digits(i*j))));
%o a(n) = my(m = tm(2*n), s=0); forperm([1..2*n], p, s += prod(j=1, n, m[p[2*j-1], p[2*j]]); ); s/(n!*2^n); \\ _Michel Marcus_, Feb 21 2026
%Y Cf. A003991, A004086, A391365, A393479 (permanent).
%Y Cf. A354865, A357279, A357420, A357421, A357503, A358158, A358160, A358162, A358164.
%K nonn,base,hard,more
%O 0,2
%A _Stefano Spezia_, Feb 16 2026
%E a(6)-a(10) from _Pontus von Brömssen_, Feb 16 2026
%E a(11) from _Sean A. Irvine_, Feb 20 2026