示例#1
0
    'v_Sounders_Brown', 'K_separator_Watkins', 'K_separator_demister_York',
    'K_Sounders_Brown_theoretical'
]

# 92 points taken from a 2172x3212 page scan, after dewarping the scan,
# digitization with Engauge Digitizer, and extensive checking; every 5th point
# it produced was selected plus the last point. The initial value is adjusted
# to be the lower limit of the graph.

tck_Watkins = implementation_optimize_tck(
    [[
        -5.115995809754082, -5.115995809754082, -5.115995809754082,
        -5.115995809754082, -4.160106231099973, -3.209113630523477,
        -1.2175106961204154, 0.4587657198189318, 1.1197669427405068,
        1.6925908552310418, 1.6925908552310418, 1.6925908552310418,
        1.6925908552310418
    ],
     [
         -1.4404286048266364, -1.2375168139385286, -0.9072614905522024,
         -0.7662335745829165, -0.944537665617708, -1.957339717378027,
         -3.002614318094637, -3.5936804378352956, -3.8779153181940553, 0.0,
         0.0, 0.0, 0.0
     ], 3])


def K_separator_Watkins(x, rhol, rhog, horizontal=False, method='spline'):
    r'''Calculates the Sounders-Brown `K` factor as used in determining maximum
    allowable gas velocity in a two-phase separator in either a horizontal or
    vertical orientation. This function approximates a graph published in [1]_
    to determine `K` as used in the following equation:

    .. math::
示例#2
0
tck_uninstulated_Catton = implementation_optimize_tck(
    [[
        0.125, 0.125, 0.125, 0.125, 0.41375910864088195, 0.5819413331927507,
        1.9885569998423345, 2.8009586482973834, 3.922852887459219, 6.0, 6.0,
        6.0, 6.0
    ],
     [
         0.125, 0.125, 0.125, 0.125, 0.4180739258304788, 0.6521218159098487,
         1.4270223336187269, 2.89426640315332, 3.9239774081390215, 6.0, 6.0,
         6.0, 6.0
     ],
     [
         16.098194938851986, 14.026983058722742, 13.35866942808268,
         13.043296359953983, 13.008470795621905, 12.991279831677808,
         13.040841344665466, 13.07803101947673, 13.111789672293794,
         14.074352449019207, 14.878522936155216, 11.151352953023258,
         11.096394321545977, 10.813773781060574, 10.796217122120712,
         10.78189560829848, 10.774336865714089, 10.78004622910552,
         13.400086198278455, 11.369928815173187, 11.82067779495709,
         9.6860949637944, 9.686120336218499, 9.50952376562826,
         9.444619552074945, 9.452058024482865, 9.441608909473647,
         12.933722760010111, 10.873615956186896, 8.971126166473885,
         8.520162104980807, 8.317346176887659, 7.837750498437191,
         7.78951404473208, 7.690715685713949, 7.695209247397283,
         13.025815591825872, 10.75723159025179, 9.734653433466208,
         8.569056561731081, 8.77031704228521, 7.853798846698488,
         7.939088236475908, 7.748880239519593, 7.785611785518214,
         12.992898431724237, 10.728320934519346, 9.37520794405935,
         8.247995842200584, 7.753730020752022, 7.937553314495094,
         7.6598493250444255, 7.673199977054488, 7.63790748099515,
         13.041869920313422, 10.713059500923494, 9.364505568407685,
         8.18000143764639, 7.927764179244221, 7.660718938605501,
         7.85174473958641, 7.5354388646400965, 7.614740168201775,
         13.077057211283323, 10.706667262420716, 9.341451094646674,
         8.122270764822368, 7.671593316397699, 7.697000470802994,
         7.530680469875164, 7.720180133976149, 7.59900173760075,
         13.111791693551362, 10.711047679739433, 9.339770955175847,
         8.117021359757253, 7.727537757463738, 7.654072928976537,
         7.607359118625173, 7.602197791148399, 7.596844236081228
     ], 3, 3])
示例#3
0
square_alphas = [
    0.0015625, 0.003125, 0.00625, 0.0125, 0.025, 0.05, 0.1, 0.15, 0.2, 0.25,
    0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.6, 0.65, 0.7, 0.75, 0.8, 0.85, 0.9, 1.
]
square_Ks = [
    1024000., 256000, 64000, 16000, 4000, 1000., 250., 85., 52., 30., 17., 11.,
    7.7, 5.5, 3.8, 2.8, 2, 1.5, 1.1, 0.78, 0.53, 0.35, 0.08, 0.
]

grills_rounded_alphas = [0.3, 0.4, 0.5, 0.6, 0.7]
grills_rounded_Ks = [2.0, 1.0, 0.6, 0.4, 0.2]
'''Cubic interpolation with no smoothing, constant value extremities
returned when outside table limits'''
grills_rounded_tck = implementation_optimize_tck(
    [[0.3, 0.3, 0.3, 0.45, 0.55, 0.7, 0.7, 0.7],
     [
         2.0, 1.0014285714285716, 0.5799999999999998, 0.3585714285714287, 0.2,
         0.0, 0.0, 0.0
     ], 2])


def round_edge_screen(alpha, Re, angle=0.0):
    r'''Returns the loss coefficient for a round edged wire screen or bar
    screen, as shown in [1]_. Angle of inclination may be specified as well.

    Parameters
    ----------
    alpha : float
        Fraction of screen open to flow [-]
    Re : float
        Reynolds number of flow through screen with D = space between rods, []
    angle : float, optional
