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 A221882 #31 Aug 18 2025 06:27:42 %S A221882 1,4,13,36,91,218,505,1144,2551,5622,12277,26612,57331,122866,262129, %T A221882 557040,1179631,2490350,5242861,11010028,23068651,48234474,100663273, %U A221882 209715176,436207591,905969638,1879048165,3892314084,8053063651,16642998242,34359738337 %N A221882 Number of order-preserving or order-reversing full contraction mappings of an n-chain. %C A221882 a(n) is the order of the semigroup (monoid) of order-preserving or order-reversing full contraction mappings (of an n-chain). %H A221882 Paolo Xausa, <a href="/A221882/b221882.txt">Table of n, a(n) for n = 1..3000</a> %H A221882 A. D. Adeshola, V. Maltcev and A. Umar, <a href="http://arxiv.org/abs/1303.7428">Combinatorial results for certain semigroups of order-preserving full contraction mappings of a finite chain</a>, arXiv:1303.7428 [math.CO], 2013. %H A221882 A. D. Adeshola, A. Umar, <a href="https://combinatorialpress.com/jcmcc/vol106/">Combinatorial results for certain semigroups of order-preserving full contraction mappings of a finite chain</a>, JMCC 106 (2017) 37-49 %H A221882 <a href="/index/Rec#order_04">Index entries for linear recurrences with constant coefficients</a>, signature (6,-13,12,-4). %F A221882 a(n) = (n+1)*2^(n-1) - n. %F A221882 a(n) = 6*a(n-1) - 13*a(n-2) + 12*a(n-3) - 4*a(n-4). %F A221882 a(n) = Sum_{k=1..n} A221877(n,k) = Sum_{k=0..n-1} A221878(n,k) = Sum_{k=1..n} A221881(n,k). [Edited by _Paolo Xausa_, Aug 18 2025] %F A221882 G.f.: x*(1-2*x+2*x^2-2*x^3)/(1-3*x+2*x^2)^2. [_Bruno Berselli_, Mar 01 2013] %e A221882 a(3) = 13 because there are exactly 13 order-preserving or order-reversing full contraction mappings of a 3-chain, namely: (111), (112), (211), (122), (221), (123), (321), (222), (223), (233), (322), (332), (333). %t A221882 A221882[n_] := (n + 1)*2^(n - 1) - n; Array[A221882, 50] (* or *) %t A221882 LinearRecurrence[{6, -13, 12, -4}, {1, 4, 13, 36}, 50] (* _Paolo Xausa_, Aug 18 2025 *) %o A221882 (PARI) a(n)=(n+1)<<(n-1)-n; \\ _Charles R Greathouse IV_, Feb 28 2013 %Y A221882 Cf. A045992, A221876, A221877, A221878, A221880, A221881. %K A221882 nonn,easy %O A221882 1,2 %A A221882 _Abdullahi Umar_, Feb 28 2013 %E A221882 More terms from _Joerg Arndt_, Mar 01 2013