  The concept of clearing or netting, as defined in the glossaries of European
Central Bank, has a great impact on the economy of a country influencing the
exchanges and the interactions between companies. On short, netting refers to
an alternative to the usual way in which the companies make the payments to
each other: it is an agreement in which each party sets off amounts it owes
against amounts owed to it. Based on the amounts two or more parties owe
between them, the payment is substituted by a direct settlement. In this paper
we introduce a set of graph algorithms which provide optimal netting solutions
for the scale of a country economy. The set of algorithms computes results in
an efficient time and is tested on invoice data provided by the Romanian
Ministry of Economy. Our results show that classical graph algorithms are still
capable of solving very important modern problems.
