How to use the fluids.Prandtl function in fluids

To help you get started, we’ve selected a few fluids examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github CalebBell / fluids / tests / test_numba.py View on Github external
fluids.Fourier_heat(t=1.5, L=2, rho=1000., Cp=4000., k=0.6))
    
    assert_close(fluids.numba.Graetz_heat(1.5, 0.25, 5, 800., 2200., 0.6),
                 fluids.Graetz_heat(1.5, 0.25, 5, 800., 2200., 0.6))
    
    assert_close(fluids.numba.Schmidt(D=2E-6, mu=4.61E-6, rho=800),
                 fluids.Schmidt(D=2E-6, mu=4.61E-6, rho=800))
    
    assert_close(fluids.numba.Lewis(D=22.6E-6, alpha=19.1E-6),
                 fluids.Lewis(D=22.6E-6, alpha=19.1E-6))
    
    assert_close(fluids.numba.Confinement(0.001, 1077, 76.5, 4.27E-3),
                 fluids.Confinement(0.001, 1077, 76.5, 4.27E-3))
    
    assert_close(fluids.numba.Prandtl(Cp=1637., k=0.010, nu=6.4E-7, rho=7.1),
                 fluids.Prandtl(Cp=1637., k=0.010, nu=6.4E-7, rho=7.1))
    
    assert_close(fluids.numba.Grashof(L=0.9144, beta=0.000933, T1=178.2, rho=1.1613, mu=1.9E-5),
                 fluids.Grashof(L=0.9144, beta=0.000933, T1=178.2, rho=1.1613, mu=1.9E-5))
    
    assert_close(fluids.numba.Froude(1.83, L=2., squared=True),
                 fluids.Froude(1.83, L=2., squared=True))
    
    assert_close(fluids.numba.nu_mu_converter(998., nu=1.0E-6),
                 fluids.nu_mu_converter(998., nu=1.0E-6))
    
    assert_close(fluids.numba.gravity(55, 1E4),
                 fluids.gravity(55, 1E4))
github CalebBell / ht / ht / conv_two_phase.py View on Github external
References
    ----------
    .. [1] Kudirka, A. A., R. J. Grosh, and P. W. McFadden. "Heat Transfer in 
       Two-Phase Flow of Gas-Liquid Mixtures." Industrial & Engineering 
       Chemistry Fundamentals 4, no. 3 (August 1, 1965): 339-44. 
       doi:10.1021/i160015a018.
    .. [2] Dongwoo Kim, Venkata K. Ryali, Afshin J. Ghajar, Ronald L. 
       Dougherty. "Comparison of 20 Two-Phase Heat Transfer Correlations with 
       Seven Sets of Experimental Data, Including Flow Pattern and Tube 
       Inclination Effects." Heat Transfer Engineering 20, no. 1 (February 1, 
       1999): 15-40. doi:10.1080/014576399271691.
    '''
    Vgs = m*x/(rhog*pi/4*D**2)
    Vls = m*(1-x)/(rhol*pi/4*D**2)
    Prl = Prandtl(Cp=Cpl, mu=mu_b, k=kl)
    Rels = D*Vls*rhol/mu_b
    Nu = 125*(Vgs/Vls)**0.125*(mug/mu_b)**0.6*Rels**0.25*Prl**(1/3.)
    if mu_w:
        Nu *= (mu_b/mu_w)**0.14
    return Nu*kl/D
github CalebBell / ht / ht / conv_two_phase.py View on Github external
299.3796286459285

    References
    ----------
    .. [1] Ravipudi, S., and Godbold, T., The Effect of Mass Transfer on Heat
       Transfer Rates for Two-Phase Flow in a Vertical Pipe, Proceedings 6th 
       International Heat Transfer Conference, Toronto, V. 1, p. 505-510, 1978.
    .. [2] Dongwoo Kim, Venkata K. Ryali, Afshin J. Ghajar, Ronald L. 
       Dougherty. "Comparison of 20 Two-Phase Heat Transfer Correlations with 
       Seven Sets of Experimental Data, Including Flow Pattern and Tube 
       Inclination Effects." Heat Transfer Engineering 20, no. 1 (February 1, 
       1999): 15-40. doi:10.1080/014576399271691.
    '''
    Vgs = m*x/(rhog*pi/4*D**2)
    Vls = m*(1-x)/(rhol*pi/4*D**2)
    Prl = Prandtl(Cp=Cpl, mu=mu_b, k=kl)
    Rels = D*Vls*rhol/mu_b
    Nu = 0.56*(Vgs/Vls)**0.3*(mug/mu_b)**0.2*Rels**0.6*Prl**(1/3.)
    if mu_w is not None:
        Nu *= (mu_b/mu_w)**0.14
    return Nu*kl/D
