Even as Congress frantically passes offers back and forth to reopen the US government and raise the ceiling on federal borrowing, financial markets remain fixated on what happens if they fail and there is a default on US debts.

Officials at many agencies say that they are thinking of contingencies but will not discuss them publicly in advance of a crisis. They will not request final decisions from their bosses unless default is imminent and it becomes a necessity.

“In my personal view the Treasury has a back-up plan and I don’t think they want to miss coupon payments,” says Eric Green at TD Securities in New York. “The problem is they can’t publicly talk about this as it blurs the motivation [in Congress] to get a plan done.”

Contingency planning is also complicated because it involves a cascade of decisions, each depending on the one before. If there were no deal, it all starts on Thursday, when the Treasury runs out of ways to delay the debt limit.

Is October 17 really the deadline?

No, or at least not exactly. Jack Lew, the US Treasury secretary, has been careful not to say the US will run out of cash but rather that it will have “run out of borrowing authority”. By the end of Thursday the US will be like a shopper who has hit his overdraft limit: he cannot borrow more but still has cash in his wallet.

When that cash runs out depends on when bills fall due. Steve Bell, senior director at the Bipartisan Policy Centre in Washington, estimates the “X-date” will fall between October 23, when a $12bn Social Security payment is due, and November 1, when a slew of bills will use up remaining cash.

It is not that simple, however, because each Thursday – October 17, 24 and 31 – the US has to roll over debt. As long as investors are willing, rollovers do not use up cash. In that case, the real deadline is either November 1 or whenever markets panic.

There is one more wrinkle. Through a legally dubious manoeuvre, known as an extension of the Debt Issuance Suspension Period, the Treasury could buy a little more time. Doing so would contradict Mr Lew, however, and there would be no point unless a settlement were in sight.

Can the president ignore the debt ceiling?

For all the outlandish arguments about invoking the 14th amendment or minting a $1tn platinum coin, President Barack Obama has two options if there is no increase in the borrowing limit: he can respect the debt limit law or he can ignore it.

Mr Obama and his advisers insist there is no escape hatch but, if it came to it, Mr Bell thinks the president would have no choice but to ignore the limit and keep borrowing. “Would you rather have turmoil in global markets or would you rather have lawyers arguing?” he says. “I’m much more worried about the market reaction than I am about a theoretical legal or constitutional problem.”

The president could simply say that the law is contradictory: Congress has ordered him to spend money but also restricted borrowing. He could throw up his hands, keep borrowing, and say, “sue me”. Some lawyers say that doing so is a constitutional necessity; others think it would lead to constitutional chaos.

There are serious political and practical problems with this approach. It would absolve Republicans of blame for the crisis and all new debt issuance would be suspect until the law became clear.

Prioritise payments or not?

If the cash runs out, and the president chooses to respect the debt limit, then the Treasury has to decide which bills to pay and how. According to a report by its inspector general on the 2011 debt ceiling fight there are four options: asset sales, across-the-board payment reductions, prioritisation of payments and payment delays.

The report says Treasury staff thought “the least harmful option . . . was to implement a delayed payment regime”. The idea would be to wait for enough cash to pay a full day’s outgoings and then process every payment due that day. Over time, all payments would gradually fall further into arrears.

Within that, though, there is a separate question of whether to prioritise debt payments in order to avoid a default on obligations to the financial markets. Doing so is technically possible because debt payments go via a separate system.

The credit rating agency Moody’s thinks the Treasury would prioritise debt payments, in which case it could avoid a default on its obligations almost indefinitely, but there is no obvious legal basis to do so. It would lead to the politically agonising spectacle of payments to Chinese debt holders in preference to the pensions of disabled military veterans.

How could the chaos be managed?

It is hard to imagine the financial environment after a default on US debt but “chaos” is probably a mild description. “An actual default would change things materially, with severe disruptions in the money markets, use of Treasuries as collateral and the repo market,” says Marc Chandler, a currency strategist at Brown Brothers Harriman in New York.

The one entity able to mount a meaningful response would be the US Federal Reserve. Similar to its actions in the 2008-09 crisis, it is likely to provide liquidity wherever it were needed, so no institution ran out of cash. There are also two further levels of action it could take: lending against defaulted Treasury securities or buying them outright.

Both measures would need a ruling from Fed lawyers but there is no obvious prohibition in the Federal Reserve Act. Section 10B says it can lend as long as the security is “to the satisfaction of such Federal Reserve bank”. Section 14 says it can buy any obligation of the US in the open market.

With the economy collapsing because of default on payments, however, such measures would be like sandbags against the flood.