The city of Detroit reached an agreement on Tuesday with two banks to end a costly interest-rate swap agreement, a significant step as the city negotiates with creditors to put together a plan to exit the largest municipal bankruptcy in U.S. history, Reuters reported yesterday. Detroit will pay $165 million, plus up to $4.2 million in costs, to end the interest-rate swap agreements with UBS AG and Bank of America Corp.’s Merrill Lynch Capital Services at a 43 percent discount. The new agreement, which was reached after Bankruptcy Judge Steven Rhodes asked the city to negotiate better terms than it first proposed, will save the city about $65 million. As part of the arrangement, Detroit will also take out a $285 million loan from Barclays PLC to pay to end the swaps. It will use $120 million of that toward improvements to services in the city, which is hampered by $18.5 billion in debt.