Id go 40 x 40 x3 ,,, and double it up on depth making it 80x40 ,,, or just buy 80 x40 x5 and be done with it
50x50x1.5 is a great workbench if you sew dresses or bake caked ,,, no use if you use a hammer ,,, mind you , you could get very artsy with it and build trusses and the likes ,,,,
Stiffness is proportional to the "second moment of inertia" of the cross section, the formula is simple or there's calculators online to work it out for you.
The 50mm will be slightly stiffer, but the heavier wall on the 40mm box will probably ring less and be a bit more pleasant to work at.
The other issue of course being distributed load. Ping a 3mm box section with a hammer and it might not even notice, 1.5mm and you could be introducing dents and deformations which compromise the structural integrity.
In terms of bending the section moduli of the SHSs [square hollow section] mentioned are almost similar with the 40x40x3 designation being about 10% stronger. For me the smaller cross section with less area for corrosion would be the one to go for together the thicker wall making for easier welding. Good luck with the bench.
Design some inertia in there while you're at it. Can you secure the bench to the floor or wall? Or alternatively build some gravity into it. Nothing worse than chasing a light bench around the workshop.