Model.penetrationchecktwo#
- Model.penetrationchecktwo(collection1, collection2, segment_orientation, partscale_contthick_toggle, part_scale, cont_thick)#
Checks penetration for entities selection type groups, elems2elems, nodes2elems, and elemsonly. To release the memory after completion, use the function
penetrationcheckend(). A valid template must be loaded for the check to occur.- Parameters:
collection1 (Collection) – The collection containing the first entities to check for penetration.
collection2 (Collection) – The collection containing the second entities to check for penetration.
segment_orientation (int) –
Flag for taking element normal into consideration for checking penetration.
0 - Elements normal will not be considered
1 - Elements normal will be considered
partscale_contthick_toggle (int) –
1 - If part thickness scale is selected
2 - If contact thickness is selected
part_scale (double) – Value of part scale factor.
cont_thick (double) – Value of contact thickness.
Examples#
Check penetration between elems2elems with segment orientation option and part thickness scale#import hm import hm.entities as ent model = hm.Model() # Creating collection of elements from components for checking penetration col1 = hm.Collection( model, ent.Element, hm.Collection(model, ent.Component, "name=plate") ) col2 = hm.Collection( model, ent.Element, hm.Collection(model, ent.Component, "name=esfera") ) model.penetrationchecktwo( collection1=col1, collection2=col2, segment_orientation=1, partscale_contthick_toggle=1, part_scale=1.0, cont_thick=0.0, )
Check penetration between nodes2elems without segment orientation option and with contact thickness#import hm import hm.entities as ent model = hm.Model() # Creating collection of elements & nodes from components for checking penetration col1 = hm.Collection( model, ent.Element, hm.Collection(model, ent.Component, "name=plate") ) col2 = hm.Collection( model, ent.Node, hm.Collection(model, ent.Component, "name=esfera") ) model.penetrationchecktwo( collection1=col1, collection2=col2, segment_orientation=1, partscale_contthick_toggle=1, part_scale=1.0, cont_thick=0.0, )