Model.beamsectionupdateparts#
- Model.beamsectionupdateparts(operationtype, beamsectionid, sourceparttype='', partnames='', targetparttype='')#
Updates the beam sections by modifying section parts with operations like split, merge, convert and delete. After completing each operation, beam section properties will be recalculated.
- Parameters:
operationtype (hwString) –
Type of the operation to be performed on beam section parts. Valid values are:
split - Split the part into multiple parts by considering each line as a separate part.
merge - Merge the parts into a single part if the lines are continuous.
convert - Convert the shell part into the solid part and vice versa.
delete - Delete the parts.
beamsectionid (unsigned int) – The ID of the beam section.
sourceparttype (hwString) – The type of beam section part used as source. Valid values are shell and solid.
partnames (hwString) – The names of the beam section parts on which to perform the operation.
targetparttype (hwString) – The type of beam section part used as target. Target part type is required only for operationtype set to convert. If the source part type is shell, the target part type should be solid. If the source part type is solid, the target part type should be shell.
Example#
Update the beam section with split#import hm import hm.entities as ent model = hm.Model() model.beamsectionupdateparts( operationtype="split", beamsectionid=14, sourceparttype="shell", partnames="PSHELL_2000120 PSHELL_2000121" )
Update beam section with convert#import hm import hm.entities as ent model = hm.Model() model.beamsectionupdateparts( operationtype="convert", beamsectionid=14, sourceparttype="shell", partnames="PSHELL_2000120 PSHELL_2000121", targetparttype="solid" )
Update beam section with delete#import hm import hm.entities as ent model = hm.Model() model.beamsectionupdateparts( operationtype="delete", beamsectionid=14, sourceparttype="shell", partnames="PSHELL_2000120 PSHELL_2000121" )