The foam stability of anionic–nonionic surfactant (A12E2SO3) was studied by molecular dynamics simulations.
Two forms of hydrogen bond bridging structures (O1⋯H2O⋯O2 and O2⋯H2O⋯Os) were observed for the first time in anionic surfactants.
The favorable structure of A12E2SO3 monolayer for the increased stability was obtained in the foam system with the addition of Mg2+.