cp's OEIS Frontend

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.

A211068 Number of 2 X 2 matrices having all terms in {1,...,n} and positive odd determinant.

Original entry on oeis.org

0, 3, 20, 48, 144, 243, 528, 768, 1400, 1875, 3060, 3888, 5880, 7203, 10304, 12288, 16848, 19683, 26100, 30000, 38720, 43923, 55440, 62208, 77064, 85683, 104468, 115248, 138600, 151875, 180480, 196608, 231200, 250563, 291924
Offset: 1

Views

Author

Clark Kimberling, Mar 31 2012

Keywords

Comments

For a guide to related sequences, see A210000.

Crossrefs

Cf. A210000.

Programs

  • Magma
    [(2*n+1-(-1)^n)^2*(6*n+1-(-1)^n)*(2*n-1+(-1)^n)/256: n in [1..40]]; // Vincenzo Librandi, Nov 28 2016
  • Mathematica
    a = 1; b = n; z1 = 35;
    t[n_] := t[n] = Flatten[Table[w*z - x*y, {w, a, b}, {x, a, b}, {y, a, b}, {z, a, b}]]
    c[n_, k_] := c[n, k] = Count[t[n], k]
    u[n_] := u[n] = Sum[c[n, 2 k], {k, 0, n^2}]
    v[n_] := v[n] = Sum[c[n, 2 k], {k, 1, n^2}]
    w[n_] := w[n] = Sum[c[n, 2 k - 1], {k, 1, n^2}]
    Table[u[n], {n, 1, z1}]  (* A211066 *)
    Table[v[n], {n, 1, z1}]  (* A211067 *)
    Table[w[n], {n, 1, z1}]  (* A211068 *)
    LinearRecurrence[{1, 4, -4, -6, 6, 4, -4, -1, 1}, {0, 3, 20, 48, 144, 243, 528, 768, 1400}, 50] (* Vincenzo Librandi, Nov 28 2016 *)

Formula

From Chai Wah Wu, Nov 27 2016: (Start)
a(n) = A211065(n)/2.
a(n) = (2*n + 1 -(-1)^n)^2*(6*n + 1 -(-1)^n)*(2*n - 1 + (-1)^n)/256.
a(n) = a(n-1) + 4*a(n-2) - 4*a(n-3) - 6*a(n-4) + 6*a(n-5) + 4*a(n-6) - 4*a(n-7) - a(n-8) + a(n-9) for n > 9.
G.f.: -x^2*(3*x^5 + 5*x^4 + 28*x^3 + 16*x^2 + 17*x + 3)/((x - 1)^5*(x + 1)^4). (End)