예제 #1
0
def test_grashof():

    ambient_temperature = 40
    conductor_temperature = 100
    elevation = 0

    tf = cigre601.temperature_film(conductor_temperature, ambient_temperature)
    gr = cigre601.grashof(
        conductor.drake_constants,
        conductor_temperature,
        ambient_temperature,
        tf,
        elevation,
    )

    assert gr == pytest.approx(96.95e3, abs=0.01e3)

    ambient_temperature = 20
    elevation = 500

    tf = cigre601.temperature_film(conductor_temperature, ambient_temperature)
    gr = cigre601.grashof(
        conductor.drake_constants_example_b,
        conductor_temperature,
        ambient_temperature,
        tf,
        elevation,
    )

    assert gr == pytest.approx(131e3, abs=0.1e3)
예제 #2
0
def test_dynamic_viscosity():
    ambient_temperature = 40
    conductor_temperature = 100

    tf = cigre601.temperature_film(conductor_temperature, ambient_temperature)
    v = cigre601.dynamic_viscosity(tf)
    assert v == pytest.approx(20.384e-6, abs=0.001e-6)

    ambient_temperature = 20

    tf = cigre601.temperature_film(conductor_temperature, ambient_temperature)
    v = cigre601.dynamic_viscosity(tf)
    assert v == pytest.approx(1.9947e-5, abs=0.0001e-5)
예제 #3
0
def test_thermal_conductivity_of_air():
    ambient_temperature = 40
    conductor_temperature = 100

    tf = cigre601.temperature_film(conductor_temperature, ambient_temperature)
    c = cigre601.thermal_conductivity_of_air(tf)
    assert c == pytest.approx(0.0286, abs=0.0001)

    ambient_temperature = 20

    tf = cigre601.temperature_film(conductor_temperature, ambient_temperature)
    c = cigre601.thermal_conductivity_of_air(tf)
    assert c == pytest.approx(0.0279, abs=0.0001)
예제 #4
0
def test_prandtl():

    ambient_temperature = 40
    conductor_temperature = 100

    tf = cigre601.temperature_film(conductor_temperature, ambient_temperature)
    pr = cigre601.prandtl(conductor.drake_constants, conductor_temperature, tf)

    assert pr == pytest.approx(0.716, abs=0.001)

    ambient_temperature = 20
    conductor_temperature = 100

    tf = cigre601.temperature_film(conductor_temperature, ambient_temperature)
    pr = cigre601.prandtl(conductor.drake_constants, conductor_temperature, tf)

    assert pr == pytest.approx(0.718, abs=0.001)
예제 #5
0
def test_nusselt_number():

    ambient_temperature = 40
    conductor_temperature = 100
    wind_speed = 0.61
    angle_of_attack = 60
    elevation = 0

    tf = cigre601.temperature_film(conductor_temperature, ambient_temperature)
    Re = cigre601.reynolds_number(wind_speed, conductor.drake_constants, tf,
                                  elevation)

    Nu = cigre601.nusselt_number = nusselt.get_nusselt_function(
        conductor.drake_constants)(Re, 90)

    assert Nu == pytest.approx(15.495, abs=0.001)

    Nu = cigre601.nusselt_number = nusselt.get_nusselt_function(
        conductor.drake_constants)(Re, angle_of_attack)

    assert Nu == pytest.approx(14.40, abs=0.01)

    ambient_temperature = 20
    wind_speed = 1.66
    angle_of_attack = 80
    elevation = 500

    tf = cigre601.temperature_film(conductor_temperature, ambient_temperature)
    Re = cigre601.reynolds_number(wind_speed, conductor.drake_constants, tf,
                                  elevation)

    Nu = cigre601.nusselt_number = nusselt.get_nusselt_function(
        conductor.drake_constants)(Re, 90)

    assert Nu == pytest.approx(24.73, abs=0.01)

    Nu = cigre601.nusselt_number = nusselt.get_nusselt_function(
        conductor.drake_constants)(Re, angle_of_attack)

    assert Nu == pytest.approx(24.53, abs=0.01)
예제 #6
0
def test_reynolds_number():

    ambient_temperature = 40
    conductor_temperature = 100
    wind_speed = 0.61
    elevation = 0

    tf = cigre601.temperature_film(conductor_temperature, ambient_temperature)
    Re = cigre601.reynolds_number(wind_speed, conductor.drake_constants, tf,
                                  elevation)

    assert Re == pytest.approx(865, abs=0.5)

    ambient_temperature = 20
    wind_speed = 1.66
    elevation = 500

    tf = cigre601.temperature_film(conductor_temperature, ambient_temperature)
    Re = cigre601.reynolds_number(wind_speed, conductor.drake_constants, tf,
                                  elevation)

    assert Re == pytest.approx(2335, abs=0.5)