A compresible formulation for multiphase flows of geophysical and geodynamic interest