Python for Abaqus: code for discrete material orientation assignment

Some Python codes for build Region in Abaqus are really difficult to figure out although Abaqus has a lot of examples and detailed manual and reference. Here is an example for creating discrete material orientation using Python script.

Assuming the part name is partName and all sets, top surface and one edge, are created beforehand, this discrete material orientation is determined by the normal direction of the top surface and the tangent direction of the edge. Here comes the code:

model = mdb.models[modelName]
part =[partName]
region = (part.cells, )
normalAxisRegion = part.surfaces['Surf-top']
primaryAxisRegion = p.sets['Set-edge']
    orientationType=DISCRETE, axis=AXIS_1, normalAxisDefinition=SURFACE,
    normalAxisRegion=normalAxisRegion, flipNormalDirection=False, 
    normalAxisDirection=AXIS_3, primaryAxisDefinition=EDGE, 
    primaryAxisRegion=primaryAxisRegion, primaryAxisDirection=AXIS_1, 
    flipPrimaryDirection=False, additionalRotationType=ROTATION_NONE, 
    angle=0.0, additionalRotationField='', stackDirection=STACK_3)

Of course, the sets of the part should be set automatically while generating the part, otherwise there should be no need to set the material orientation by script.

And if the part has been set a cell Set named Set-cell for the whole entity, the expression for the region can also have the form of following code,

region = part.sets['Set-cell']

If you know any other code for setting the region, please share it with us in the following comments area 🙂©


1 条关于 “Python for Abaqus: code for discrete material orientation assignment” 的评论

  1. 引用通告: Python for Abaqus: code for meshing a part | Abaqus 学习笔记


电子邮件地址不会被公开。 必填项已用*标注

您可以在评论中使用如下的 HTML 标记来辅助表达: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>