You are on page 1of 19

# UofAANSYSTutorial

ANSYS
UTILITIES

BASIC
TUTORIALS

BicycleSpaceFrame
PlaneStressBracket
ModelingTools

TUTORIALS

POSTPROC.
TUTORIALS

COMMAND
LINEFILES

PRINTABLE
VERSION

PlaneStressBracket

TwoDimensionalTruss

INTERMEDIATE

TUTORIALS

|VerificationExample||Preprocessing||Solution||Postprocessing||CommandLine|
|BracketExample||Preprocessing||Solution||Postprocessing||CommandLine|

SolidModeling

Introduction

Index

Contributions

ThistutorialisthesecondofthreebasictutorialscreatedtoillustratecommomfeaturesinANSYS.The
planestressbrackettutorialbuildsupontechniquescoveredinthefirsttutorial(3DBicycleSpace
Frame),itisthereforeessentialthatyouhavecompletedthattutorialpriortobeginningthisone.
The2DPlaneStressBracketwillintroducebooleanoperations,planestress,anduniformpressure

MecE563
MechanicalEngineering
UniversityofAlberta

ProblemDescription
Theproblemtobemodeledinthisexampleisasimplebracketshowninthefollowingfigure.This
bracketistobebuiltfroma20mmthicksteelplate.Afigureoftheplateisshownbelow.

ANSYSInc.

UniversityofAlberta

theright.

VerificationExample
Thefirststepistosimplifytheproblem.Wheneveryouaretryingoutanewanalysistype,youneed
something(ieanalyticalsolutionorexperimentaldata)tocomparetheresultsto.Thiswayyoucanbe
surethatyou'vegottenthecorrectanalysistype,units,scalefactors,etc.
Thesimplifiedversionthatwillbeusedforthisproblemisthatofaflatrectangularplatewithahole
showninthefollowingfigure:

Preprocessing:DefiningtheProblem
1.GivetheSimplifiedVersionaTitle
2.FormGeometry
Booleanoperationsprovideameanstocreatecomplicatedsolidmodels.Theseproceduresmake
iteasytocombinesimplegeometricentitiestocreatemorecomplexbodies.Subtractionwillused
tocreatethismodel,however,manyotherBooleanoperationscanbeusedinANSYS.
a.Createthemainrectangularshape
Preprocessor>Modeling>Create>Areas>Rectangle>By2Corners

Fillinthewindowasshownabove.Thiswillcreatearectanglewherethebottomleft
cornerhasthecoordinates0,0,0andthetoprightcornerhasthecoordinates
200,100,0.
(Alternatively,thecommandlinecodefortheabovecommandisBLC4,0,0,200,100)
b.Createthecircle
Preprocessor>Modeling>Create>Areas>Circle>SolidCircle

Fillinthewindowasshownabove.Thiswillcreateacirclewherethecenterhasthe
mm.
(Alternatively,thecommandlinecodefortheabovecommandisCYL4,100,50,20)
c.Subtraction
Nowwewanttosubtractthecirclefromtherectangle.Priortothisoperation,your
imageshouldresemblethefollowing:

Modeling>Operate>Booleans>Subtract>Areas
Atthispointa'SubtractAreas'windowwillpopupandtheANSYSInputwindow
willdisplaythefollowingmessage:[ASBA]Pickorenterbaseareasfromwhich
tosubtract(asshownbelow)

Therefore,selectthebasearea(therectangle)byclickingonit.Note:Theselected
areawillturnpinkonceitisselected.

Thefollowingwindowmayappearbecausethereare2areasatthelocationyou
clicked.

Ensurethattheentirerectangularareaisselected(otherwiseclick'Next')andthen
click'OK'.
Click'OK'onthe'SubtractAreas'window.
Nowyouwillbepromptedtoselecttheareastobesubtracted,selectthecircleby
clickingonitandthenclick'OK'.
Youshouldnowhavethefollowingmodel:

(Alternatively,thecommandlinecodefortheabovestepisASBA,1,2)
3.DefinetheTypeofElement
Itisnownecessarytodefinethetypeofelementtouseforourproblem:
element,asshownintheabovefigure.

PLANE82isahigherorderversionofthetwodimensional,fournodeelement
modelcurvedboundaries.
Forthisexample,weneedaplanestresselementwiththickness,therefore

Clickonthe'Options...'button.ClickandholdtheK3button,andselect'Planestrsw/thk',
asshownbelow.