示例#4
0
'''Quadratic interpolation with no smoothing, constant value extremities
returned when outside table limits'''

'''Quadratic interpolation with no smoothing, constant value extremities
returned when outside table limits. Last actual value in the original table is
K=1000 at alpha=0.05; the rest are extrapolated.'''
square_alphas = [0.0015625, 0.003125, 0.00625, 0.0125, 0.025, 0.05, 0.1, 0.15, 0.2, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.6, 0.65, 0.7, 0.75, 0.8, 0.85, 0.9, 1.]
square_Ks = [1024000., 256000, 64000, 16000, 4000, 1000., 250., 85., 52., 30., 17., 11., 7.7, 5.5, 3.8, 2.8, 2, 1.5, 1.1, 0.78, 0.53, 0.35, 0.08, 0.]


grills_rounded_alphas = [0.3, 0.4, 0.5, 0.6, 0.7]
grills_rounded_Ks = [2.0, 1.0, 0.6, 0.4, 0.2]
'''Cubic interpolation with no smoothing, constant value extremities
returned when outside table limits'''
grills_rounded_tck = implementation_optimize_tck([[0.3, 0.3, 0.3, 0.45, 0.55, 0.7, 0.7, 0.7], 
                                                  [2.0, 1.0014285714285716, 0.5799999999999998, 
                                                   0.3585714285714287, 0.2, 0.0, 0.0, 0.0],
                                                   2])


def round_edge_screen(alpha, Re, angle=0):
    r'''Returns the loss coefficient for a round edged wire screen or bar
    screen, as shown in [1]_. Angle of inclination may be specified as well.

    Parameters
    ----------
    alpha : float
        Fraction of screen open to flow [-]
    Re : float
        Reynolds number of flow through screen with D = space between rods, []
    angle : float, optional
        Angle of inclination, with 0 being straight and 90 being parallel to
示例#5
0
]
Bhirud_normal_lnU0s = [
    -1.6198, -1.604, -1.59, -1.578, -1.564, -1.548, -1.533, -1.515, -1.489,
    -1.454, -1.425, -1.243
]
Bhirud_normal_lnU1 = [
    -0.4626, -0.459, -0.451, -0.441, -0.428, -0.412, -0.392, -0.367, -0.337,
    -0.302, -0.283, -0.2629
]

Bhirud_normal_lnU0_tck = implementation_optimize_tck(
    [[
        0.98, 0.98, 0.98, 0.98, 0.984, 0.986, 0.988, 0.99, 0.992, 0.994, 0.996,
        0.998, 1.0, 1.0, 1.0, 1.0
    ],
     [
         -1.6198000000000001, -1.6090032590995371, -1.5930934818009272,
         -1.5785097772986094, -1.5645133351302174, -1.547436882180519,
         -1.5337391361477044, -1.5156065732286643, -1.4938345709376377,
         -1.4430551430207872, -1.4529816189930713, -1.243, 0.0, 0.0, 0.0, 0.0
     ], 3])
Bhirud_normal_lnU1_tck = implementation_optimize_tck(
    [[
        0.98, 0.98, 0.98, 0.98, 0.984, 0.986, 0.988, 0.99, 0.992, 0.994, 0.996,
        0.998, 1.0, 1.0, 1.0, 1.0
    ],
     [
         -0.4626000000000001, -0.4624223420145324, -0.4543553159709354,
         -0.4416003593769303, -0.4284319856698448, -0.41267169794369013,
         -0.39288122255539465, -0.3678034118347314, -0.3379051301056794,
         -0.30257606774255136, -0.2767190885302606, -0.2629, 0.0, 0.0, 0.0, 0.0
示例#6
0
__all__ = ['v_Sounders_Brown', 'K_separator_Watkins',
           'K_separator_demister_York', 'K_Sounders_Brown_theoretical']


# 92 points taken from a 2172x3212 page scan, after dewarping the scan,
# digitization with Engauge Digitizer, and extensive checking; every 5th point 
# it produced was selected plus the last point. The initial value is adjusted 
# to be the lower limit of the graph.


tck_Watkins = implementation_optimize_tck([[-5.115995809754082, -5.115995809754082, -5.115995809754082,
                                            -5.115995809754082, -4.160106231099973, -3.209113630523477,
                                            -1.2175106961204154, 0.4587657198189318, 1.1197669427405068,
                                            1.6925908552310418, 1.6925908552310418, 1.6925908552310418,
                                            1.6925908552310418],
                                        [-1.4404286048266364, -1.2375168139385286, -0.9072614905522024,
                                         -0.7662335745829165, -0.944537665617708, -1.957339717378027,
                                         -3.002614318094637, -3.5936804378352956, -3.8779153181940553,
                                         0.0, 0.0, 0.0, 0.0],
                                         3])
                            
def K_separator_Watkins(x, rhol, rhog, horizontal=False, method='spline'):
    r'''Calculates the Sounders-Brown `K` factor as used in determining maximum 
    allowable gas velocity in a two-phase separator in either a horizontal or
    vertical orientation. This function approximates a graph published in [1]_ 
    to determine `K` as used in the following equation:
    
    .. math::
        v_{max} =  K_{SB}\sqrt{\frac{\rho_l-\rho_g}{\rho_g}}
    
    The graph has `K_{SB}` on its y-axis, and the following as its x-axis: