There might be a formula with all of the variables needed, but I think you can answer this question easily enough without one, if you have actual loans in mind.
It should be pretty straight-forward to run the numbers given the existing loan information, current rates, and how much over you can pay each month given any specific value of T. There are 4 parts to calculate, before T with one loan at 0%, and after T with that loan changing back to its regular rate, and for each, putting the extra principal payments towards one loan or the other. You should be able to run both sides for any specific T value and see how long it takes to pay off both loans (or just look at the total amount paid at the end).
Now re-run that same calculation for various T values, starting at 1, and incrementing by 1 month until it flips and makes sense to start paying off the lower interest loan first. Let's say for example you run T from 1 to 20 and that it flips at T = 20 months. Now all you have to do is guess the likelihood the interest will remain at 0% for at last 20 months. In this example perhaps you believe it would not last 20 months, and therefore you'd be better off still paying the higher interest rate first, despite the temporary interest suspension.
As a side note, if you were to try to obtain a formula, there is some extra information that might be needed: Does the loan with the suspended interest have it's minimum payment lowered, or does it stay the same and suddenly more goes towards the principal of the loan? If the minimum is reduced it would give you more to work with to put towards the other loan each month, for that side of the calculation.