r'''Calculates internal convection Nusselt number for turbulent flows
    in pipe according to [2]_ as shown in [1]_. The most widely used rough
    pipe turbulent correlation.

    .. math::
        Nu_D = \frac{(f/8)Re_DPr}{1+\sqrt{f/8}(4.5Re_{\epsilon}^{0.2}Pr^{0.5}-8.48)}

    Parameters
    ----------
    Re : float
        Reynolds number, [-]
    Pr : float
        Prandtl number, [-]
    fd : float
        Darcy friction factor [-]
    eD : float
        Relative roughness, [-]

    Returns
    -------
    Nu : float
        Nusselt number, [-]

    Notes
    -----
    According to [1]_, the limits are:
    0.5 ≤ Pr ≤  10
    0.002 ≤ ε/D ≤  0.05
    10,000 ≤ Re_{D}
    Another correlation is listed in this equation, with a wider variety
    of validity.

    Examples
    --------
    >>> turbulent_Bhatti_Shah(Re=1E5, Pr=1.2, fd=0.0185, eD=1E-3)
    302.7037617414273

    References
    ----------
    .. [1] Rohsenow, Warren and James Hartnett and Young Cho. Handbook of Heat
       Transfer, 3E. New York: McGraw-Hill, 1998.
    .. [2] M. S. Bhatti and R. K. Shah. Turbulent and transition flow
       convective heat transfer in ducts. In S. Kakaç, R. K. Shah, and W.
       Aung, editors, Handbook of Single-Phase Convective Heat Transfer,
       chapter 4. Wiley-Interscience, New York, 1987.

def turbulent_Bhatti_Shah(Re, Pr, fd, eD):
    r'''Calculates internal convection Nusselt number for turbulent flows
    in pipe according to [2]_ as shown in [1]_. The most widely used rough
    pipe turbulent correlation.

    .. math::
        Nu_D = \frac{(f/8)Re_DPr}{1+\sqrt{f/8}(4.5Re_{\epsilon}^{0.2}Pr^{0.5}-8.48)}

    Parameters
    ----------
    Re : float
        Reynolds number, [-]
    Pr : float
        Prandtl number, [-]
    fd : float
        Darcy friction factor [-]
    eD : float
        Relative roughness, [-]

    Returns
    -------
    Nu : float
        Nusselt number, [-]

    Notes
    -----
    According to [1]_, the limits are:
    0.5 ≤ Pr ≤  10
    0.002 ≤ ε/D ≤  0.05
    10,000 ≤ Re_{D}
    Another correlation is listed in this equation, with a wider variety
    of validity.

    Examples
    --------
    >>> turbulent_Bhatti_Shah(Re=1E5, Pr=1.2, fd=0.0185, eD=1E-3)
    302.7037617414273

    References
    ----------
    .. [1] Rohsenow, Warren and James Hartnett and Young Cho. Handbook of Heat
       Transfer, 3E. New York: McGraw-Hill, 1998.
    .. [2] M. S. Bhatti and R. K. Shah. Turbulent and transition flow
       convective heat transfer in ducts. In S. Kakaç, R. K. Shah, and W.
       Aung, editors, Handbook of Single-Phase Convective Heat Transfer,
       chapter 4. Wiley-Interscience, New York, 1987.
    '''
    Re_e = Re*eD*(fd/8.)**0.5
    return Re*Pr*fd/8./(1 + (fd/8.)**0.5*(4.5*Re_e**0.2*Pr**0.5 - 8.48))