github CalebBell / ht / ht / conv_two_phase.py View on Github external
References
    ----------
    .. [1] Elamvaluthi, G., and N. S. Srinivas. "Two-Phase Heat Transfer in Two
       Component Vertical Flows." International Journal of Multiphase Flow 10, 
       no. 2 (April 1, 1984): 237-42. doi:10.1016/0301-9322(84)90021-1.
    .. [2] Dongwoo Kim, Venkata K. Ryali, Afshin J. Ghajar, Ronald L. 
       Dougherty. "Comparison of 20 Two-Phase Heat Transfer Correlations with 
       Seven Sets of Experimental Data, Including Flow Pattern and Tube 
       Inclination Effects." Heat Transfer Engineering 20, no. 1 (February 1, 
       1999): 15-40. doi:10.1080/014576399271691.
    '''
    Vg = m*x/(rhog*pi/4*D**2)
    Vl = m*(1-x)/(rhol*pi/4*D**2)

    Prl = Prandtl(Cp=Cpl, mu=mu_b, k=kl)
    ReM = D*Vl*rhol/mu_b + D*Vg*rhog/mug
    Nu_TP = 0.5*(mug/mu_b)**0.25*ReM**0.7*Prl**(1/3.)
    if mu_w:
        Nu_TP *= (mu_b/mu_w)**0.14
    return Nu_TP*kl/D
github CalebBell / ht / ht / conv_two_phase.py View on Github external
References
    ----------
    .. [1] Groothuis, H., and W. P. Hendal. "Heat Transfer in Two-Phase Flow.: 
       Chemical Engineering Science 11, no. 3 (November 1, 1959): 212-20. 
       doi:10.1016/0009-2509(59)80089-0. 
    .. [2] Dongwoo Kim, Venkata K. Ryali, Afshin J. Ghajar, Ronald L. 
       Dougherty. "Comparison of 20 Two-Phase Heat Transfer Correlations with 
       Seven Sets of Experimental Data, Including Flow Pattern and Tube 
       Inclination Effects." Heat Transfer Engineering 20, no. 1 (February 1, 
       1999): 15-40. doi:10.1080/014576399271691.
    '''
    Vg = m*x/(rhog*pi/4*D**2)
    Vl = m*(1-x)/(rhol*pi/4*D**2)

    Prl = Prandtl(Cp=Cpl, mu=mu_b, k=kl)
    ReM = D*Vl*rhol/mu_b + D*Vg*rhog/mug

    if water:
        Nu_TP = 0.029*(ReM)**0.87*(Prl)**(1/3.)
    else:
        Nu_TP = 2.6*ReM**0.39*Prl**(1/3.)
    if mu_w:
        Nu_TP *= (mu_b/mu_w)**0.14
    return Nu_TP*kl/D
