Expected winning of a player with highest lowest and second highest lowest grouping

The triple integral for the continuous case comes to $$\frac18(1-x)^4 + x^3(1-x) + \frac18x^4$$ Its local maximum is near $x=0.86$. The three terms are for $x=a$, $x=b \text{ or }c$ and $x=d$.
Alex's numbers follow one quartic for $n=1$ to $25$, and a different quartic for $n=26$ to $50$.


The question can be easily answered by a short computer program. Below are provided a graph and a table of the total gain (divided by $6$) for each choice $a_1$ of the first player. The best choice is $a_1=43$ with the total gain $139940\cdot 6$.

enter image description here

110400
101476
93150
85441
78365
71935
66161
61050
56606
52830
49720
47271
45475
44321
43795
43880
44556
45800
47586
49885
52665
55891
59525
63526
67850
72450
77280
82295
87447
92685
97955
103200
108360
113372
118170
122685
126845
130575
133797
136430
138390
139590
139940
139347
137715
134945
130935
125580
118772
110400

The program (in Pascal):

program p3542562;
const
 n=50;
var
 OFi:Text;
 a1,a2,a3,a4,gain:LongInt;
 w:array[1..n]of LongInt;
begin
assign(OFi,'3542562.txt');
Rewrite(OFi);
for a1:=1 to n do begin
 w[a1]:=0;
 for a2:=1 to n-2 do for a3:=a2+1 to n-1 do for a4:=a3+1 to n do begin
  if (a1<>a2) and (a1<>a3) and (a1<>a4) then begin
   if a1>a4 then gain:=a1+a2-a3-a4 else
   if a1<a2 then gain:=a1+a4-a2-a3 else
    gain:=a1+a3-a2-a4;
   if gain>0 then w[a1]:=w[a1]+gain;
  end;
 end;
 writeln(OFi,w[a1]);
end;
Close(OFi);
end.

Below are provided a graph and a table of the total gain (divided by $6$) for each choice $a_1$ of the first player *for the case when the winning team gain is paid by the losing team. The best choice now is $a_1=40$ with the total gain $86710\cdot 6$.

enter image description here

0
-17296
-32430
-45494
-56580
-65780
-73186
-78890
-82984
-85560
-86710
-86526
-85100
-82524
-78890
-74290
-68816
-62560
-55614
-48070
-40020
-31556
-22770
-13754
-4600
4600
13754
22770
31556
40020
48070
55614
62560
68816
74290
78890
82524
85100
86526
86710
85560
82984
78890
73186
65780
56580
45494
32430
17296
0