Пример #1
0
 def test_stiffeners_everywhere(self):
     initial_cs = create_initial_cs(4000, 4000, 2000, 20, 20, 20)
     stiffener_1 = st.create_stiffener_global(1, 1, 1000, 0, 0, 300, 200,
                                              200, 15)
     stiffener_2 = st.create_stiffener_global(1, 2, -1000, 0, 0, 300, 200,
                                              200, 15)
     stiffener_3 = st.create_stiffener_global(2, 3, -2000, 1000,
                                              3 * math.pi / 2, 200, 100,
                                              100, 10)
     stiffener_4 = st.create_stiffener_global(3, 4, -1000, 2000, math.pi,
                                              300, 200, 200, 15)
     stiffener_5 = st.create_stiffener_global(3, 5, 1000, 2000, math.pi,
                                              300, 200, 200, 15)
     stiffener_6 = st.create_stiffener_global(4, 6, 2000, 1000, math.pi / 2,
                                              200, 100, 100, 10)
     stiffeners = [
         stiffener_1, stiffener_2, stiffener_3, stiffener_4, stiffener_5,
         stiffener_6
     ]
     final_cs = merge.merge(initial_cs, stiffeners)
     length = len(final_cs.lines)
     self.assertEqual(length, 34)
     last_line = final_cs.get_line(tpl_number=16)
     code_16 = plcd.plate_code(4, 0, 16, 0, 0)
     self.assertEqual(last_line.code, code_16)
Пример #2
0
 def test_empty(self):
     initial_cs = create_initial_cs(4000, 3000, 2000, 20, 20, 20)
     stiffeners = []
     final_cs = merge.merge(initial_cs, stiffeners)
     length = len(final_cs.lines)
     line_4 = final_cs.get_line(pl_type=0, pl_position=4, tpl_number=4)
     code_4 = plcd.plate_code(4, 0, 4, 0, 0)
     self.assertEqual(length, 4)
     self.assertEqual(line_4.code, code_4)
Пример #3
0
 def test_stiffeners_top(self):
     initial_cs = create_initial_cs(4000, 3000, 2000, 20, 20, 20)
     stiffener_1 = st.create_stiffener_global(1, 1, 1000, 0, 0, 300, 200,
                                              200, 15)
     stiffener_2 = st.create_stiffener_global(1, 2, -1000, 0, 0, 300, 200,
                                              200, 15)
     stiffeners = [stiffener_1, stiffener_2]
     final_cs = merge.merge(initial_cs, stiffeners)
     length = len(final_cs.lines)
     self.assertEqual(length, 14)
     stiffener_1_line_3 = final_cs.get_line(st_number=1, st_pl_position=3)
     st_1_3_length = stiffener_1_line_3.get_length_tot()
     self.assertEqual(st_1_3_length, 200)
     line_top_right = final_cs.get_line(tpl_number=5)
     code_5 = plcd.plate_code(1, 0, 5, 0, 0)
     self.assertEqual(line_top_right.code, code_5)
     self.assertEqual(line_top_right.a.y, -1150)
Пример #4
0
from classes import plate_code as plcd
from classes import merge
from classes import crosssection as cs
from proofs import global_plate_buckling as glb
import data
import math

data.input_data.update({"M_Ed": -45000 * 10**6})

initial_cs = ics.create_initial_cs(4000, 3000, 2000, 10, 10, 5)
stiffener_1 = st.create_stiffener_global(3, 1, -1000, 2000, math.pi, 200, 150,
                                         100, 5)
stiffener_2 = st.create_stiffener_global(3, 2, 1000, 2000, math.pi, 200, 150,
                                         100, 5)

stiffener_list = [stiffener_1, stiffener_2]
final_cs = merge.merge(initial_cs, stiffener_list)
final_cs = initial_cs

point_a = pt.point(-1500, 2000)
point_b = pt.point(1500, 2000)
code = plcd.plate_code(3, 0, 3, 0, 0)
plate = ln.line(code, point_a, point_b, 5)
x_sec = ics.create_initial_cs(4000, 3000, 2000, 10, 10, 5)
stiffened_plate = merge.merge(x_sec, stiffener_list)
x_sec.lines.remove(x_sec.get_line(pl_position=1, pl_type=0))
x_sec.lines.remove(x_sec.get_line(pl_position=2, pl_type=0))
x_sec.lines.remove(x_sec.get_line(pl_position=4, pl_type=0))

glb.global_plate_buckling(final_cs, stiffened_plate)
Пример #5
0
import sys
#just add the directory where the BA folder is on your computer
sys.path.append('C:/Users/Nino/Google Drive/Studium/FS 2021/Bachelorarbeit/BA')
sys.path.append('C:/Users/Nino/Google Drive/Studium/FS 2021/Bachelorarbeit/BA/ebplate')

