Using the Old PoolMath Webpage link at the bottom of the page...
20 x 40 x 3.5 = 20900
20 x 40 x 6 = 35900
Let's break the pool down into two 20 x 20 sections
20 x 20 x 3.3 = 9900
20 x 20 x 6 = 18000 (6 feet estimated average depth of deep end)
Based on your pool depth profile, I'd estimate 26000-28000 gallons
Is the pool already filled?
If not, and you can check the starting and ending meter readings, you can get a much better guess of the volume.
You can also use certain pool chemicals to zero in on volume.