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.

A189826 a(n) = (3^n-n)*(n-1) - 2^n*(n-2).

Original entry on oeis.org

2, 7, 40, 199, 856, 3359, 12440, 44335, 153808, 523159, 1752928, 5804759, 19041608, 61981807, 200458504, 644783071, 2064276256, 6581953703, 20911793168, 66230028871, 209167217752, 658918365247, 2070973772920, 6495510239759, 20334154874096, 63545035094839
Offset: 1

Views

Author

Adeniji, Adenike Apr 28 2011

Keywords

Comments

Previous name was: Identity difference partial transformation semigroup, IDP_n is obtained by taking the absolute value of the difference between the max(Im(alpha)) and min(Im(alpha)) <= 1. The number of elements for each n is denoted by #IDP_n.

Examples

			For n=4, #IDP_n = 199.
		

Programs

  • Magma
    [(3^n-n)*(n-1)-2^n*(n-2): n in [1..30]]; // Vincenzo Librandi, Jun 19 2011
    
  • Mathematica
    LinearRecurrence[{13,-70,202,-337,325,-168,36},{2,7,40,199,856,3359,12440},30] (* Harvey P. Dale, Apr 03 2016 *)
  • PARI
    a(n) = (3^n-n)*(n-1)-2^n*(n-2); \\ Altug Alkan, Sep 20 2018

Formula

a(n) = (3^n-n)*(n-1) - 2^n*(n-2).
G.f.: -x*(2 - 19*x + 89*x^2 - 235*x^3 + 329*x^4 - 210*x^5 + 36*x^6) / ( (3*x-1)^2 *(2*x-1)^2 *(x-1)^3 ). - R. J. Mathar, Jun 20 2011

Extensions

Simpler name using formula from Joerg Arndt, Sep 20 2018