mdl.add_node(xyz=[-5., -5., 0.]) mdl.add_nodes(nodes=[[5., -5., 0.], [5., 5., 0.], [-5., 5., 0.], [0., 0., 5.]]) # print('Node number 3:', mdl.nodes[3]) # print('Node number 3 xyz:', mdl.node_xyz(3)) # print('Node count: ', mdl.node_count()) # print('Node index: ', mdl.node_index) # print('Check node at [0, 0, 0]: ', mdl.check_node_exists([0, 0, 0])) # print('Check node at [5, 5, 0]: ', mdl.check_node_exists([5, 5, 0])) # print('Node bounds: ', mdl.node_bounds()) # Add elements mdl.add_elements(elements=[[0, 4], [1, 4], [2, 4], [3, 4]], type='BeamElement', axes={'ex': [1, 0, 0]}) mdl.add_element(nodes=[0, 1, 4], type='ShellElement') # print('Element 3 nodes: ', mdl.elements[3].nodes) # print('Element count: ', mdl.element_count()) # print('Element index: ', mdl.element_index) # print('Check element with nodes 1-4: ', mdl.check_element_exists([1, 4])) # print('Check element with nodes 0-1: ', mdl.check_element_exists([0, 1])) # Add sets mdl.add_set(name='nset_base', type='node', selection=[0, 1, 2, 3]) mdl.add_set(name='nset_top', type='node', selection=[4]) mdl.add_set(name='elset_beams', type='element', selection=[0, 1, 2, 3]) mdl.add_set(name='elset_shell', type='element', selection=[4])
# Add nodes mdl.add_nodes(nodes=[[-5., -5., 0.], [5., -5., 0.], [5., 5., 0.], [-5., 5., 0.], [0., 0., 5.]]) # print('Node number 3:', mdl.nodes[3]) # print('Node number 3 xyz:', mdl.node_xyz(3)) # print('Node count: ', mdl.node_count()) # print('Node index: ', mdl.node_index) # print('Check node at [0, 0, 0]: ', mdl.check_node_exists([0, 0, 0])) # print('Check node at [5, 5, 0]: ', mdl.check_node_exists([5, 5, 0])) # Add elements mdl.add_elements(elements=[[0, 4], [1, 4], [2, 4], [3, 4]], type='BeamElement') mdl.add_element(nodes=[0, 1, 4], type='ShellElement') # print('Element 3 nodes: ', mdl.elements[3].nodes) # print('Element count: ', mdl.element_count()) # print('Element index: ', mdl.element_index) # print('Check element with nodes 1-4: ', mdl.check_element_exists([1, 4])) # print('Check element with nodes 0-1: ', mdl.check_element_exists([0, 1])) # Add sets mdl.add_set(name='nset_base', type='node', selection=[0, 1, 2, 3]) mdl.add_set(name='nset_top', type='node', selection=[4]) mdl.add_set(name='elset_beams', type='element', selection=[0, 1, 2, 3]) mdl.add_set(name='elset_shell', type='element', selection=[4])