示例#1
0
# Analyse

zmin, zmax = mdl.node_bounds()[2]
nodes_top = [i for i, node in mdl.nodes.items() if node.z > zmax - 0.010]
nodes_bot = [i for i, node in mdl.nodes.items() if node.z < zmin + 0.010]

mdl.add_set(name='nset_top', type='node', selection=nodes_top)
mdl.add_set(name='nset_bot', type='node', selection=nodes_bot)

#print(mdl.sets['nset_top'])
#print(mdl.sets['nset_bot'])

mdl.add([
    ElasticIsotropic(name='mat_elastic', E=50 * 10**9, v=0.3, p=1),
    SolidSection(name='sec_solid'),
    ElementProperties(name='ep_tets',
                      material='mat_elastic',
                      section='sec_solid',
                      elset='mesh_tets'),
    PinnedDisplacement(name='disp_pinned', nodes='nset_bot'),
    PointLoad(name='load_top', nodes='nset_top', y=20000, z=10000),
    GeneralStep(name='step_bc', displacements='disp_pinned'),
    GeneralStep(name='step_load', loads='load_top'),
])
mdl.steps_order = ['step_bc', 'step_load']

mdl.summary()

mdl.analyse_and_extract(software='abaqus', fields=['u', 's'])
示例#2
0
# Tetrahedrons

mesh = rs.ObjectsByLayer('base_mesh')[0]
rhino.add_tets_from_mesh(mdl, name='elset_tets', mesh=mesh, volume=10**(-4))

# Sets

rhino.add_sets_from_layers(mdl, layers=['nset_base', 'nset_top'])

# Materials

mdl.add(ElasticIsotropic(name='mat_elastic', E=10 * 10**9, v=0.3, p=1))

# Sections

mdl.add(SolidSection(name='sec_solid'))

# Properties

mdl.add(
    Properties(name='ep_tets',
               material='mat_elastic',
               section='sec_solid',
               elset='elset_tets'))

# Displacementss

mdl.add(PinnedDisplacement(name='disp_pinned', nodes='nset_base'))

# Loads
# add supports --------------------------------------------------------------

nkeys = list(volmesh.vertices_where({'z': 0}))
s.add_set(name='support_nodes', type='NODE', selection=nkeys)
supppots = FixedDisplacement(name='supports', nodes='support_nodes')
s.add_displacement(supppots)

# add materials and sections -----------------------------------------------
E = 35 * 10**9
v = .02
p = 2400
matname = 'concrete'
concrete = ElasticIsotropic(name=matname, E=E, v=v, p=p)
s.add_material(concrete)
section = SolidSection(name='concrete_sec')
s.add_section(section)
prop = ElementProperties(name='floor',
                         material=matname,
                         section='concrete_sec',
                         elsets=['solids'])
s.add_element_properties(prop)

# add gravity load -------------------------------------------------------------

s.add_load(GravityLoad(name='load_gravity', elements=['shell']))

# add steps --------------------------------------------------------------------

step = GeneralStep(name='gravity_step',
                   nlgeom=False,