Is there a theory / equation showing whether or not two passing bodies will go into orbit around each other? I am looking for a theory that shows whether or not two passing celestial bodies will go into orbit.

I assume there would have to be a critical point where the gravitational attraction is stronger than the inertia of the moving bodies.

The bodies would then orbit until they collide, or be affected by a force to fall behind the critical point and escape orbit.

I am looking for a theory that states that objects past this critical point of gravitational attraction must either collide immediately, or go into orbit after falling within a certain distance.
If there are only two bodies, then they will never enter a mutual orbit. For two objects initially gravitationally unbound, in order to become gravitationally bound you must remove energy from the system. With only two bodies (that don't collide), this does not happen. They will accelerate toward each other, change directions according to how close they get, and then leave each other again with exactly the same total energy and momentum as before, but in general shared in some other ratio (for instance, if a small body encounters a large body, the smaller will gain energy and leave with a larger velocity).

On the other hand, if you have three (or more) bodies, one may get slung out with high velocity, thus extracting energy from the two others, which can then go in orbit. But alas, there's no equation for this; the so-called N-body problem has no analytic solution, and must in general be solved numerically.