import initial_cs as ics
from proofs import global_buckling as globb
from proofs import local_buckling as locb
from output import geometry_output as go
import data
import deck
from classes import merge
from classes import stiffener as st
from proofs import buckling_proof

data.input_data.update({"b_inf": 3000})
data.input_data.update({"b_sup": 4000})
data.input_data.update({"h": 1500})
data.input_data.update({"M_Ed": 50*10**9})
data.input_data.update({"Q_Ed": 1000})
data.input_data.update({"T_Ed": 1000})
data.input_data.update({"a": 1000})
data.input_data.update({"L_e": 1000})
data.input_data.update({"bending type": "sagging bending"})
data.input_data.update({"cs position": 1000})
initial_cs = ics.create_initial_cs(4000, 3000, 1500, 4, 4, 4)
deck_stiffeners = deck.deck(4000)
stiffened_cs = merge.merge(initial_cs, deck_stiffeners)
buckling_proof.buckling_proof(stiffened_cs)
Пример #6
0
from output import geometry_output as go
from classes import point as pt
from classes import line as ln
from classes import plate_code as plcd
from classes import crosssection as cs
from classes import merge
import deck

initial_cs = ics.create_initial_cs(4000, 4000, 2000, 20, 20, 20)

st_list_deck = deck.deck(4000)

s = len(st_list_deck)

stiffener_1 = st.create_stiffener_global(2, s+1, -2000, 1000, 3*math.pi/2, 200, 100, 100, 10)
stiffener_2 = st.create_stiffener_global(3, s+2, -1000, 2000, math.pi, 300, 200, 200, 15)
stiffener_3 = st.create_stiffener_global(3, s+3, 1000, 2000, math.pi, 300, 200, 200, 15)
stiffener_4 = st.create_stiffener_global(4, s+4, 2000, 1000, math.pi/2, 200, 100, 100, 10)


st_list_rest = [stiffener_1, stiffener_2, stiffener_3, stiffener_4]

st_list = st_list_deck + st_list_rest

print(len(st_list))

final_cs = merge.merge(initial_cs, st_list)
print(final_cs)
print(len(final_cs.lines))
go.print_cs_red(final_cs)
Пример #7
0
from classes import proposed_stiffener
from classes import crosssection
from classes import merge
import deck
import data
import defaults

defaults.set_cs_defaults()
defaults.set_forces_defaults()

cs = initial_cs.create_initial_cs(data.input_data.get("b_sup"),
                                  data.input_data.get("b_inf"),
                                  data.input_data.get("h"), 20, 20, 20)
geometry_output.print_cs_red(cs)
deck_stiffeners = deck.deck(data.input_data.get("b_sup"))
cs = merge.merge(cs, deck_stiffeners)
geometry_output.print_cs_red(cs)

prop_list = stiffeners_proposition.stiffeners_proposition()
#propose stiffeners, mimicking input from optimizer

prop_1 = proposed_stiffener.proposed_stiffener(2, 1, 0.5, 10**7)
prop_list.add(prop_1)

#prop_2 = ps.proposed_stiffener(2, 2, 0.3, 10**7)
#prop_list.add(prop_2)
prop_3 = proposed_stiffener.proposed_stiffener(3, 2, -0.7, 10**7)
prop_list.add(prop_3)
prop_4 = proposed_stiffener.proposed_stiffener(3, 3, 0.7, 10**7)
prop_list.add(prop_4)
#prop_5 = ps.proposed_stiffener(4, 5, 0.3, 10**7)
Пример #8
0
#assign input to variables
b_sup = 4000 #data.input_data["b_sup"]
b_inf = 2000 #data.input_data["b_inf"]
h = 1500 #data.input_data["h"]
t_side = 10
t_deck = 10
t_bottom = 10

#create initial cross section with t=20mm
test_cs = ics.create_initial_cs(b_sup, b_inf, h, t_side, t_deck, t_bottom)
for line in test_cs.lines:
    line.t = 20

deck_stiffeners = deck.deck(b_sup)
test_cs = merge.merge(test_cs, deck_stiffeners)

prop_list = st_prop.stiffeners_proposition()
#propose stiffeners, mimicking input from optimizer

prop_1 = ps.proposed_stiffener(2, 1, 0.8, 10**7)
prop_list.add(prop_1)

#prop_2 = ps.proposed_stiffener(2, 2, 0.3, 10**7)
#prop_list.add(prop_2)
#prop_3 = ps.proposed_stiffener(3, 3, -0.8, 10**7)
#prop_list.add(prop_3)
#prop_4 = ps.proposed_stiffener(3, 4, 0.8, 10**7)
#prop_list.add(prop_4)
#prop_5 = ps.proposed_stiffener(4, 5, 0.3, 10**7)
#prop_list.add(prop_5)