(Alternatively,thecommandlinecodefortheabovestepisET,1,PLANE82followedby
KEYOPT,1,3,3)
4.DefineGeometricProperties
Enterathicknessof20asshowninthefigurebelow.Thisdefinesaplatethicknessof
20mm)

(Alternatively,thecommandlinecodefortheabovestepisR,1,20)
5.ElementMaterialProperties
Asshowninpreviousexamples,selectPreprocessor>MaterialProps>Material
models>Structural>Linear>Elastic>Isotropic
WearegoingtogivethepropertiesofSteel.Enterthefollowingwhenprompted:

EX200000
PRXY0.3

(Alternatively,thecommandlinecodefortheabovestepisMP,EX,1,200000followedby
MP,PRXY,1,0.3)
6.MeshSize
TotellANSYShowbigtheelementsshouldbe,Preprocessor>Meshing>SizeCntrls>
ManualSize>Areas>AllAreas

fortheproblem.
(Alternatively,thecommandlinecodefortheabovestepisAESIZE,ALL,25,)
7.Mesh

Nowtheframecanbemeshed.
whenprompted
(Alternatively,thecommandlinecodefortheabovestepisAMESH,ALL)
Youshouldnowhavethefollowing:

SavingYourJob

theresultingsystemofequations.
1.DefineAnalysisType
EnsurethataStaticAnalysiswillbeperformed(Solution>AnalysisType>New
Analysis).
(Alternatively,thecommandlinecodefortheabovestepisANTYPE,0)
2.ApplyConstraints
Asshownpreviously,theleftendoftheplateisfixed.
Selecttheleftendoftheplateandclickon'Apply'inthe'ApplyU,ROTonLines'window.
Fillinthewindowasshownbelow.

ThislocationisfixedwhichmeansthatallDOF'sareconstrained.Therefore,select'All
DOF'byclickingonitandenter'0'intheValuefieldasshownabove.
Youwillseesomebluetrianglesinthegraphicswindowindicatingthedisplacement
contraints.
(Alternatively,thecommandlinecodefortheabovestepisDL,4,,ALL,0)
Whenthewindowappears,selectthelinealongtherighthandedgeoftheplateandclick
'OK'
theplate(1MPa).
Fillinthe"ApplyPRESonlines"windowasshownbelow.NOTE:
Thepressureisuniformalongthesurfaceoftheplate,thereforethelastfieldisleft
blank.
Thepressureisactingawayfromthesurfaceoftheplate,andisthereforedefinedas
anegativepressure.

4.SolvingtheSystem
Solution>Solve>CurrentLS

