function [M_L,M_G]=inertia(alpha_L,rho_G,u_L,u_G,data)
%   Function for computing the momentum of the flow in a staggered grid
%   approch
%
%   Written by Espen Storkaas 16. Jan 2003
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
[d_L,d_G]=flowdir(mean([u_L(data.I_mL) u_L(data.I_mL+1)],2),...
    mean([u_G(data.I_mL) u_G(data.I_mL+1)],2));
M_L=alpha_L*data.rho_L.*mean([u_L(data.I_mL) u_L(data.I_mL+1)],2).*u_L(data.I_mL+d_L);
M_G=(1-alpha_L).*rho_G.*mean([u_G(data.I_mL) u_G(data.I_mL+1)],2).*u_G(data.I_mL+d_G);