RIO DE JANEIRO/BRASILIA – An agreement by Vale, BHP and their joint venture Samarco to pay 170 billion reais ($29.85 billion) in compensation for a deadly dam collapse in Brazil could end more than a hundred lawsuits against the mining companies in the South American country and possibly limit legal action abroad, three sources close to the matter said.