In 1940 there were less than 20 operational U Boats and 2,3 million ton of MV was lost .
In 1941 there were mostly more than 40 operational U Boats and the losses were 2,2 million GRT .
Not sure where you're getting your numbers from, but the Kreigsmarine had far more than 20 operational U-Boats in 1940 and so on.
You may be misreading their operational status, which showed about 40 at sea when WWII staryed on 1 September 1939.
There was a slight lull by Christmas '39 where most boats were in port, but their numbers (put to sea) started increasing during winter/spring of '40, reaching about 35 at sea by April.
Then by Spring of 1941, their numbers at sea
did not drop under 40 deployed until 29 April 1945.
It should also be noted that the U-Boat numbers deployed at sea do not include the Coastal type U-Boats, as they were not sea-going.
As far as tonnage is concerned, the U-Boats accounted for:
1939 (Sept - Dec): 0.6 million tons
1940: 2.3 million tons
1941: 2.2 million tons
1942: 5.8 million tons
1943: 2.3 million tons
1944: 0.6 million tons
1945 (Jan - Apr) 0.2 million tons
This totals 14 million tons.
That is a tremendous amount of valuable shipping lost.
To put tonnage in perspective, the IJN Yamato, one of the world's largest warships, weighed 71,660 tons (fully loaded, battle ready).
That's a.considerable amount of food, clothing, vehicles, ammunition, fuel, aircraft, raw materials and humans that were lost...