If you are working in a field, the application is on an area basis. so work out the plot size . 20 tones per hectare is a weight per area.
You must consider your plot area (or pot area,) rather than the weight of soil. So work out the plot area (length by width ) or the pot area of the pot (typically a circular pot ) so you calculate the (area of a circle) at soil height in the pot.
It depends on the depth your soil (or, at least, the depth that interest you for our study : the ploughing depth? The depth explored by the roots?). Once you answered that question, it is just a simple calculation to make using the soil density (approximately 1,3 for a sandy soil and up to 1,5 for a clay soil).
You need to know the depth to which the compost will be incorporated and the bulk density of the soil. A sample calculation assuming that the compost is mixed into the soil to 0.1 m depth and the bulk density of the soil is 1.3 t/m^3.