コード例 #1
0
    GravityLoad(name='load_gravity', elements='elset_beams'),
])

# print('load_point components: ', mdl.loads['load_point'].components)

# Add displacements

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

# print('disp_pinned components: ', mdl.displacements['disp_pinned'].components)

# Add steps

mdl.add([
    GeneralStep(name='step_bc', displacements=['disp_pinned']),
    GeneralStep(name='step_loads', loads=['load_point', 'load_gravity']),
])
mdl.steps_order = ['step_bc', 'step_loads']

# Structure summary

mdl.summary()

# Generate input files

mdl.write_input_file(software='abaqus', fields=['s', 'u'])

# Launch App

mdl.view()
コード例 #2
0
    Properties(name='ep_concrete',
               material='mat_concrete',
               section='sec_concrete',
               elset='elset_concrete'))

# Displacements

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

# Steps

mdl.add([
    GeneralStep(name='step_bc', displacements=['disp_pinned']),
    ModalStep(name='step_modal', modes=5),
])
mdl.steps_order = ['step_bc', 'step_modal']

# Summary

mdl.summary()

# Run

mdl.analyse_and_extract(software='opensees', fields=['u'])

print(mdl.results['step_modal']['frequencies'])

mdl.save_to_obj()

mdl.view(mode='1')  # temp hack