 derivativeGasDensityWrtGasPressure(this,rhog,pg)
            <span class="comment">% Pertubation value</span>
            pert = sqrt(eps);
            <span class="comment">% Compute the gas density given a pertubation at the gas pressure</span>
            rhogPert = this.gasFluid.getDensity(pg + pert);
            <span class="comment">% Compute the derivative</span>
            drhogdpg = (rhogPert - rhog)/(pert);
        <span class="keyword">end</span>

    <span class="keyword">end</span>
</pre><pre