  The oscillatory flows present in an inkjet printhead can lead to strong
deformations of the air-liquid interface at the nozzle exit. Such deformations
may lead to an inward directed air jet with bubble pinch-off and the subsequent
entrainment of an air bubble, which is highly detrimental to the stability of
inkjet printing. Understanding the mechanisms of bubble entrainment is
therefore crucial in improving print stability. In the present work, we use
ultrafast X-ray phase-contrast imaging and direct numerical simulations based
on the Volume-of-Fluid method to study the mechanisms underlying the bubble
entrainment in a piezo-acoustic printhead. We first demonstrate good agreement
between experiments and numerics. We then show the different classes of bubble
pinch-off obtained in experiments, and that those were also captured
numerically. The numerical results are then used to show that the baroclinic
torque, which is generated at the gas-liquid interface due to the misalignment
of density and pressure gradients, results in a flow-focusing effect that
drives the formation of the air jet from which a bubble can pinch-off.
