Example #1
0
def test_structural__crimped_simplesupported_simplesupported_beam():
    material = Material(E=1, poisson=0.3, alpha=1)
    section = Rectangle(12, 1)
    f1 = Load.PontualLoad(-200, x=700)
    n1 = Node.Crimp(x=0)
    n2 = Node.SimpleSupport(x=1000)
    n3 = Node.SimpleSupport(x=1500)
    bar1 = BeamElement([n1, n2], section, material)
    bar2 = BeamElement([n2, n3], section, material)
    beam = Beam(
        loads=[f1],
        beam_elements=[bar1, bar2],
    )
    support_reaction = beam.nodal_efforts
    assert support_reaction[0] == approx(60.8, abs=0.1)
    assert support_reaction[1] == approx(18480, abs=0.1)
    assert support_reaction[-4] == approx(174.4, abs=0.1)
    assert support_reaction[-3] == approx(0, abs=0.1)
    assert support_reaction[-2] == approx(-35.30, abs=10)
    assert support_reaction[-1] == approx(0, abs=0.1)

    assert beam.getInternalShearStrength(100) == approx(60.8, abs=0.1)
    assert beam.getInternalShearStrength(800) == approx(-139.2, abs=0.1)
    assert beam.getInternalShearStrength(1200) == approx(35.3, abs=0.1)
    assert beam.getInternalMomentumStrength(e) == approx(-18480, abs=1)
    assert beam.getInternalMomentumStrength(100) == approx(-12400, abs=10)
    assert beam.getInternalMomentumStrength(800) == approx(10190, abs=10)
    assert beam.getInternalMomentumStrength(1200) == approx(-10580, abs=10)
    assert beam.getInternalMomentumStrength(1500 - e) == approx(0, abs=10)
Example #2
0
def create_simple_beam():
    material = Material(E=1, poisson=0.3, alpha=1)
    section = Rectangle(12, 1)
    f1 = Load.PontualLoad(-1, x=500)
    n1 = Node.SimpleSupport(x=0)
    n2 = Node.SimpleSupport(x=1000)
    bar1 = BeamElement([n1, n2], section, material)
    return Beam(loads=[f1], beam_elements=[bar1], solve_structural=False)
Example #3
0
def test_simple_simple_simple():
    base, altura, comprimento = 57, 107, 1100
    pp = Load.UniformDistributedLoad(-0.1375, x_begin=0, x_end=comprimento)

    n1 = Node.SimpleSupport(x=0)
    n2 = Node.SimpleSupport(x=comprimento / 2)
    n3 = Node.SimpleSupport(x=comprimento)

    be1 = BeamElement([n1, n2], Rectangle(base, altura), Material(10000, 1, 1))
    be2 = BeamElement([n2, n3], Rectangle(base, altura), Material(10000, 1, 1))

    beam = Beam(loads=[pp], beam_elements=[be1, be2])
    compare(beam=beam, name="simple_simple_simple")
Example #4
0
def test_crimped_free():
    material = Material(E='27000 MPa', poisson=1, alpha=1)
    section = Rectangle(25, 44.6)

    f1 = Load.UniformDistributedLoad(-0.1622, x_begin=0, x_end=113)

    n1 = Node.Crimp(x=0)
    n2 = Node.Free(x=113)

    bar1 = BeamElement([n1, n2], section, material)

    beam = Beam(loads=[f1], beam_elements=[bar1])
    compare(beam=beam, name="crimped_free", ftool_displacement_in_mm=True)
Example #5
0
def test_simple_simple_simple_partial_load():
    base, altura, comprimento = 57, 107, 1100
    pp = Load.UniformDistributedLoad(-0.1375, x_begin=250, x_end=600)

    n1 = Node.SimpleSupport(x=0)
    n2 = Node.SimpleSupport(x=comprimento / 2)
    n3 = Node.SimpleSupport(x=comprimento)

    be1 = BeamElement([n1, n2], Rectangle(base, altura), Material(10000, 1, 1))
    be2 = BeamElement([n2, n3], Rectangle(base, altura), Material(10000, 1, 1))

    beam = Beam(loads=[pp], beam_elements=[be1, be2])
    compare(beam=beam, name="simple_simple_simple_partial_load")


