The constitutive equation and flow dynamics of bubbly magmas