24 Litres!
Let the quantity of wine the cask held originally= X litres
Now, after first operation quantity of wine held by cask= X-8 litres
After second operation, the quantity of wine held by cask= (X-8) - (X-8)*8/X ...second term is the proportion of wine removed from the mixture of wine and water in second operation.
==> Held quantity = (X-8) - (8X-64)/X = (X^2-8X-8X+64)/X = (X^2-16X+64)/X
taking X^2 out of bracket term.... X^2(1-16/X+64/X^2)/X= X(1-2*8/X+(8/X)^2) = X(1-8/X)^2
Similarly, after third operation, quantity of wine held in mixture= X(1-8/X)^3
and after fourth operation, quanity held = X(1-8/X)^4
So, ratio of wine to total mixture...
(X(1-8/X)^4)/X = 16/81 =>> (1-8/X)^4 = (2/3)^4 =>> 1-8/X = 2/3 =>> (X-8)*3 = 2*X
Hence, X = 24 litres