Exemplo n.º 1
0
from aeropy.geometry.parametric import CoordinateSystem
from aeropy.structural.shell import shell
from aeropy.structural.stable_solution import (mesh_1D, properties,
                                               boundary_conditions,
                                               euler_bernoulle)
from optimization_tools.DOE import DOE
import matplotlib.pyplot as plt
import matplotlib.cm as cm
import numpy as np
import pickle
import math

bp = properties()
bc = boundary_conditions(concentrated_load=np.array([[0, 0, -1], ]))
# bc = boundary_conditions(distributed_load=1)

abaqus_data = pickle.load(open('curved_neutral_line.p', 'rb'))

# Define parent and child geometries
chord_parent = math.sqrt(3)

curve_parent = CoordinateSystem.cylindrical([2], chord = chord_parent, color = 'b')
curve_child = CoordinateSystem.cylindrical([2], chord = chord_parent, color = 'g')

# Define shell
beam = shell(curve_parent, curve_child, bp, bc)

# Setting mesh and bounds
bounds =  [[.001, beam.g_c.D[0]],]
beam.calculate_chord(bounds = bounds)
beam.theta1 = np.linspace(0, beam.g_p.arclength()[0], 10)
Exemplo n.º 2
0
import pickle


def input_function(x):
    return np.array([0, 0] + list(x))


np.set_printoptions(precision=5)

# Results from Abaqus
abaqus_data = pickle.load(open('neutral_line.p', 'rb'))

# Beam properties
bp = properties()
bc = boundary_conditions(load=np.array([
    [0, -1],
]))
EB_solution = bc.concentrated_load[0][1]/(6*bp.young*bp.inertia) * \
    np.array([0, 0, 3, -1])

mesh = mesh_1D(mesh_n=11, alpha=[1, 1], alpha_nodes=[0, 1])
curve_parent = poly(a=[0, 0, 0, 0])
curve_child = poly(a=EB_solution)

beam = structure(curve_parent, curve_child, mesh, bp, bc)
beam.calculate_position()
eulerBernoulle = beam.r_c

# Find stable solution
bounds = np.array(((-0.02, 0.02), (-0.02, 0.02)))
Exemplo n.º 3
0
bp = properties(young=194.3e9, dimensions=[width, thickness])
exp_F = [0.000, 0.098, 0.196, 0.294, 0.392, 0.490, 0.588]
exp_delta = [0.089, 0.149, 0.195, 0.227, 0.251, 0.268, 0.281]

bounds_opt = np.array([[-3, -1.0], [1, 2]])

curve_parent = CoordinateSystem.polynomial(experiment[0], chord_parent, 'b')

colors = ['0.0', '0.3', '0.5', '0.7']
loads = list(experiment.keys())
span_num = []

for i in range(len(loads)):
    load = loads[i]
    bc = boundary_conditions(concentrated_load=np.array([
        [0, 0, -load],
    ]),
                             load_x=[chord_parent])
    curve_child = CoordinateSystem.polynomial(experiment[load],
                                              chord_parent,
                                              color='g')

    # Define shell
    beam = shell(curve_parent, curve_child, bp, bc)

    # Kinematics
    bounds = np.array([
        [0, 1.5 * chord_parent],
    ])
    beam.calculate_chord(bounds=bounds)
    beam.theta1 = np.linspace(0, beam.g_p.arclength()[0], 20)
    beam.g_p.bounds = bounds
Exemplo n.º 4
0
from aeropy.geometry.parametric import polynomial
from aeropy.structural.shell import shell
from aeropy.structural.stable_solution import (mesh_1D, properties,
                                               boundary_conditions,
                                               euler_bernouille)
from optimization_tools.DOE import DOE
import matplotlib.pyplot as plt
import matplotlib.cm as cm
import numpy as np

bp = properties()
# bc = boundary_conditions(concentrated_load=np.array([[0, 0, -1], ]))
bc = boundary_conditions(distributed_load=1)

# Define parent and child geometries
straight = np.array([0, 0, 0, 0])
eulerBernoulle = euler_bernouille()
chord_parent = 1

curve_parent = polynomial(np.copy(straight), chord_parent, color='b')
curve_child = polynomial(np.copy(eulerBernoulle), color='g')

# Define shell
beam = shell(curve_parent, curve_child, bp, bc)

# Kinematics
beam.calculate_chord()
theta_1 = np.linspace(0, 1, 10)
beam.g_p.calculate_x1(theta_1)
beam.g_c.calculate_x1(theta_1)
beam.g_p.basis()
Exemplo n.º 5
0
from aeropy.geometry.parametric import poly
from aeropy.structural.stable_solution import (structure, mesh_1D, properties,
                                               boundary_conditions)
import matplotlib.pyplot as plt
import matplotlib.cm as cm
import numpy as np

coefficients = np.array([0, 0, 0, 0])

beam_properties = properties()
bc = boundary_conditions()
analytical_solution = bc.concentrated_load[0][0] / (beam_properties.young *
                                                    beam_properties.area)

mesh = mesh_1D(alpha=[1 + analytical_solution, 1 + analytical_solution],
               alpha_nodes=[0, 1],
               mesh_n=10)
curve_parent = poly(coefficients)
curve_child = poly(coefficients)

beam = structure(curve_parent, curve_child, mesh, beam_properties, bc)
strain = beam.strain()
stress = beam.stress()

n = 21
strain_list = analytical_solution * np.linspace(0, 2, n)
strain_matrix = np.array(list(zip(strain_list, strain_list)))
strain_x = np.linspace(0, 1, n)
strain_x = np.array(list(zip(strain_list, strain_x)))
energy, residual = beam.sweep_strains(strain_matrix, strain_x)