gxi_circuit_caemodel.py
#
# Getting Started with ABAQUS
#
# Script for circuit board drop test example
#
session.journalOptions.setValues(replayGeometry=COORDINATE,
recoverGeometry=COORDINATE)
from abaqus import *
from abaqusConstants import *
session.Viewport(name='Viewport: 1', origin=(1.5625, 1.5625), width=230.0,
height=155.0)
session.viewports['Viewport: 1'].makeCurrent()
from driverUtils import executeOnCaeStartup
executeOnCaeStartup()
#: Executing "onCaeStartup()" in the site directory ...
#: Executing "onCaeStartup()" in the home directory ...
Mdb()
#: A new model database has been created.
#: The model "Model-1" has been created.
session.viewports['Viewport: 1'].setValues(displayedObject=None)
mdb.models.changeKey(fromName='Model-1', toName='circuitBoard')
import part
import regionToolset
import displayGroupMdbToolset as dgm
#: Part module loaded
s = mdb.models['circuitBoard'].Sketch(name='__profile__', sheetSize=0.1)
g, v, d = s.geometry, s.vertices, s.dimensions
s.sketchOptions.setValues(sheetSize=0.1, gridSpacing=0.002, grid=ON,
gridFrequency=2, constructionGeometry=ON, dimensionTextHeight=0.002,
decimalPlaces=3)
s.rectangle(point1=(-0.01, -0.012), point2=(0.01, 0.012))
p = mdb.models['circuitBoard'].Part(name='Packaging', dimensionality=THREE_D,
type=DEFORMABLE_BODY)
p = mdb.models['circuitBoard'].parts['Packaging']
p.BaseSolidExtrude(sketch=s, depth=0.11)
p = mdb.models['circuitBoard'].parts['Packaging']
session.viewports['Viewport: 1'].setValues(displayedObject=p)
del mdb.models['circuitBoard'].sketches['__profile__']
p = mdb.models['circuitBoard'].parts['Packaging']
f, e = p.faces, p.edges
t = p.MakeSketchTransform(sketchPlane=f.findAt(coordinates=(
-0.00333333333333333, -0.004, 0.11)), sketchUpEdge=e.findAt(coordinates=(
0.01, -0.006, 0.11)), sketchPlaneSide=SIDE1, sketchOrientation=RIGHT,
origin=(0.0, 0.0, 0.11))
s0 = mdb.models['circuitBoard'].Sketch(name='__profile__', sheetSize=0.1,
gridSpacing=0.002, transform=t)
g, v, d = s0.geometry, s0.vertices, s0.dimensions
s0.sketchOptions.setValues(sheetSize=0.1, gridSpacing=0.002, grid=ON,
gridFrequency=2, constructionGeometry=ON, dimensionTextHeight=0.002,
decimalPlaces=3)
p = mdb.models['circuitBoard'].parts['Packaging']
p.projectReferencesOntoSketch(sketch=s0, filter=COPLANAR_EDGES)
r, r0 = s0.referenceGeometry, s0.referenceVertices
s0.rectangle(point1=(-0.001, 0.0), point2=(0.001, 0.015))
p = mdb.models['circuitBoard'].parts['Packaging']
f0, e0 = p.faces, p.edges
p.CutExtrude(sketchPlane=f0.findAt(coordinates=(-0.00333333333333333, -0.004,
0.11)), sketchUpEdge=e0.findAt(coordinates=(0.01, -0.006, 0.11)),
sketchPlaneSide=SIDE1, sketchOrientation=RIGHT, sketch=s0)
del mdb.models['circuitBoard'].sketches['__profile__']
p0 = mdb.models['circuitBoard'].parts['Packaging']
e = p0.edges
p0.DatumPointByMidPoint(point1=p0.InterestingPoint(edge=e.findAt(coordinates=(
0.0005, 0.0, 0.11)), rule=MIDDLE), point2=p0.InterestingPoint(
edge=e.findAt(coordinates=(-0.0005, 0.0, 0.0)), rule=MIDDLE))
s = mdb.models['circuitBoard'].Sketch(name='__profile__', sheetSize=0.5)
g, v, d = s.geometry, s.vertices, s.dimensions
s.sketchOptions.setValues(sheetSize=0.5, gridSpacing=0.01, grid=ON,
gridFrequency=2, constructionGeometry=ON, dimensionTextHeight=0.01,
decimalPlaces=3)
s.rectangle(point1=(0.0, 0.0), point2=(0.1, 0.15))
session.viewports['Viewport: 1'].view.fitView()
p = mdb.models['circuitBoard'].Part(name='Board', dimensionality=THREE_D,
type=DEFORMABLE_BODY)
p = mdb.models['circuitBoard'].parts['Board']
p.BaseShell(sketch=s)
p = mdb.models['circuitBoard'].parts['Board']
session.viewports['Viewport: 1'].setValues(displayedObject=p)
del mdb.models['circuitBoard'].sketches['__profile__']
p0 = mdb.models['circuitBoard'].parts['Board']
v0 = p0.vertices
p0.DatumPointByOffset(point=v0.findAt(coordinates=(0.0, 0.0, 0.0)), vector=(
0.01, 0.135, 0.0))
p0 = mdb.models['circuitBoard'].parts['Board']
v0 = p0.vertices
p0.DatumPointByOffset(point=v0.findAt(coordinates=(0.0, 0.0, 0.0)), vector=(
0.07, 0.09, 0.0))
p0 = mdb.models['circuitBoard'].parts['Board']
v0 = p0.vertices
p0.DatumPointByOffset(point=v0.findAt(coordinates=(0.0, 0.0, 0.0)), vector=(
0.08, 0.03, 0.0))
s0 = mdb.models['circuitBoard'].Sketch(name='__profile__', sheetSize=0.5)
g, v, d = s0.geometry, s0.vertices, s0.dimensions
s0.sketchOptions.setValues(sheetSize=0.5, gridSpacing=0.01, grid=ON,
gridFrequency=2, constructionGeometry=ON, dimensionTextHeight=0.01,
decimalPlaces=3)
s0.rectangle(point1=(-0.1, -0.1), point2=(0.1, 0.1))
p = mdb.models['circuitBoard'].Part(name='Floor', dimensionality=THREE_D,
type=DISCRETE_RIGID_SURFACE)
p = mdb.models['circuitBoard'].parts['Floor']
p.BaseShell(sketch=s0)
p = mdb.models['circuitBoard'].parts['Floor']
session.viewports['Viewport: 1'].setValues(displayedObject=p)
del mdb.models['circuitBoard'].sketches['__profile__']
p0 = mdb.models['circuitBoard'].parts['Floor']
p0.ReferencePoint(point=(0.0, 0.0, 0.0))
session.viewports['Viewport: 1'].setValues(displayedObject=p)
import material
import section
import regionToolset
import displayGroupMdbToolset as dgm
#: Property module loaded
mdb.models['circuitBoard'].Material('PCB')
mdb.models['circuitBoard'].materials['PCB'].Elastic(table=((45.e9, 0.3), ))
mdb.models['circuitBoard'].materials['PCB'].Density(table=((500.0, ), ))
mdb.models['circuitBoard'].Material('Foam')
mdb.models['circuitBoard'].materials['Foam'].Elastic(table=((3.e6, 0.0), ))
mdb.models['circuitBoard'].materials['Foam'].Density(table=((100.0, ), ))
mdb.models['circuitBoard'].materials['Foam'].CrushableFoam(table=((1.1, 0.1),
))
mdb.models['circuitBoard'].materials['Foam'].crushableFoam.CrushableFoamHardening(
table=((220000.0, 0.0), (246510.0, 0.1), (272940.0, 0.2), (299020.0, 0.3),
(324550.0, 0.4), (349350.0, 0.5), (373260.0, 0.6), (396170.0, 0.7), (
418010.0, 0.8), (438720.0, 0.9), (458270.0, 1.0), (493840.0, 1.2), (
524840.0, 1.4), (551530.0, 1.6), (574310.0, 1.8), (593590.0, 2.0), (
629360.0, 2.5), (651990.0, 3.0), (683340.0, 5.0), (688330.0, 10.0)))
mdb.models['circuitBoard'].HomogeneousShellSection(name='BoardSection',
preIntegrate=OFF, material='PCB', thickness=0.002,
poissonDefinition=DEFAULT, temperature=GRADIENT, integrationRule=SIMPSON,
numIntPts=5)
mdb.models['circuitBoard'].HomogeneousSolidSection(name='FoamSection',
material='Foam', thickness=1.0)
p = mdb.models['circuitBoard'].parts['Board']
session.viewports['Viewport: 1'].setValues(displayedObject=p)
p0 = mdb.models['circuitBoard'].parts['Board']
f = p0.faces
faces = f.findAt(((0.0333333333333333, 0.05, 0.0), ))
region = regionToolset.Region(faces=faces)
p1 = mdb.models['circuitBoard'].parts['Board']
p1.SectionAssignment(region=region, sectionName='BoardSection')
#: The section "BoardSection" has been assigned to the selected regions.
p = mdb.models['circuitBoard'].parts['Packaging']
session.viewports['Viewport: 1'].setValues(displayedObject=p)
p0 = mdb.models['circuitBoard'].parts['Packaging']
c = p0.cells
cells = c.findAt(((-0.000333333333333333, 0.0, 0.0366666666666667), ))
region = regionToolset.Region(cells=cells)
p1 = mdb.models['circuitBoard'].parts['Packaging']
p1.SectionAssignment(region=region, sectionName='FoamSection')
#: The section "FoamSection" has been assigned to the selected regions.
import assembly
import regionToolset
import displayGroupMdbToolset as dgm
#: Assembly module loaded
session.viewports['Viewport: 1'].setValues(displayedObject=p)
p = mdb.models['circuitBoard'].parts['Board']
session.viewports['Viewport: 1'].setValues(displayedObject=p)
p1 = mdb.models['circuitBoard'].parts['Board']
e = p1.edges
p1.DatumCsysByTwoLines(CARTESIAN, line1=e.findAt(coordinates=(0.025, 0.0,
0.0)), line2=e.findAt(coordinates=(0.1, 0.0375, 0.0)), name='Datum csys-1')
p1 = mdb.models['circuitBoard'].parts['Board']
f = p1.faces
faces = f.findAt(((0.0333333333333333, 0.05, 0.0), ))
region = regionToolset.Region(faces=faces)
p0 = mdb.models['circuitBoard'].parts['Board']
datums = p0.datums[6]
p0.assignMaterialOrientation(region=region, localCsys=datums, axis=AXIS_3)
#: Specified material orientation has been assigned to the selected regions.
a = mdb.models['circuitBoard'].rootAssembly
session.viewports['Viewport: 1'].setValues(displayedObject=a)
a = mdb.models['circuitBoard'].rootAssembly
a.DatumCsysByDefault(CARTESIAN)
p = mdb.models['circuitBoard'].parts['Floor']
a.Instance(name='Floor-1', part=p, dependent=ON)
a = mdb.models['circuitBoard'].rootAssembly
a.DatumPointByCoordinate(coords=(0.0, 0.0, 0.0))
a = mdb.models['circuitBoard'].rootAssembly
a.DatumPointByCoordinate(coords=(0.5, 0.707, 0.25))
session.viewports['Viewport: 1'].view.fitView()
session.viewports['Viewport: 1'].view.setValues(cameraPosition=(-0.035316,
-0.47176, 2.0325), cameraUpVector=(-0.12685, 0.92429, 0.36001))
session.viewports['Viewport: 1'].view.setValues(width=0.084511,
height=0.054026, viewOffsetX=-0.11689, viewOffsetY=-0.14047)
session.viewports['Viewport: 1'].view.fitView()
a = mdb.models['circuitBoard'].rootAssembly
r1 = a.instances['Floor-1'].referencePoints
d1 = a.datums
a.DatumAxisByTwoPoint(point1=r1[2], point2=d1[5])
session.viewports['Viewport: 1'].view.setValues(session.views['Front'])
a0 = mdb.models['circuitBoard'].rootAssembly
p = mdb.models['circuitBoard'].parts['Packaging']
a0.Instance(name='Packaging-1', part=p, dependent=ON)
mdb.models['circuitBoard'].rootAssembly.setValues(
regenerateConstraintsTogether=OFF)
session.viewports['Viewport: 1'].view.setViewpoint(viewVector=(-1, -1, 1),
cameraUpVector=(0, 0, 1))
session.viewports['Viewport: 1'].view.fitView()
session.viewports['Viewport: 1'].view.setValues(width=0.35487, height=0.22686,
viewOffsetX=0.007119, viewOffsetY=-0.091124)
session.viewports['Viewport: 1'].view.setValues(width=0.2072, height=0.13246,
viewOffsetX=0.031584, viewOffsetY=-0.11213)
session.viewports['Viewport: 1'].assemblyDisplay.setValues(renderStyle=SHADED)
a0 = mdb.models['circuitBoard'].rootAssembly
e1 = a0.instances['Packaging-1'].edges
d01 = a0.datums
a0.EdgeToEdge(movableAxis=e1.findAt(coordinates=(-0.01, -0.012, 0.0825)),
fixedAxis=d01[6], flip=ON)
#: The instance "Packaging-1" is partially constrained with 1 unconstrained translations and 1 unconstrained rotations
session.viewports['Viewport: 1'].view.setValues(session.views['Bottom'])
session.viewports['Viewport: 1'].view.setValues(width=0.15321,
height=0.097941, viewOffsetX=-0.085326, viewOffsetY=-0.060246)
session.viewports['Viewport: 1'].view.setValues(viewOffsetX=-0.10794,
viewOffsetY=-0.055338)
a = mdb.models['circuitBoard'].rootAssembly
a.DatumPointByCoordinate(coords=(-0.5, 0.707, -0.5))
session.viewports['Viewport: 1'].view.fitView()
a = mdb.models['circuitBoard'].rootAssembly
d1 = a.datums
a.DatumPlaneByLinePoint(line=d1[6], point=d1[10])
session.viewports['Viewport: 1'].view.fitView()
session.viewports['Viewport: 1'].view.setValues(width=0.2198, height=0.14051,
viewOffsetX=0.0044844, viewOffsetY=0.060789)
#: Warning: Cannot continue yet--complete the step or cancel the procedure.
a0 = mdb.models['circuitBoard'].rootAssembly
f1 = a0.instances['Packaging-1'].faces
d01 = a0.datums
a0.FaceToFace(movablePlane=f1.findAt(coordinates=(0.0179891354276455,
0.00658330416135736, 0.012563775694313)), fixedPlane=d01[11], flip=ON,
clearance=0.0)
#: The instance "Packaging-1" is partially constrained with 1 unconstrained translations and 0 unconstrained rotations
session.viewports['Viewport: 1'].view.setValues(width=0.12259,
height=0.078369, viewOffsetX=0.0041783, viewOffsetY=0.072575)
session.viewports['Viewport: 1'].view.setValues(cameraPosition=(-0.81827,
-2.6068, -0.096307), cameraUpVector=(-0.13397, 0.048574, 0.98979),
cameraTarget=(0.019855, 0.28341, -0.12471))
session.viewports['Viewport: 1'].view.setValues(cameraPosition=(-1.0124,
-2.5346, -0.24032), cameraUpVector=(-0.13057, 0.0071533, 0.99141),
cameraTarget=(0.019535, 0.29001, -0.1248))
session.viewports['Viewport: 1'].view.setValues(cameraPosition=(-0.017858,
-2.7188, 0.20795), cameraUpVector=(-0.022885, 0.11052, 0.99361),
cameraTarget=(0.0033243, 0.27216, -0.12427))
a0 = mdb.models['circuitBoard'].rootAssembly
v1 = a0.instances['Packaging-1'].vertices
r1 = a0.instances['Floor-1'].referencePoints
a0.CoincidentPoint(movablePoint=v1.findAt(coordinates=(-0.0303476233973587,
-0.0429115394838653, -0.0151738116986794)), fixedPoint=r1[2])
#: The instance "Packaging-1" is fully constrained
a0 = mdb.models['circuitBoard'].rootAssembly
p2 = a0.instances['Packaging-1']
p2.ConvertConstraints()
#: All position constraints of "Packaging-1" have been converted to absolute positions
a0 = mdb.models['circuitBoard'].rootAssembly
p2 = a0.instances['Floor-1']
p2.translate(vector=(0.0, 0.0, -0.0001))
#: The instance Floor-1 was translated by 0, 0, -0.0001 w/respect to the Assembly CS
a0 = mdb.models['circuitBoard'].rootAssembly
p = mdb.models['circuitBoard'].parts['Board']
a0.Instance(name='Board-1', part=p, dependent=ON)
a0 = mdb.models['circuitBoard'].rootAssembly
p1 = a0.instances['Board-1']
p1.translate(vector=(0.51, 0.0, 0.0))
session.viewports['Viewport: 1'].view.fitView()
session.viewports['Viewport: 1'].view.setValues(width=0.27668, height=0.17687,
viewOffsetX=0.0039684, viewOffsetY=0.045919)
session.viewports['Viewport: 1'].view.fitView()
a0 = mdb.models['circuitBoard'].rootAssembly
f1 = a0.instances['Board-1'].faces
f2 = a0.instances['Packaging-1'].faces
a0.ParallelFace(movablePlane=f1.findAt(coordinates=(0.543333333333333, 0.05,
0.0), normal=(0.0, 0.0, 1.0)), fixedPlane=f2.findAt(coordinates=(
0.0272382919150449, 0.0177981609225068, 0.0273814785169062)), flip=OFF)
#: The instance "Board-1" is partially constrained with 3 unconstrained translations and 1 unconstrained rotations
a0 = mdb.models['circuitBoard'].rootAssembly
e1 = a0.instances['Board-1'].edges
e2 = a0.instances['Packaging-1'].edges
a0.ParallelEdge(movableAxis=e1.findAt(coordinates=(0.596604525482204,
0.137963003192081, 0.0307533566177196)), fixedAxis=e2.findAt(coordinates=(
0.0431590254312432, 0.0559914769973559, 0.0527683904196429)), flip=OFF)
#: The instance "Board-1" is partially constrained with 3 unconstrained translations and 0 unconstrained rotations
a0 = mdb.models['circuitBoard'].rootAssembly
e1 = a0.instances['Board-1'].edges
d1 = a.instances['Packaging-1'].datums
a0.CoincidentPoint(fixedPoint=d1[3],
movablePoint=a0.instances['Board-1'].InterestingPoint(
edge=e1.findAt(coordinates=(0.652343827802905, 0.0916453486569404,
-0.0804357827095802)), rule=MIDDLE))
#: The instance "Board-1" is fully constrained
session.viewports['Viewport: 1'].view.fitView()
session.viewports['Viewport: 1'].view.setValues(width=0.22362, height=0.14296,
viewOffsetX=-0.0045625, viewOffsetY=0.10646)
a = mdb.models['circuitBoard'].rootAssembly
d1 = a.instances['Board-1'].datums
a.ReferencePoint(point=d1[2])
a = mdb.models['circuitBoard'].rootAssembly
d1 = a.instances['Board-1'].datums
a.ReferencePoint(point=d1[3])
a = mdb.models['circuitBoard'].rootAssembly
d1 = a.instances['Board-1'].datums
a.ReferencePoint(point=d1[4])
a = mdb.models['circuitBoard'].rootAssembly
r1 = a.referencePoints
refPoints1=(r1[19], )
a.Set(referencePoints=refPoints1, name='TopChip')
#: The set 'TopChip' has been created (1 reference point).
a = mdb.models['circuitBoard'].rootAssembly
r1 = a.referencePoints
refPoints1=(r1[20], )
a.Set(referencePoints=refPoints1, name='MidChip')
#: The set 'MidChip' has been created (1 reference point).
a = mdb.models['circuitBoard'].rootAssembly
r1 = a.referencePoints
refPoints1=(r1[21], )
a.Set(referencePoints=refPoints1, name='BotChip')
#: The set 'BotChip' has been created (1 reference point).
a = mdb.models['circuitBoard'].rootAssembly
session.viewports['Viewport: 1'].setValues(displayedObject=a)
session.viewports['Viewport: 1'].view.setValues(width=0.35526, height=0.22711,
viewOffsetX=-0.0040555, viewOffsetY=0.081617)
session.viewports['Viewport: 1'].view.setValues(width=0.22988, height=0.14695,
viewOffsetX=0.001882, viewOffsetY=0.10537)
session.viewports['Viewport: 1'].assemblyDisplay.setValues(
visibleInstances=('Board-1', ))
a = mdb.models['circuitBoard'].rootAssembly
e1 = a.instances['Board-1'].edges
edges1 = e1.findAt(((0.0153385555521983, 0.0191710250695974,
0.0232637166281098), ))
a.Set(edges=edges1, name='BotBoard')
#: The set "BotBoard" has been created.
session.viewports['Viewport: 1'].assemblyDisplay.setValues(
visibleInstances=('Board-1', 'Floor-1', 'Packaging-1'))
session.viewports['Viewport: 1'].assemblyDisplay.geometryOptions.setValues(
datumPoints=OFF, datumAxes=OFF, datumPlanes=OFF, datumCoordSystems=OFF)
session.viewports['Viewport: 1'].view.setValues(session.views['Bottom'])
a = mdb.models['circuitBoard'].rootAssembly
region=a.sets['TopChip']
mdb.models['circuitBoard'].rootAssembly.engineeringFeatures.PointMassInertia(
name='MassTopChip', region=region, mass=0.005, alpha=0.0, composite=0.0)
region=a.sets['MidChip']
mdb.models['circuitBoard'].rootAssembly.engineeringFeatures.PointMassInertia(
name='MassMidChip', region=region, mass=0.005, alpha=0.0, composite=0.0)
region=a.sets['BotChip']
mdb.models['circuitBoard'].rootAssembly.engineeringFeatures.PointMassInertia(
name='MassBotChip', region=region, mass=0.005, alpha=0.0, composite=0.0)
import step
import regionToolset
import displayGroupMdbToolset as dgm
#: Step module loaded
mdb.models['circuitBoard'].ExplicitDynamicsStep(name='Drop',
previous='Initial', timePeriod=0.02, massScaling=PREVIOUS_STEP)
session.viewports['Viewport: 1'].assemblyDisplay.setValues(step='Drop')
regionDef=mdb.models['circuitBoard'].rootAssembly.sets['TopChip']
mdb.models['circuitBoard'].HistoryOutputRequest(name='H-Output-2',
createStepName='Drop', variables=('U1', 'U2', 'U3', 'UR1', 'UR2', 'UR3',
'V1', 'V2', 'V3', 'VR1', 'VR2', 'VR3', 'A1', 'A2', 'A3', 'AR1', 'AR2',
'AR3'), timeInterval=0.0001, region=regionDef)
mdb.models['circuitBoard'].HistoryOutputRequest('H-Output-3',
mdb.models['circuitBoard'].historyOutputRequests['H-Output-2'])
regionDef=mdb.models['circuitBoard'].rootAssembly.sets['MidChip']
mdb.models['circuitBoard'].historyOutputRequests['H-Output-3'].setValues(
region=regionDef)
mdb.models['circuitBoard'].HistoryOutputRequest('H-Output-4',
mdb.models['circuitBoard'].historyOutputRequests['H-Output-3'])
regionDef=mdb.models['circuitBoard'].rootAssembly.sets['BotChip']
mdb.models['circuitBoard'].historyOutputRequests['H-Output-4'].setValues(
region=regionDef)
regionDef=mdb.models['circuitBoard'].rootAssembly.sets['BotBoard']
mdb.models['circuitBoard'].HistoryOutputRequest(name='H-Output-5',
createStepName='Drop', variables=('S11', 'S22', 'LEP'),
timeInterval=0.0001, region=regionDef, sectionPoints=(1, 5))
import interaction
import regionToolset
import displayGroupMdbToolset as dgm
#: Interaction module loaded
session.viewports['Viewport: 1'].assemblyDisplay.setValues(interactions=ON,
constraints=ON, connectors=ON)
mdb.models['circuitBoard'].ContactProperty('Fric')
mdb.models['circuitBoard'].interactionProperties['Fric'].TangentialBehavior(
formulation=PENALTY, directionality=ISOTROPIC, slipRateDependency=OFF,
pressureDependency=OFF, temperatureDependency=OFF, dependencies=0, table=((
0.3, ), ), shearStressLimit=None, maximumElasticSlip=FRACTION,
fraction=0.005, elasticSlipStiffness=None)
#: The interaction property "Fric" has been created.
mdb.models['circuitBoard'].ContactExp(name='All', createStepName='Drop')
mdb.models['circuitBoard'].interactions['All'].includedPairs.setValuesInStep(
stepName='Drop', useAllstar=ON)
mdb.models['circuitBoard'].interactions['All'].contactPropertyAssignments.appendInStep(
stepName='Drop', assignments=((GLOBAL, SELF, 'Fric'), ))
#: The interaction "All" has been created.
a = mdb.models['circuitBoard'].rootAssembly
s1 = a.instances['Board-1'].faces
side12Faces1 = s1.findAt(((-0.00974285153035949, 0.032710286964063,
0.0651809666638234), ))
a.Surface(side12Faces=side12Faces1, name='Board')
#: The surface "Board" has been created.
a = mdb.models['circuitBoard'].rootAssembly
region1=a.surfaces['Board']
a = mdb.models['circuitBoard'].rootAssembly
region2=a.sets['TopChip']
mdb.models['circuitBoard'].Tie(name='TopChip', master=region1, slave=region2,
positionToleranceMethod=COMPUTED, adjust=ON, tieRotations=OFF)
a = mdb.models['circuitBoard'].rootAssembly
region1=a.surfaces['Board']
a = mdb.models['circuitBoard'].rootAssembly
region2=a.sets['MidChip']
mdb.models['circuitBoard'].Tie(name='MidChip', master=region1, slave=region2,
positionToleranceMethod=COMPUTED, adjust=ON, tieRotations=OFF)
a = mdb.models['circuitBoard'].rootAssembly
region1=a.surfaces['Board']
a = mdb.models['circuitBoard'].rootAssembly
region2=a.sets['BotChip']
mdb.models['circuitBoard'].Tie(name='BotChip', master=region1, slave=region2,
positionToleranceMethod=COMPUTED, adjust=ON, tieRotations=OFF)
import load
import regionToolset
import displayGroupMdbToolset as dgm
#: Load module loaded
session.viewports['Viewport: 1'].assemblyDisplay.setValues(loads=ON, bcs=ON,
fields=ON, interactions=OFF, constraints=OFF, connectors=OFF)
a = mdb.models['circuitBoard'].rootAssembly
r1 = a.instances['Floor-1'].referencePoints
refPoints1=(r1[2], )
a.Set(referencePoints=refPoints1, name='floorRefPt')
#: The set "floorRefPt" has been created.
session.viewports['Viewport: 1'].assemblyDisplay.setValues(step='Initial')
a = mdb.models['circuitBoard'].rootAssembly
region = a.sets['floorRefPt']
mdb.models['circuitBoard'].EncastreBC(name='BC-1', createStepName='Initial',
region=region)
a0 = mdb.models['circuitBoard'].rootAssembly
c1 = a0.instances['Packaging-1'].cells
cells1 = c1.findAt(((0.0108355091608163, 0.0310028088363391,
0.0228442997250458), ))
f1 = a0.instances['Packaging-1'].faces
faces1 = f1.findAt(((0.0375839553254742, 0.0531184959054038,
0.0389955058002604), ), ((0.034042599397909, 0.0548871166732468,
0.0410765581239308), ), ((0.0391836298157272, 0.0533639181330079,
0.0351021027600898), ), ((-0.00372667328917828, -0.00565800572800451,
0.0234541867771533), ), ((0.00957784161762248, 0.0284979213856836,
0.0324434565218871), ), ((0.0345787744886994, 0.0524262471506507,
0.0469635469522516), ), ((0.0108355091608163, 0.0310028088363391,
0.0228442997250458), ), ((0.0272382919150449, 0.0177981609225068,
0.0273814785169062), ), ((0.0242242602961521, 0.024733942963146,
0.0137951501437643), ), ((0.057296018975405, 0.0806280811341163,
0.053965532909445), ))
e1 = a0.instances['Packaging-1'].edges
edges1 = e1.findAt(((0.0585189395132964, 0.0817404761168004,
0.0483738388226317), ), ((0.0145341806137423, 0.0166057647422787,
0.0231139821582351), ), ((-0.00606827334905367, -0.00370531828945841,
0.0226151868206957), ), ((0.0379164855505004, 0.0614293930850632,
0.0478750434850923), ), ((0.0537894100531424, 0.0837891943699307,
0.0520391225230873), ), ((0.00624013055582148, 0.0194947754512711,
0.0315319599890464), ), ((-0.00366876161367417, -0.00333718494805217,
0.0167750822604399), ), ((0.0133691717513551, 0.017814190539547,
0.0220265717283349), ), ((-0.0129474474208814, 0.00200169080152135,
0.0202341132550605), ), ((0.000956526830572513, -0.00956338060509671,
0.0251321866900685), ), ((-0.00653989867775137, -0.00464465108345422,
0.0262148706195112), ), ((0.0506965147840733, 0.0855688196197885,
0.0531921328546275), ), ((0.0315089368073703, 0.0680757349700388,
0.0418942861206416), ), ((0.0431590254312432, 0.0559914769973559,
0.0527683904196429), ), ((0.0571040635272033, 0.078922477734813,
0.0591728902190782), ), ((0.050329130471283, 0.088806964229707,
0.0447694285233588), ), ((0.0457670191984375, 0.0647145651465906,
0.0228835095992187), ), ((0.0574171078223104, 0.0526303071739078,
0.0337576138982201), ))
v1 = a0.instances['Packaging-1'].vertices
verts1 = v1.findAt(((0.0531721586166462, 0.0830009148005934,
0.0555028800181652), ), ((-0.00785053364793706, -0.0032851720615274,
0.0249915338858736), ), ((0.052007149754259, 0.0842093405978617,
0.0544154695882651), ), ((-0.00901554251032435, -0.00207674626425911,
0.0239041234559735), ), ((-0.00260799376719427, -0.00872308814923467,
0.0298848808204242), ), ((0.0467646098735162, 0.089647256685569,
0.0495221226537145), ))
f2 = a0.instances['Board-1'].faces
faces2 = f2.findAt(((-0.00974285153035949, 0.032710286964063,
0.0651809666638234), ))
e2 = a0.instances['Board-1'].edges
edges2 = e2.findAt(((0.0153385555521983, 0.0191710250695974,
0.0232637166281098), ), ((0.0346666829056445, 0.0832542757792721,
0.0737712454875774), ), ((-0.0653649993524251, 0.0153160343301651,
0.105442334724031), ))
r3 = a0.referencePoints
refPoints3=(r3[19], r3[20], r3[21], )
region = regionToolset.Region(vertices=verts1, edges=edges1+edges2,
faces=faces1+faces2, cells=cells1, referencePoints=refPoints3)
mdb.models['circuitBoard'].Velocity(name='Field-1', region=region,
velocity1=0.0, velocity2=0.0, velocity3=-4.43, omega=0.0)
import mesh
import regionToolset
import displayGroupMdbToolset as dgm
#: Mesh module loaded
session.viewports['Viewport: 1'].assemblyDisplay.setValues(mesh=ON, loads=OFF,
bcs=OFF, fields=OFF)
session.viewports['Viewport: 1'].assemblyDisplay.meshOptions.setValues(
meshTechnique=ON)
session.viewports['Viewport: 1'].view.setValues(width=0.056654,
height=0.036218, viewOffsetX=0.0028709, viewOffsetY=-0.030586)
p = mdb.models['circuitBoard'].parts['Board']
e = p.edges
pickedEdges = e.findAt(((0.025, 0.0, 0.0), ), ((0.1, 0.0375, 0.0), ), ((0.0,
0.1125, 0.0), ), ((0.075, 0.15, 0.0), ))
p.seedEdgeByNumber(edges=pickedEdges, number=10)
f = p.faces
faces = f.findAt(((0.033333, 0.05, 0.0), ))
p.setMeshControls(regions=faces, technique=SWEEP)
elemType1 = mesh.ElemType(elemCode=S4R, elemLibrary=EXPLICIT,
secondOrderAccuracy=OFF, hourglassControl=RELAX_STIFFNESS)
elemType2 = mesh.ElemType(elemCode=S3R, elemLibrary=EXPLICIT)
regions =(faces, )
p.setElementType(regions=regions, elemTypes=(elemType1, elemType2))
p.generateMesh()
##
p = mdb.models['circuitBoard'].parts['Floor']
p.seedPart(size=1.0)
#: Global seeds have been assigned.
elemType1 = mesh.ElemType(elemCode=R3D4, elemLibrary=EXPLICIT)
elemType2 = mesh.ElemType(elemCode=R3D3, elemLibrary=EXPLICIT)
f = p.faces
faces = f.findAt(((-0.033333, -0.033333, 0.0), ))
regions =(faces, )
p.setElementType(regions=regions, elemTypes=(elemType1, elemType2))
p.generateMesh()
##
p = mdb.models['circuitBoard'].parts['Packaging']
e = p.edges
edges =(e.findAt(coordinates=(0.0005, 0.0, 0.11)), )
p.seedEdgeByNumber(edges=edges, number=1)
edges = e.findAt(((0.001, 0.009, 0.11), ), ((-0.001, 0.003, 0.11), ), ((
-0.00775, 0.012, 0.11), ), ((0.00325, 0.012, 0.11), ))
p.seedEdgeByNumber(edges=edges, number=3)
edges = e.findAt(((0.01, 0.006, 0.11), ))
p.seedEdgeByNumber(edges=edges, number=6)
edges = e.findAt(((0.005, -0.012, 0.11), ))
p.seedEdgeByNumber(edges=edges, number=7)
edges = e.findAt(((0.01, 0.012, 0.0275), ))
p.seedEdgeByNumber(edges=edges, number=15)
elemType1 = mesh.ElemType(elemCode=C3D8R, elemLibrary=EXPLICIT,
kinematicSplit=AVERAGE_STRAIN, secondOrderAccuracy=OFF,
hourglassControl=ENHANCED)
elemType2 = mesh.ElemType(elemCode=C3D6, elemLibrary=EXPLICIT)
elemType3 = mesh.ElemType(elemCode=C3D4, elemLibrary=EXPLICIT)
c = p.cells
cells = c.findAt(((-0.01, -0.004, 0.073333), ))
regions =(cells, )
p.setElementType(regions=regions, elemTypes=(elemType1, elemType2, elemType3))
p.generateMesh()
##
import job
#: Job module loaded
session.viewports['Viewport: 1'].assemblyDisplay.setValues(mesh=OFF)
session.viewports['Viewport: 1'].assemblyDisplay.meshOptions.setValues(
meshTechnique=OFF)
mdb.Job(name='Circuit', model='circuitBoard', type=ANALYSIS,
explicitPrecision=DOUBLE, description='Circuit board drop test',
userSubroutine='', numCpus=1,
standardMemory=128.0, scratch='', echoPrint=OFF,
modelPrint=OFF, contactPrint=OFF, historyPrint=OFF)
session.viewports['Viewport: 1'].view.fitView()
a = mdb.models['circuitBoard'].rootAssembly
a.regenerate()
mdb.saveAs('Circuit')