The correct equation should be: MLM - DOM - FUEL REMAINING

Assuming traffic is limited by landing mass at London, the fuel figure; before taxi it is 20,100 * 0.79 = 15,879. To get fuel remaining of 9,639, you must subtract taxi and trip fuel (250 and 5,990).
Using the formula, you get the answer given: 58,900 - 34,930 - 9,639 = 14,331