The restriction to the said formula matters from the following derivation, which I will politely color orange for those less inclined to drool through algebra:
Suppose you’re fighting badguy X. It turns out you need, say, a 15 or better to hit X. You threaten a crit on an 18 since it turns out you’re wielding a Falchion. X is vulnerable to crits (aren’t we all).
SNIP.
Great, answer the question frisbeet. What condition did I require in this derivation? Answer: N, the # of d20 outcomes which hit-but-don’t-threat, must be >=0. This formula is exactly wrong when badguy X’s AC is high enough such that only a 20 or 19 or (generalizing) 20-C+2 or better hits. A very subtle point. Gotcha! for reading this.
Which is why, I think, it’s clearer to just do the calculations against several AC taking into account a whole bunch of things yada yada yada click sig.