This Matlab code can be used for generating a steady state slug hydrodynamic profile for an inclined pipe transporting the multiphase liquid-gas flow, based on a slug unit cell concept.