 The violent collapse of bubbles (cavitation) near solid surfaces and the resulting impinging jet constitute the mechanism used in ultrasonic cleaning.The same effect, but on a larger scale, is used in focused energy weapons such as the bazooka and the torpedo.Pistol shrimp also use a collapsing cavitation bubble as a weapon.