GH, You do not provide what the glass thickness is, however based upon similar aquariums 0.25 inch glass thickness is common. If it is other, no problem simply adjust. You also asked for several data points as well as the math, so to your answer(s) begin with:
Water is 231 cubic inch per US gallon. Further the dimensions should account for the glass thickness on all sides as the water only occupies the inside. So the first equation to use simply finds the inches per gallon in vertical height of your aquarium:
231 cu. in. per gallon / [(18 - 0.25 - 0.25)in. X (48.5 - 0.25 - 0.25)in.] or, 0.275 inch per gallon in vertical height.
If you are after gallon per inch in vertical height simply: 1/0.275 or, 3.6363 gallon per inch in vertical height.
For your data points then:
10 gallon X 0.275 inch per gallon = 2.75 inch (aka 2 3/4")
15 gallon X 0.275 inch per gallon = 4.125 inch (aka 4 1/8")
20 gallon X 0.275 inch per gallon = 5.5 inch (aka 5 1/2")
Now if you want it in metric, you'll need a metric sized tank