#for x, ft, fc in zip(x_momentum, momentum_diagram_ftool, momentum_fconcrete):
#    if ft != approx(fc, abs=0.000001):
#        print(x, ft, fc)
Example #6
0
def test_structural__crimped_simple_supported_beam():
    material = Material(E=1, poisson=0.3, alpha=1)
    section = Rectangle(12, 1)
    f1 = Load.PontualLoad(-200, x=700)
    n1 = Node.Crimp(x=0)
    n2 = Node.SimpleSupport(x=1000)
    bar1 = BeamElement([n1, n2], section, material)
    beam = Beam(loads=[f1], beam_elements=[bar1])
    support_reaction = beam.nodal_efforts
    assert support_reaction[0] == approx(87.3, abs=0.1)
    assert support_reaction[1] == approx(27300, abs=10)
    assert support_reaction[-2] == approx(112.7, abs=0.1)
    assert support_reaction[-1] == approx(0, abs=10)
    assert beam.getInternalShearStrength(100) == approx(87.3, abs=0.1)
    assert beam.getInternalShearStrength(800) == approx(-112.7, abs=0.1)
    assert beam.getInternalMomentumStrength(e) == approx(-27300, abs=10)
    assert beam.getInternalMomentumStrength(100) == approx(-18570, abs=10)
    assert beam.getInternalMomentumStrength(800) == approx(+22540, abs=10)
    assert beam.getInternalMomentumStrength(1000 - e) == approx(0, abs=10)
Example #7
0
def test_v47():
    material = Material(E='27000 MPa', poisson=1, alpha=1)
    section = Rectangle(25, 44.6)

    f1 = Load.UniformDistributedLoad(-0.1622, x_begin=0, x_end=113)
    f2 = Load.UniformDistributedLoad(-0.4994, x_begin=113, x_end=583)
    f3 = Load.UniformDistributedLoad(-0.4196, x_begin=583, x_end=1188)

    n1 = Node.SimpleSupport(x=0)
    n2 = Node.SimpleSupport(x=113)
    n3 = Node.SimpleSupport(x=583)
    n4 = Node.SimpleSupport(x=1188)

    bar1 = BeamElement([n1, n2], section, material)
    bar2 = BeamElement([n2, n3], section, material)
    bar3 = BeamElement([n3, n4], section, material)

    beam = Beam(loads=[f1, f2, f3], beam_elements=[bar1, bar2, bar3])
    compare(beam=beam, name="v47", ftool_displacement_in_mm=True)
Example #8
0
def test_structural_double_crimped_beam():
    material = Material(E=1, poisson=0.3, alpha=1)
    section = Rectangle(12, 1)
    f1 = Load.PontualLoad(-200, x=200)
    n1 = Node.Crimp(x=0)
    n2 = Node.Crimp(x=1000)
    bar1 = BeamElement([n1, n2], section, material)
    beam = Beam(loads=[f1], beam_elements=[bar1])
    support_reaction = beam.nodal_efforts
    assert support_reaction[0] == approx(179.2, abs=0.1)
    assert support_reaction[1] == approx(25600, abs=10)
    assert support_reaction[-2] == approx(20.8, abs=0.1)
    assert support_reaction[-1] == approx(-6400, abs=10)
    assert beam.getInternalShearStrength(150) == approx(179.2, abs=0.1)
    assert beam.getInternalShearStrength(300) == approx(-20.8, abs=0.1)
    assert beam.getInternalMomentumStrength(e) == approx(-25600, abs=10)
    assert beam.getInternalMomentumStrength(200) == approx(+10240, abs=10)
    assert beam.getInternalMomentumStrength(170) == approx(4860, abs=10)
    assert beam.getInternalMomentumStrength(210) == approx(10030, abs=10)
    assert beam.getInternalMomentumStrength(1000 - e) == approx(-6400, abs=10)