Postprocessing:ViewingtheResults
1.HandCalculations
Now,sincethepurposeofthisexercisewastoverifytheresultsweneedtocalculatewhatwe
shouldfind.
Deflection:Themaximumdeflectionoccursontherighthandsideoftheplateandwas
calculatedtobe0.001mmneglectingtheeffectsoftheholeintheplate(iejustaflatplate).
Theactualdeflectionoftheplateisthereforeexpectedtobegreaterbutinthesamerangeof
magnitude.
Stress:Themaximumstressoccursatthetopandbottomoftheholeintheplateandwasfound
tobe3.9MPa.
2.ConvergenceusingANSYS
Atthispointweneedtofindwhetherornotthefinalresulthasconverged.Wewilldothisby
lookingatthedeflectionandstressatparticularnodeswhilechangingthesizeofthemeshing
element.
Sincewehaveananalyticalsolutionforthemaximumstresspoint,wewillcheckthestress
atthispoint.Firstweneedtofindthenodecorrespondingtothetopoftheholeintheplate.
Firstplotandnumberthenodes
Theplotshouldlooksimilartotheoneshownbelow.Makeanoteofthenodeclosesttothe
topofthecircle(ie.#49)

Listthestresses(GeneralPostproc>ListResults>NodalSolution>Stress,Principals
SPRIN)andchecktheSEQV(EquivalentStress/vonMisesStress)forthenodein
question.(asshownbelowinred)

Theequivalentstresswasfoundtobe2.9141MPaatthispoint.Wewillusesmaller
elementstotrytogetamoreaccuratesolution.
ResizeElements
Preprocessor>Meshing>SizeCntrls>ManualSize>Areas>AllAreas
nowdecreasetheelementedgelength(ie20)
b.Nowremeshthemodel(Preprocessor>Meshing>Mesh>Areas>Free).Once
youhaveselectedtheareaandclicked'OK'thefollowingwindowwillappear:

c.Click'OK'.Thiswillremeshthemodelusingthenewelementedgelength.
d.Solvethesystemagain(notethattheconstraintsneednotbereapplied).(Solution
Repeatsteps'a'through'd'untilthemodelhasconverged.(notethenumberofthenodeat
thetopoftheholehasmostlikelychanged.Itisessentialthatyouplotthenodesagainto
selecttheappropriatenode).Plotthestress/deflectionatvaryingmeshsizesasshown
belowtoconfirmthatconvergencehasoccured.

Notetheshapesofboththedeflectionandstresscurves.Asthenumberofelementsinthemesh
increases(ietheelementedgelengthdecreases),thevaluesconvergetowardsafinalsolution.
ThevonMisesstressatthetopoftheholeintheplatewasfoundtobeapproximatly3.8MPa.
Thisisamere2.5%differencebetweentheanalyticalsolutionandthesolutionfoundusing
ANSYS.
Theapproximatemaximumdisplacementwasfoundtobe0.0012mm,thisis20%greaterthan
theanalyticalsolution.However,theanalyticalsolutiondoesnotaccountforthelargeholeinthe
centeroftheplatewhichwasexpectedtosignificantlyincreasethedeflectionattheendofthe
plate.
Therefore,theresultsusingANSYSweredeterminedtobeappropriatefortheverificationmodel.
3.Deformation
GeneralPostproc>PlotResults>DeformedShape>Def+undeformdtoviewboth
thedeformedandtheundeformedobject.

Observethelocationsofdeflection.
4.Deflection
GeneralPostproc>PlotResults>NodalSolution...ThenselectDOFsolution,USUM
inthewindow.

Alternatively,obtaintheseresultsasalist.(GeneralPostproc>ListResults>Nodal
Solution...)
Aretheseresultswhatyouexpected?Notethatalltranslationaldegreesoffreedomwere
constrainedtozeroattheleftendoftheplate.
5.Stresses
GeneralPostproc>PlotResults>NodalSolution...ThenselectStress,vonMisesinthe
window.

YoucanlistthevonMisesstressestoverifytheresultsatcertainnodes
GeneralPostproc>ListResults.SelectStress,PrincipalsSPRIN

CommandFileModeofSolution
TheaboveexamplewassolvedusingamixtureoftheGraphicalUserInterface(orGUI)andthe
commandlanguageinterfaceofANSYS.ThisproblemhasalsobeensolvedusingtheANSYS
commandlanguageinterfacethatyoumaywanttobrowse.Openthe.HTMLversion,copyandpaste
inputfrom...'andselectthefile.A.PDFversionisalsoavailableforprinting.

BracketExample

Nowwewillreturntotheanalysisofthebracket.AcombinationofGUIandtheCommandlinewillbe
usedforthisexample.
Theproblemtobemodeledinthisexampleisasimplebracketshowninthefollowingfigure.This
bracketistobebuiltfroma20mmthicksteelplate.Afigureoftheplateisshownbelow.

theright.

Preprocessing:DefiningtheProblem
1.GivetheBracketexampleaTitle
2.FormGeometry
Again,BooleanoperationswillbeusedtocreatethebasicgeometryoftheBracket.
a.Createthemainrectangularshape
Themainrectangularshapehasawidthof80mm,aheightof100mmandthebottomleft
cornerislocatedatcoordinates(0,0)
commandlinewindow)
line'.NowIwillexplainthelinerequiredtocreatearectangle:

BLC4,XCORNER,YCORNER,WIDTH,HEIGHT
BLC4,Xcoord(bottomleft),Ycoord(bottomleft),width,height

Therefore,thecommandlineforthisrectangleisBLC4,0,0,80,100
b.Createthecircularendontherighthandside
Thefollowingcodeisusedtocreateacirculararea:

Therefore,thecommandlineforthiscircleisCYL4,80,50,50
c.Nowcreateasecondandthirdcircleforthelefthandsideusingthefollowingdimensions:
parameter circle2 circle3
XCENTER 0

YCENTER 20

80

20

20

d.Createarectangleonthelefthandendtofillthegapbetweenthetwosmallcircles.
XCORNER 20
YCORNER 20
WIDTH

20

HEIGHT

60

Yourscreenshouldnowlooklikethefollowing...

Youshouldnowhavethefollowingmodel:

f.CreatetheBoltHolesWenowwanttoremovetheboltholesfromthisplate.
Createthethreecircleswiththeparametersgivenbelow:
parameter circle1 circle2 circle3
WPX

80

WPY

50

20

80

30

10

10

Nowselect
Preprocessor>Modeling>Operate>Booleans>Subtract>Areas
Selectthebaseareasfromwhichtosubract(thelargeplatethatwascreated)
Nextselectthethreecirclesthatwejustcreated.Clickonthethreecirclesthatyou
justcreatedandclick'OK'.
(Alternatively,thecommandlinecodefortheabovestepisASBA,6,ALL)
Nowyoushouldhavethefollowing:

3.DefinetheTypeofElement

Asintheverificationmodel,PLANE82willbeusedforthisexample
Usethe'Options...'buttontogetaplanestresselementwiththickness
(Alternatively,thecommandlinecodefortheabovestepisET,1,PLANE82followedby
KEYOPT,1,3,3)
UndertheExtraElementOutputK5selectnodalstress.
4.DefineGeometricContants
Enterathicknessof20mm.
(Alternatively,thecommandlinecodefortheabovestepisR,1,20)
5.ElementMaterialProperties
Preprocessor>MaterialProps>MaterialLibrary>Structural>Linear>Elastic>
Isotropic
WearegoingtogivethepropertiesofSteel.Enterthefollowingwhenprompted:

EX200000
PRXY0.3

(ThecommandlinecodefortheabovestepisMP,EX,1,200000followedbyMP,PRXY,1,0.3)
6.MeshSize
Preprocessor>Meshing>SizeCntrls>ManualSize>Areas>AllAreas
Selectanelementedgelengthof5.Again,wewillneedtomakesurethemodelhas
converged.
(Alternatively,thecommandlinecodefortheabovestepisAESIZE,ALL,5,)
7.Mesh
Preprocessor>Meshing>Mesh>Areas>Freeandselecttheareawhenprompted
(Alternatively,thecommandlinecodefortheabovestepisAMESH,ALL)

SavingYourJob

theresultingsystemofequations.
1.DefineAnalysisType
'Solution'>'NewAnalysis'andselect'Static'.
(Alternatively,thecommandlinecodefortheabovestepisANTYPE,0)
2.ApplyConstraints
Asillustrated,theplateisfixedatbothofthesmallerholesonthelefthandside.
circleofwhichallthenodesinthatareawillbeselected.Forthiscase,select'circle'as
PlotCtrls/Pan,Zoom,Rotate...)Clickatthecenteroftheboltholeanddragthecircle
outsothatittouchesallofthenodesontheborderofthehole.