github CalebBell / ht / ht / conv_two_phase.py View on Github external
References
    ----------
    .. [1] Aggour, Mohamed A. Hydrodynamics and Heat Transfer in Two-Phase 
       Two-Component Flows, Ph.D. Thesis, University of Manutoba, Canada 
       (1978). http://mspace.lib.umanitoba.ca/xmlui/handle/1993/14171.
    .. [2] Dongwoo Kim, Venkata K. Ryali, Afshin J. Ghajar, Ronald L. 
       Dougherty. "Comparison of 20 Two-Phase Heat Transfer Correlations with 
       Seven Sets of Experimental Data, Including Flow Pattern and Tube 
       Inclination Effects." Heat Transfer Engineering 20, no. 1 (February 1, 
       1999): 15-40. doi:10.1080/014576399271691.
    '''
    Vls = m*(1-x)/(rhol*pi/4*D**2)
    Vl = Vls/(1.-alpha)
    
    Prl = Prandtl(Cp=Cpl, k=kl, mu=mu_b)
    Rel = Reynolds(V=Vl, D=D, rho=rhol, mu=mu_b)

    if turbulent or (Rel > 2000.0 and turbulent is None):
        hl = 0.0155*(kl/D)*Rel**0.83*Prl**0.5
        return hl*(1-alpha)**-0.83
    else:
        hl = 1.615*(kl/D)*(Rel*Prl*D/L)**(1/3.)
        if mu_w:
            hl *= (mu_b/mu_w)**0.14
        return hl*(1.0 - alpha)**(-1/3.)
github CalebBell / ht / ht / conv_two_phase.py View on Github external
.. [1] Martin, B. W, and G. E Sims. "Forced Convection Heat Transfer to 
       Water with Air Injection in a Rectangular Duct." International Journal 
       of Heat and Mass Transfer 14, no. 8 (August 1, 1971): 1115-34. 
       doi:10.1016/0017-9310(71)90208-0.
    .. [2] Dongwoo Kim, Venkata K. Ryali, Afshin J. Ghajar, Ronald L. 
       Dougherty. "Comparison of 20 Two-Phase Heat Transfer Correlations with 
       Seven Sets of Experimental Data, Including Flow Pattern and Tube 
       Inclination Effects." Heat Transfer Engineering 20, no. 1 (February 1, 
       1999): 15-40. doi:10.1080/014576399271691.
    '''
    Vgs = m*x/(rhog*pi/4*D**2)
    Vls = m*(1-x)/(rhol*pi/4*D**2)
    if hl is None:
        V = Vgs + Vls # Net velocity
        Re = Reynolds(V=V, D=D, rho=rhol, mu=mu_b)
        Pr = Prandtl(Cp=Cpl, k=kl, mu=mu_b)
        Nul = laminar_entry_Seider_Tate(Re=Re, Pr=Pr, L=L, Di=D, mu=mu_b, mu_w=mu_w)
        hl = Nul*kl/D
    return hl*(1.0 + 0.64*(Vgs/Vls)**0.5)
github CalebBell / ht / ht / conv_two_phase.py View on Github external
.. [1] Knott, R. F., R. N. Anderson, Andreas. Acrivos, and E. E. Petersen. 
       "An Experimental Study of Heat Transfer to Nitrogen-Oil Mixtures." 
       Industrial & Engineering Chemistry 51, no. 11 (November 1, 1959): 
       1369-72. doi:10.1021/ie50599a032. 
    .. [2] Dongwoo Kim, Venkata K. Ryali, Afshin J. Ghajar, Ronald L. 
       Dougherty. "Comparison of 20 Two-Phase Heat Transfer Correlations with 
       Seven Sets of Experimental Data, Including Flow Pattern and Tube 
       Inclination Effects." Heat Transfer Engineering 20, no. 1 (February 1, 
       1999): 15-40. doi:10.1080/014576399271691.
    '''
    Vgs = m*x/(rhog*pi/4*D**2)
    Vls = m*(1-x)/(rhol*pi/4*D**2)
    if not hl:
        V = Vgs + Vls # Net velocity
        Re = Reynolds(V=V, D=D, rho=rhol, mu=mu_b)
        Pr = Prandtl(Cp=Cpl, k=kl, mu=mu_b)
        Nul = laminar_entry_Seider_Tate(Re=Re, Pr=Pr, L=L, Di=D, mu=mu_b, mu_w=mu_w)
        hl = Nul*kl/D
    return hl*(1 + Vgs/Vls)**(1/3.)