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 A268191 #22 May 23 2018 07:21:29 %S A268191 0,0,1,3,8,14,27,42,67,101,149,210,301,416,565,770,1030,1368,1800, %T A268191 2357,3055,3962,5068,6485,8232,10444,13125,16506,20600,25701,31865, %U A268191 39483,48644,59906,73375,89846,109515,133379,161784,196078,236801,285720,343623,412866,494624,591991,706623,842625 %N A268191 The difference between the two largest distinct parts of a partition (0 if no distinct parts), summed over all partitions of n. %H A268191 Vaclav Kotesovec, <a href="/A268191/b268191.txt">Table of n, a(n) for n = 1..1932</a> (terms 1..1000 from Alois P. Heinz) %F A268191 a(n) = Sum_{k>0} k*A268190(n,k). %F A268191 G.f.: g = Sum_{i>1} (Sum_{j = 1..i-1} ((i-j)*x^{i+j}/((1-x^i) * Product_{k=1..j} (1 - x^k)))). %e A268191 a(5) = 8 because the partitions [5], [4,1], [3,2], [3,1,1], [2,2,1], [2,1,1,1], and [1,1,1,1,1] of 5 contribute 0, 3, 1, 2, 1, 1, and 0, respectively. %p A268191 g := add(add((i-j)*x^(i+j)/((1-x^i)*mul(1-x^k, k = 1 .. j)), j = 1 .. i-1), i = 2 .. 80): gser := series(g, x = 0, 55): seq(coeff(gser, x, n), n = 1 .. 50); %p A268191 # second Maple program: %p A268191 b:= proc(n, l, i) option remember; `if`(irem(n, i)=0, %p A268191 `if`(l=0, 0, i-l), 0) +`if`(i>n, 0, add(b(n-i*j, %p A268191 `if`(j=0, l, i), i+1), j=0..(n-1)/i)) %p A268191 end: %p A268191 a:= n-> b(n, 0, 1): %p A268191 seq(a(n), n=1..50); # _Alois P. Heinz_, Feb 11 2016 %t A268191 b[n_, l_, i_] := b[n, l, i] = If[Mod[n, i] == 0, If[l == 0, 0, i-l], 0] + If[i>n, 0, Sum[b[n-i*j, If[j == 0, l, i], i+1], {j, 0, (n-1)/i}]]; a[n_] := b[n, 0, 1]; Table[a[n], {n, 1, 50}] (* _Jean-François Alcover_, Dec 21 2016, after _Alois P. Heinz_ *) %Y A268191 Cf. A268190. %K A268191 nonn %O A268191 1,4 %A A268191 _Emeric Deutsch_, Feb 10 2016