Clickon'Apply'inthe'ApplyU,ROTonLines'windowandconstrainallDOF'sinthe
'ApplyU,ROTonNodes'window.
Repeatforthesecondbolthole.
Structural>Force/Moment>OnKeypointsSelectaforceintheydirectionof1000)

4.SolvingtheSystem
Solution>Solve>CurrentLS

PostProcessing:ViewingtheResults
oncewedetermineconvergencehasoccured.
1.ConvergenceusingANSYS
Asshownpreviously,itisnecessarytoprovethatthesolutionhasconverged.Reducethe
meshsizeuntilthereisnolongerasizeablechangeinyourconvergencecriteria.
2.Deformation
GeneralPostproc>PlotResults>Def+undeformedtoviewboththedeformedandthe
undeformedobject.
Thegraphicshouldbesimilartothefollowing

Observethelocationsofdeflection.Ensurethatthedeflectionattheboltholeisindeed0.
3.Deflection

ToplotthenodaldeflectionsuseGeneralPostproc>PlotResults>ContourPlot>
NodalSolutionthenselectDOFSolutionUSUMinthewindow.

Alternatively,obtaintheseresultsasalist.(GeneralPostproc>ListResults>Nodal
Solution...)
Aretheseresultswhatyouexpected?Notethatalltranslationaldegreesoffreedomwere
constrainedtozeroattheboltholes.
4.Stresses
GeneralPostproc>PlotResults>NodalSolution...ThenselectvonMisesStressinthe
window.

YoucanlistthevonMisesstressestoverifytheresultsatcertainnodes
GeneralPostproc>ListResults.SelectStress,PrincipalsSPRIN

CommandFileModeofSolution
TheaboveexamplewassolvedusingamixtureoftheGraphicalUserInterface(orGUI)andthe
commandlanguageinterfaceofANSYS.ThisproblemhasalsobeensolvedusingtheANSYS
commandlanguageinterfacethatyoumaywanttobrowse.Openthe.HTMLversion,copyandpaste