pl);
            rhog = this.gasFluid.getDensity(pg);
            <span class="comment">% Capillary pressure</span>
            pc = pg - pl;
            <span class="comment">% Derivative of the liquid saturation degree wrt pc</span>
            dSldpc = this.capillaryPressure.derivativeSaturationDegree(pc, this.porousMedia);
            <span class="comment">% Derivative of the gas density wrt to pg</span>
            drhogdpg = this.derivativeGasDensityWrtGasPressure(rhog,pg);
            <span class="co