本文摘要(由AI生成):
本文展示了在ABAQUS中创建仿真模型、施加边界条件、集中力、重力、划分网格、创建作业并提交分析,以及进行后处理的过程。首先,通过定义边界条件和集中力来设置模型。然后,划分网格,并创建作业进行分析。分析完成后,通过后处理模块查看结果,并保存CAE文件。
基于Python 的 Abaqus 的二次开发便捷之处在于:
#此程序用来绘制臂架前段
#导入相关模块
#
coding: mbcs
from abaqus import *
from abaqusConstants import *
#定义整个臂架的长、宽、高
L0=14300
W0=1650
H0=800
#创建零件P01_12
L1=H0+200 W1=200 T1=12
s = mdb.models['Model-1'].ConstrainedSketch(name=' profile ',
sheetSize=2000.0)
g, v, d, c = s.geometry, s.vertices, s.dimensions, s.constraints
s.setPrimaryObject(option=STANDALONE) s.rectangle(point1=(W0/2, L1/2), point2=(W0/2+W1, -L1/2))
s.rectangle(point1=(-W0/2, L1/2), point2=(-W0/2-W1, -L1/2))
p = mdb.models['Model-1'].Part(name='Part-1', dimensionality=THREE_D, type=DEFORMABLE_BODY)
p = mdb.models['Model-1'].parts['Part-1'] p.BaseShell(sketch=s)
session.viewports['Viewport: 1'].setValues(displayedObject=p) del mdb.models['Model-1'].sketches['
profile ']
注:通过点的坐标进行参数化是模型参数化的 最 好选择。
#定义零件的厚度
p = mdb.models['Model-1'].parts['Part-1']
f = p.faces
pickedFaces01 = f.findAt(((W0/2, L1/2, 0),),((-W0/2, L1/2, 0),), )
p.assignThickness(faces=pickedFaces01, thickness=T1)
p.Set(faces=pickedFaces01, name='P01_12')
注:建立一个零件后就立即对该零件建立一个 Set Set 的建立可以方便后期的相关处理。需要通过findAt() 命令来选取相应的体、面、线或点。
#创建辅助平面和辅助坐标系
p = mdb.models['Model
1'].parts['Part 1']
p.DatumCsysByThreePoints(name='Datum csys
1', coordSysType=CARTESIAN, origin=(
0.0, 0.0, 0.0), line1=(1.0, 0.0, 0.0), line2=(0.0, 1.0, 0.0))
p = mdb.models['Model
1'].parts['Part 1']
p.DatumPlaneByPrincipalPlane(principalPlane=XYPLANE, offset=L0)
注:所建立的第一个参考可以不编号。
#创建零件P02_12
L2=L1 W2=W1 T2=12
p = mdb.models['Model-1'].parts['Part-1']
d = p.datums
#将草图原点参数化
t = p.MakeSketchTransform(sketchPlane=d[5], sketchUpEdge=d[4].axis2, sketchPlaneSide=SIDE1,
sketchOrientation=RIGHT, origin=(0.0, 0.0, L0))
s = mdb.models['Model-1'].ConstrainedSketch(name=' profile ', sheetSize=29006.85,
gridSpacing=725.17, transform=t)
g, v, d1, c = s.geometry, s.vertices, s.dimensions, s.constraints
s.setPrimaryObject(option=SUPERIMPOSE)
p = mdb.models['Model-1'].parts['Part-1']
s.rectangle(point1=(W0/2, L2/2), point2=(W0/2+W2, -L2/2))
s.rectangle(point1=(-W0/2, L2/2), point2=(-W0/2-W2, -L2/2)) p =
mdb.models['Model-1'].parts['Part-1']
d2 = p.datums
p.Shell(sketchPlane=d2[5], sketchUpEdge=d2[4].axis2, sketchPlaneSide=SIDE1,
sketchOrientation=RIGHT, sketch=s)
s.unsetPrimaryObject()
del mdb.models['Model-1'].sketches[' profile ']
注:从第二个草图开始就需要对草图的原点进行参数化。
#定义零件的厚度
p = mdb.models['Model
1'].parts['Part 1']
f = p.faces
pickedFaces02 = f.findAt(((W0/2, L1/2, L0),),((
W0/2, L1/2, L0),), )
p.as
signThickness (faces=pickedFaces02, thickness=
p.Set(faces=pickedFaces02, name='P02_12')
注:给几何面赋厚度,可以在后期赋壳单元属性时直接选取几何面的厚度;也可以通过壳单元属性给建立的 Set 赋予厚度。两种方法适用于不同的情况。
#创建零件 P03_12 和零件 P04_08
T3=12
T4=8
p = mdb.models['Model
1'].parts['Part 1']
d = p.datums
t = p.MakeSketchTransform(sketchPlane=d[5], sketchUpEdge=d[4].axis2,
sketchPlaneSide=SIDE1, sketchOrientation=RIGHT, origin=(0.0, 0.0, L0))
s = mdb.models['Model
1'].ConstrainedSketch(name='__profile__',
sheetSize=29006.85, gridSpacing=725.17, transform=t)
g, v, d1, c = s.geometry, s.vertices, s.dimensions, s.const
raints
s.setPrimaryObject(option=SUPERIMPOSE)
#创建草图
p = mdb.models['Model
1'].parts['Part 1']
s.Line(point1=(
W0/2 W1, H0/2), point2=( W0/2, H0/2))
s.Line(point1=(W0/2, H0/2), point2=(W0/2+W1, H0/2))
s.Line(point1=(
W0/2 W1, H0/2), point2=( W0/2, H0/2))
s.Line(point1=(W0/2,
H0/2), point2=(W0/2+W1, H0/2))
p = mdb.models['Model
1'].parts['Part 1']
d2 = p.datums
p.ShellExtrude(sketchPlane=d2[5], sketchUpEdge=d2[4].axis2,
sketchPlaneSide=SIDE1, sketchOrientation=RIGHT, sketch=s, depth=L0,
flipExtr udeDirection=ON)
s.unsetPrimaryObject()
del mdb.models['Model
1'].sketches['__profile__']
#定义零件 P03_12 的厚度
p = mdb.models['Model
1'].parts['Part 1']
f = p.faces
pickedFaces03 = f.findAt(((
W0/2, H0/2, L0/2),),((W0/2, H0/2, L0/2),),)
p.assignThickness(faces=pickedFaces03, thickness=T3)
p.Set(faces=pickedFaces03, name='P03_12')
#定义零件P04_12 的厚度
p = mdb.models['Model-1'].parts['Part-1'] f = p.faces
pickedFaces04 = f.findAt(((-W0/2, -H0/2, L0/2),),((W0/2, -H0/2, L0/2),),)
p.assignThickness(faces=pickedFaces04, thickness=T4) p.Set(faces=pickedFaces04, name='P04_12')
#创建零件P05_08 T5=8
p = mdb.models['Model-1'].parts['Part-1'] d = p.datums
t = p.MakeSketchTransform(sketchPlane=d[5], sketchUpEdge=d[4].axis2, sketchPlaneSide=SIDE1,
sketchOrientation=RIGHT, origin=(0.0, 0.0, L0))
s = mdb.models['Model-1'].ConstrainedSketch(name=' profile ', sheetSize=29006.85,
gridSpacing=725.17, transform=t)
g, v, d1, c = s.geometry, s.vertices, s.dimensions, s.constraints
s.setPrimaryObject(option=SUPERIMPOSE) p = mdb.models['Model-1'].parts['Part-1']
s.Line(point1=(-W0/2-W1/2, H0/2), point2=(-W0/2-W1/2, -H0/2)) s.Line(point1=(W0/2+W1/2, H0/2),
point2=(W0/2+W1/2, -H0/2)) p = mdb.models['Model-1'].parts['Part-1']
d2 = p.datums
p.ShellExtrude(sketchPlane=d2[5], sketchUpEdge=d2[4].axis2, sketchPlaneSide=SIDE1,
sketchOrientation=RIGHT, sketch=s, depth=L0, flipExtrudeDirection=ON)
s.unsetPrimaryObject()
del mdb.models['Model-1'].sketches[' profile '] #定义零件P05_8 的厚度
p = mdb.models['Model-1'].parts['Part-1']
f = p.faces
pickedFaces05 = f.findAt(((-W0/2-W1/2, 0, L0/2),),((W0/2+W1/2, 0, L0/2),),)
p.assignThickness(faces=pickedFaces05, thickness=T5) p.Set(faces=pickedFaces05, name='P05_08')
#创建零件P06_08 L6=W0+W1 n=L0//2520+1
T6=8
p = mdb.models['Model-1'].parts['Part-1']
f, d = p.faces, p.datums
t = p.MakeSketchTransform(sketchPlane=f[0], sketchUpEdge=d[4].axis2, sketchPlaneSide=SIDE1,
sketchOrientation=RIGHT, origin=(W0/2+W1/2, -H0/2,
0))
s = mdb.models['Model
1'].C onstrainedSketch(name='__profile__',
sheetSize=28684, gridSpacing=717, transform=t)
g, v, d1, c = s.geometry, s.vertices, s.dimensions, s.constraints
s.setPrimaryObject(option=SUPERIMPOSE)
p = mdb.models['Model
1'].parts['Part 1']
#循环命令绘制平行隔板
for i in range(0,n):
s.Line(point1=(-500-(i*2520), H0), point2=(-500-(i*2520), 0.0))
p = mdb.models['Model-1'].parts['Part-1']
f1, d2 = p.faces, p.datums
p.ShellExtrude(sketchPlane=f1[0], sketchUpEdge=d2[4].axis2, sketchPlaneSide=SIDE1,
sketchOrientation=RIGHT, sketch=s, depth=L6, flipExtrudeDirection=ON)
s.unsetPrimaryObject()
del mdb.models['Model-1'].sketches[' profile ']
注:也可以将 range(0,n) 改成 自定义 数组,这样就可以实现不等间距的参数化控制。
#定义零件P06_08 的厚度
p = mdb.models['Model-1'].parts['Part-1'] f = p.faces
for i in range(0,n):
pickedFaces = f.findAt(((0, H0/4, 500+i*2520),)) p.assignThickness(faces=pickedFaces, thickness=T6)
p.Set(faces=pickedFaces, name='P06_08_'+str(1+i))
注:将循环绘制的零件通过循环命令分别建立各自的 Set 并分别命名。也可以将循环绘制的零件建立成一个 Set ,视具体情况而定。
#创建零件P07_12,P08_12
W7=200 L7=W0+W1
T7=12 T8=12
p = mdb.models['Model-1'].parts['Part-1']
f, e = p.faces, p.edges
t = p.MakeSketchTransform(
sketchPlane=f.findAt(coordinates=(W0/2+W1/2, 0.0, 100.0)),
sketchUpEdge=e.findAt(coordinates=(W0/2+W1/2, 0.0, 0.0)),
sketchOrientation=RIGHT,sketchPlaneSide=SIDE1, origin=(W0/2+W1/2, -H0/2, 0.0))
s = mdb.models['Model-1'].ConstrainedSketch(name=' profile ', sheetSize=53678,
gridSpacing=1341, transform=t)
g, v, d, c = s.geometry, s.vertices, s.dimensions, s.constraints
s.setPrimaryObject(option=SUPERIMPOSE) p = mdb.models['Model-1'].parts['Part-1']
#循环命令绘制平行隔板
for i in range(0,n):
s.Line(point1=(400+i*2520, -H0), point2=(600+i*2520, -H0))
s.Line(point1=(400+i*2520, 0), point2=(600+i*2520, 0))
p = mdb.models['Model-1'].parts['Part-1']
f1, e1 = p.faces, p.edges
p.ShellExtrude(
sketchPlane=f.findAt(coordinates=(W0/2+W1/2, 0.0, 100.0)),
sketchUpEdge=e.findAt(coordinates=(W0/2+W1/2, 0.0, 0.0)), sketchPlaneSide=SIDE1,
sketchOrientation=RIGHT, sketch=s, depth=W0+W1, flipExtrudeDirection=ON,
keepInternalBoundaries=ON)
s.unsetPrimaryObject()
del mdb.models['Model-1'].sketches[' profile ']
#定义零件P07_12 的厚度
p = mdb.models['Model-1'].parts['Part-1'] f = p.faces
for i in range(0,n):
pickedFaces07 = f.findAt(((0, H0/2, 400+i*2520),),((0, H0/2, 600+i*2520),),)
p.assignThickness(faces=pickedFaces07, thickness=T7)
p.Set(faces=pickedFaces07, name='P07_12_'+str(1+i))
#定义耦合set
fp=[]
for i in range(0,2):
fp.append(f.findAt(((0, H0/2, 400+i*2520),),((0, H0/2, 600+i*2520),),))
p.Set(faces=fp, name='P07_fp') #定义零件P08_12 的厚度
p = mdb.models['Model-1'].parts['Part-1'] f = p.faces
for i in range(0,n):
pickedFaces08 = f.findAt(((0, -H0/2, 400+i*2520),),((0, -H0/2, 600+i*2520),),)
p.assignThickness(faces=pickedFaces08, thickness=T7)
p.Set(faces=pickedFaces08, name='P08_12_'+str(1+i))
注:为了后期边界条件施加的方便,在此次将一系列面定义成一个 Set 。必须通过 append()命令将所有通过循环命令查找的 faces 添加到一个数值中,这样才能将所有的 faces 建立到一个 Set 中去
#为中间隔板创建空腔
#定义相关参数边界距离、圆角 d0=100
r0=100
p = mdb.models['Model-1'].parts['Part-1']
f1, e1 = p.faces, p.edges
t = p.MakeSketchTransform(
f.findAt(coordinates=(0, 0.0, 500.0)),
sketchUpEdge=e.findAt(coordinates=(W0/2+W1/2, 0.0, 500.0)), sketchPlaneSide=SIDE1,
sketchOrientation=RIGHT,
origin=(0.0, 0.0, 500.0))
s = mdb.models['Model-1'].ConstrainedSketch(name=' profile ', sheetSize=5910.0,
gridSpacing=147.0, transform=t)
g, v, d1, c = s.geometry, s.vertices, s.dimensions, s.constraints
s.setPrimaryObject(option=SUPERIMPOSE)
p = mdb.models['Model-1'].parts['Part-1']
p.projectReferencesOntoSketch(sketch=s, filter=COPLANAR_EDGES)
#创建矩形
s.rectangle(point1=(-W0/2-W1/2+d0, H0/2-d0), point2=(W0/2+W1/2-d0, -H0/2+d0))
#创建圆角
s.FilletByRadius(radius=r0, curve1=g[29], nearPoint1=(-W0/2-W1/2+d0,
H0/2-d0), curve2=g[26], nearPoint2=(-W0/2-W1/2+d0, H0/2-d0)) s.FilletByRadius(radius=r0,
curve1=g[26], nearPoint1=(-W0/2-W1/2+d0,
-H0/2+d0), curve2=g[27], nearPoint2=(-W0/2-W1/2+d0, -H0/2+d0)) s.FilletByRadius(radius=r0,
curve1=g[27], nearPoint1=(W0/2+W1/2-d0,
-H0/2+d0), curve2=g[28], nearPoint2=(W0/2+W1/2-d0, -H0/2+d0)) s.FilletByRadius(radius=r0,
curve1=g[28], nearPoint1=(W0/2+W1/2-d0,
H0/2-d0), curve2=g[29], nearPoint2=(W0/2+W1/2-d0, H0/2-d0)) p =
mdb.models['Model-1'].parts['Part-1']
f1, d2 = p.faces, p.datums
注:圆制圆角进行参的原点最好通
p.CutExtrude(
f.findAt(coordinates=(0, 0.0, 500.0)),
sketchUpEdge=e.findAt(coordinates=(W0/2+W1/2, 0.0, 500.0)), sketchPlaneSide=SIDE1,
sketchOrientation=RIGHT, sketch=s, depth=L0, flipExtrudeDirection=OFF)
s.unsetPrimaryObject()
del mdb.models['Model-1'].sketches[' profile ']
注:圆角有方向性,因此在绘制圆角时需要将 nearpoint 也进行参数化,可直接选择草图的原点。另外,此处的 curve最好通过 findAt 查找得出。
#开始建立梁Beam_1
p = mdb.models['Model-1'].parts['Part-1'] f, d = p.faces, p.datums
#绘制参考面 p.DatumPlaneByOffset(plane=f.findAt(coordinates=
(W0/2, -H0/2, 100.0)),flip=SIDE2, offset=8.0)
dp1 = d.keys()[-1]
p = mdb.models['Model-1'].parts['Part-1'] d = p.datums
t = p.MakeSketchTransform(sketchPlane=d[dp1], sketchUpEdge=d[4].axis1, sketchPlaneSide=SIDE1,
sketchOrientation=RIGHT, origin=(0.0, 0.0,
0.0))
s = mdb.models['Model-1'].ConstrainedSketch(name=' profile ', sheetSize=31857.0,
gridSpacing=796.0, transform=t)
g, v, d1, c = s.geometry, s.vertices, s.dimensions, s.constraints
s.setPrimaryObject(option=SUPERIMPOSE)
p = mdb.models['Model-1'].parts['Part-1']
注:此处建立参考面后,立即给该参考面进行了编号(dp1),否则后面的程序中无法引用该参考面。实际上,每建立一个参考后,都应该给该参考进行编号,这样的操作才比较规范。
注:通过参考面的编号[dp1]来引用参考面。
#计算中间加强梁的数量
if n%2==1:
n1=n//2
n2=n//2 else:
n1=n//2 n2=n//2-1
for i in range(0,n1):
s.Line(point1=(-500-i*2520*2, W0/2+W1/2), point2=(-500-2520-i*2520*2,-W0/2-W1/2 )) for i in
range(0,n2):
s.Line(point1=(-500-2520-i*2520*2,-W0/2-W1/2), point2=(-500-2*2520-i*2520*2,W0/2+W1/2 ))
#在基准平面 dp1 上面绘制梁
p = mdb.models['Model-1'].parts['Part-1'] d2 = p.datums
e = p.edges
p.Wire(sketchPlane=d2[dp1], sketchUpEdge=d2[4].axis1, sketchPlaneSide=SIDE1,
sketchOrientation=RIGHT, sketch=s)
s.unsetPrimaryObject()
del mdb.models['Model-1'].sketches[' profile ']
edges1=[]
for i in range(0,n-1):
edges1.append(e.findAt(((0, -H0/2-8, 500+2520/2+i*2520),),))
p.Set(edges=edges1, name='Beam_1')
注:必须通过 append()命令将所有通过循环命令查找的edges 添加到一个数组中,这样才能将所有的edges 建立到一个 Set 中去,以方便后期建立 tie。
###########################
#开始定义有限元分析的相关参数 #定义材料
mdb.models['Model-1'].Material(name='steel')
mdb.models['Model-1'].materials['steel'].Elastic(table=((210000.0, 0.3), ))
mdb.models['Model-1'].materials['steel'].Density(table=((7.8e-06, ), ))
#定义壳单元属性
mdb.models['Model-1'].HomogeneousShellSection(name='shell', preIntegrate=OFF, material='steel',
thicknessType=UNIFORM, thickness=10.0, thicknessField='', idealization=NO_IDEALIZATION,
poissonDefinition=DEFAULT, thicknessModulus=None, temperature=GRADIENT, useDensity=OFF,
integrationRule=SIMPSON, numIntPts=5)
#赋所有壳单元属性
p = mdb.models['Model-1'].parts['Part-1']
for i in range(1,5):
region1 = p.sets['P0'+str(i)+'_12']
p.SectionAssignment(region=region1, sectionName='shell', offset=0.0,
offsetType=FROM_GEOMETRY, offsetField='',
thicknessAssignment=FROM_GEOMETRY)
region2 = p.sets['P05_08']
p.SectionAssignment(region=region2, sectionName='shell', offset=0.0,
offsetType=FROM_GEOMETRY, offsetField='', thicknessAssignment=FROM_GEOMETRY)
for i in range(1,n+1):
region3 = p.sets['P06_08_'+str(i)]
p.SectionAssignment(region=region3, sectionName='shell', offset=0.0,
offsetType=FROM_GEOMETRY, offsetField='', thicknessAssignment=FROM_GEOMETRY)
for i in range(1,n+1):
region4 = p.sets['P07_12_'+str(i)]
p.SectionAssignment(region=region4, sectionName='shell', offset=0.0,
offsetType=FROM_GEOMETRY, offsetField='', thicknessAssignment=FROM_GEOMETRY)
for i in range(1,n+1):
region5 = p.sets['P08_12_'+str(i)]
p.SectionAssignment(region=region5, sectionName='shell', offset=0.0,
offsetType=FROM_GEOMETRY, offsetField='',
thicknessAssignment=FROM_GEOMETRY)
注:此处选择厚度属性来源于几何。如果需要做厚度优化的话,也可以选择来源于壳单元属性,但需要建立与之匹配的壳单元属性,并且一个零件对应于一个壳单元熟悉。
注:全部通过前期建立的Set来赋壳单元属性,省掉了再次findAt 的麻烦。
#定义梁单元属性
mdb.models['Model-1'].LProfile(name='L_65', a=65.0, b=65.0, t1=7.0, t2=7.0)
mdb.models['Model-1'].BeamSection(name='B_65', integration=DURING_ANALYSIS,
poissonRatio=0.0, profile='L_65', material='steel', temperatureVar=LINEAR,
consistentMassMatrix=False)
#赋所有梁单元属性
p = mdb.models['Model-1'].parts['Part-1'] region = p.sets['Beam_1']
p.SectionAssignment(region=region, sectionName='B_65', offset=0.0,
offsetType=MIDDLE_SURFACE, offsetField='', thicknessAssignment=FROM_SECTION)
p.assignBeamSectionOrientation(region=region, method=N1_COSINES, n1=(0.0, 0.0,
-1.0))
#定义装配体 import assembly
a = mdb.models['Model-1'].rootAssembly a.DatumCsysByDefault(CARTESIAN)
p = mdb.models['Model-1'].parts['Part-1']
a.Instance(name='Part-1-1', part=p, dependent=ON)
#定义分析步 import step
mdb.models['Model-1'].StaticStep(name='Step-1', previous='Initial')
#定义底面与梁的tied
import interaction
a = mdb.models['Model-1'].rootAssembly region1=a.instances['Part-1-1'].sets['P04_12']
region2=a.instances['Part-1-1'].sets['Beam_1']
mdb.models['Model-1'].Tie(name='Constraint-1', master=region1, slave=region2,
positionToleranceMethod=COMPUTED, adjust=OFF, tieRotations=ON, thickness=ON)
#开始定义耦合
#导入相关模块 import regionToolset
a = mdb.models['Model-1'].rootAssembly
d, r = a.datums, a.referencePoints
#定义参考点
a.ReferencePoint(point=(0.0, H0/2, 500+2520/2)) r1 = a.referencePoints
rp1 = r.keys()[-1]
refPoints1=(r1[rp1], ) region1=regionToolset.Region(referencePoints=refPoints1) s1 =
a.instances['Part-1-1'].faces
region2 = a.instances['Part-1-1'].sets['P07_fp']
mdb.models['Model-1'].Coupling(name='Constraint-2', controlPoint=region1, surface=region2,
influenceRadius=WHOLE_SURFACE, couplingType=DISTRIBUTING,
localCsys=None, u1=ON, u2=ON, u3=ON, ur1=ON, ur2=ON, ur3=ON)
注:对建立的参考点编号,以方便后期调用。
########################
#定义边界条件 import load
a = mdb.models['Model-1'].rootAssembly d, r = a.datums, a.referencePoints
region = a.instances['Part-1-1'].sets['P02_12']
mdb.models['Model-1'].DisplacementBC(name='SPC', createStepName='Initial', region=region, u1=SET,
u2=SET, u3=SET, ur1=SET, ur2=SET, ur3=SET, amplitude=UNSET, distributionType=UNIFORM, fieldName='',
localCsys=None)
a = mdb.models['Model-1'].rootAssembly
region = a.instances['Part-1-1'].sets['P08_12_'+str(n-1)]
mdb.models['Model-1'].DisplacementBC(name='SPC2', createStepName='Initial', region=region, u1=SET,
u2=SET, u3=SET, ur1=SET, ur2=SET, ur3=SET, amplitude=UNSET, distributionType=UNIFORM, fieldName='',
localCsys=None)
r1 = a.referencePoints refPoints1=(r1[rp1], )
region = regionToolset.Region(referencePoints=refPoints1)
mdb.models['Model-1'].ConcentratedForce(name='force', createStepName='Step-1',
region=region, cf2=-10000.0, distributionType=UNIFORM, field='',
localCsys=None)
mdb.models['Model-1'].Gravity(name='G', createStepName='Step-1', comp2=-9.8,
distributionType=UNIFORM, field='')
################
#划分网格 import mesh
p = mdb.models['Model-1'].parts['Part-1'] p.seedPart(size=20.0, deviationFactor=0.1,
minSizeFactor=0.1) p.generateMesh()
a = mdb.models['Model-1'].rootAssembly
##############
#创建作业并提交分析 import job
mdb.Job(name='006', model='Model-1', description='', type=ANALYSIS, atTime=None, waitMinutes=0,
waitHours=0, queue=None, memory=90, memoryUnits=PERCENTAGE, getMemoryFromAnalysis=True,
explicitPrecision=SINGLE, nodalOutputPrecision=SINGLE, echoPrint=OFF, modelPrint=OFF,
contactPrint=OFF, historyPrint=OFF, userSubroutine='', scratch='', multiprocessingMode=DEFAULT,
numCpus=4, numDomains=4)
mdb.jobs['006'].submit(consistencyChecking=ON) mdb.jobs['006'].waitForCompletion()
##############
#进入后处理模块 import visualization
o3 = session.openOdb(name='F:/ABAQUS/006.odb') session.viewports['Viewport:
1'].setValues(displayedObject=o3) session.viewports['Viewport:
1'].odbDisplay.display.setValues(plotState=(
CONTOURS_ON_DEF, ))
session.viewports['Viewport: 1'].view.setValues(session.views['Iso'])
mdb.saveAs(pathName='F:/ABAQUS/006.cae')