Vous êtes sur la page 1sur 40

WWW.VIDYARTHIPLUS.

COM

LAB MANUAL

VIDYARTHIPLUS.COM
WWW.VIDYAUS.COM

INDEX

Mark /
S/No Date Experiments
Signature
ANALYSIS
1. Stress Analysis of a Rectangular Plate with Circular Hole

2. Stress Analysis of A Rectangular L-Bracket

3. Stress Analysis of an Axis -Symmetric Component

4. Stress Analysis of Truss


Stress Analysis of Beam
5.
(Cantilever, Simply Supported and Fixed Beam)
6. Mode Frequency analysis of 2d component
Modal Analysis of Beam
7.
(Cantilever, Simply supported and Fixed Beam)
8. Harmonic Analysis of 2D Component

9. Convective Heat Transfer Analysis of a 2D Component

10. Conductive Heat Transfer Analysis of a 2D Element

11. Thermal Stress Analysis of 2D Component

SIMULATION
12. Modal Analysis of a Spring-Mass System

13. Simulation of Air conditioning system

14. Graphing function using Octave

15. Simulation of Spring Mass system

16. Matrix and Graph Plotting


INTRODUCTION TO ANSYS
ANSYS is a general-purpose finite-element modeling package for numerically solving a
wide variety of mechanical problems. These problems include static/dynamic, structural analysis
(both linear and nonlinear), heat transfer, and fluid problems, as well as acoustic and
electromagnetic problems.
ANSYS finite element analysis software enables engineers to perform the following tasks:
 Build computer models or transfer CAD models of structures, products, components, or
systems.
 Apply operating loads or other design performance conditions.
 Study physical responses, such as stress levels, temperature distributions, or
electromagnetic fields.
 Optimize a design early in the development process to reduce production costs.
 Do prototype testing in environments where it otherwise would be undesirable or
impossible (for example, biomedical applications)
1.1 In general, a finite-element solution may be broken into the following three stages.
(i) Preprocessing: defining the problem
The major steps in preprocessing are
(i) define keypoints/lines/areas/volumes,
(ii) define element type and material/geometric properties, and
(iii) mesh lines/areas/ volumes as required.
The amount of detail required will depend on the dimensionality of the analysis, i.e., 1D,
2D, axisymmetric, and 3D.
(ii) Solution: assigning loads, constraints, and solving
Here, it is necessary to specify the loads (point or pressure), constraints (translational and
rotational), and finally solve the resulting set of equations.
(iii) Post processing: further processing and viewing of the results
In this stage one may wish to see (i) lists of nodal displacements, (ii) element forces and
moments, (iii) deflection plots, and (iv) stress contour diagrams or temperature maps.
1.2 ANSYS graphical user interface
There are two methods to use ANSYS. The first is by means of the graphical user interface
or GUI. This method follows the conventions of popular Windows and X-Windows based
programs. The GUI method is exclusively used in this book. The second is by means of command
files. The command file approach has a steeper learning curve for many, but it has the advantage
that the entire analysis can be described in a small text file, typically in less than 50 lines of
commands. This approach enables easy model modifications and minimal file space requirements.
The ANSYS environment contains two windows: the Main Window and an Output Window
.Within the Main Window there are five divisions
(i) Utility Menu: The Utility Menu [A] contains functions that are available throughout the ANSYS
session, such as file controls, selections, graphic controls, and parameters.
(ii) Input Line: The Input Line [B] shows program prompt messages and allows to type in
commands directly.
(iii) Toolbar: The Toolbar [C] contains push buttons that execute commonly used ANSYS
commands. More push buttons can be made available if desired.
(iv) Main Menu: The Main Menu [D] contains the primary ANSYS functions, organizedby
preprocessor, solution, general postprocessor, and design optimizer. It is from this menu that the
vast majority of modeling commands are issued.
(v) Graphics Windows: The Graphics Window [E] is where graphics are shown and graphical
picking can be made. It is here where the model in its various stages of construction and the
ensuing results from the analysis can be viewed.
The Output Window, shown in displays text output from the program, such as listing of data, etc.
It is usually positioned behind the Graphics Window and can be put to the front if necessary.
1.3 Saving and restoring jobs
It is a good practice to save the model at various stages during its creation. Very often the
stage in the modeling is reached where things have gone well and the model ought to be saved at
this point. In that way, if mistakes are made later on, it will be possible to come back to this point.
To save the model, from ANSYSUtilityMenu select, File→Save as Jobname.db. The model will
be saved in a file called Jobname.db, where Jobname is the name that was specified in the Launcher
when ANSYS was first started. It is a good idea to save the job at different times throughout the
building and analysis of the model to backup the work in case of a system crash or other unforeseen
problems. Alternatively, select File → Save as.
Frequently there is a need to start up ANSYS and recall and continue a previous job. There are two
methods to do this:
(1) Using the Launcher. (i) In the ANSYS Launcher, select Interactive and specify the
previously defined jobname. (ii) When ANSYS is running,
(2) select Utility Menu: File: Resume Jobname.db. This will restore as much of the database
(geometry, loads, solution, etc.) as was previously saved. Start ANSYS and select Utility
Menu : File →Resume from and click on the job from the list that appears
1.4 Organization of files
A large number of files are created when ANSYS is run. If ANSYS is started without
specifying a jobname, the name of all files created will be File.*, where the * represents various
extensions described below. If a jobname is specified, say Beam, then the created files will all have
the file prefix, Beam again with various extensions:
beam.db – database file (binary). This file stores the geometry, boundary conditions, and any
solutions. beam.dbb – backup of the database file (binary).
beam.err – error file (text). Listing of all error and warning messages.

beam.out – output of all ANSYS operations (text). This is what normally scrolls in the output
window during ANSYS session.
beam.log – log file or listing of ANSYS commands (text). Listing of all equivalent
2. GENERAL ANALYSIS PROCEDURE IN ANSYS
2.1. PREFERENCES: Define Analysis Type
The "Preferences" dialog box allows you to choose the desired engineering discipline for
context filtering of menu choices. By default, menu choices for all disciplines are shown, with non-
applicable choices "dimmed" based on a set of element types in your model. If you prefer not to see
the dimmed choices at all, you should turn on filtering. For example, turning on structural filtering
completely suppresses all thermal, electromagnetic, and fluid menu topics.
Choose Main Menu> Preferences. The Preferences for GUI Filtering dialog box appears
2.2. PREPROCESSING: Defining the problem
2.2.1. Define the Element Types
1. Choose menu path Main Menu> Preprocessor> Element Type> Add/Edit/Delete.
2. Click on Add. The Library of Element Types dialog box appears.
3. In the scroll box on the left, click once on "Structural Solid."
4. In the scroll box on the right, click once on "beam3."
5. Click on Apply to define it as element type 1.
6. Click on Close in the Element Types dialog box.
2.2.2. Define Material Properties
1. Choose menu path Main Menu> Preprocessor> Material Props> Material Models. The
Define Material Model Behavior dialog box appears.
2. In the Material Models Available window, double-click on the following options:
Structural, Linear, Elastic, Isotropic. A dialog box appears.
3. Type the text EXX in the EX field (for Young's modulus), and .3 for PRXY.
Click on OK. This sets Young's modulus to the parameter specified above. Material Model
Number 1 appears in the Material Models Defined window on the left.
4. Choose menu path Material> Exit to remove the Define Material Model Behavior dialog
box.
2.2.3. Define Real constants
1. ANSYSMainMenu→Preprocessor→Real Constants
2. Select Real Constants in the ANSYS Main
3. Menu as shown
(1) Click Add/Edit/Delete button to open the Real Constants window and click
Add…button.
(2) Then the Element Type for Real Constants window opens. Click OK button.
(3) The Element Type for Real Constants window vanishes and the Real Constants Set
Number 1. for PLANE82 window appears
2.2.4. Create Keypoints
1. Choose menu path Main Menu> Preprocessor> Modeling> Create> Keypoints> In
Active CS. The Create Keypoints in Active Coordinate System dialog box appears.
2. Enter 1 for keypoint number. Type a 0 in each of the X, Y, Z location fields.
3. Click on Apply.
2.2.5. Create Lines
1. Choose menu path Main Menu> Preprocessor> Modeling> Create> Lines> Lines>
Straight Line. The Create Straight Line picking menu appears.
2. Click once on keypoints 1 and 2 to create a line between keypoints 1 and 2.
3. Click on OK.
2.2.6. Set Meshing Density
1. Choose menu path Main Menu> Preprocessor> Meshing> Size Cntrls> Lines> Picked
Lines. The Element Size on Picked Lines picking menu appears.
2. select the line, then press ENTER.
3. Click on OK in the picking menu. The Element Sizes on Picked Lines dialog box appears.
4. Enter number of element divisions and click on OK.
2.2.7. Generate Mesh
1. Choose menu path Main Menu> Preprocessor> Meshing> Mesh> lines> all lines. The
Mesh lines picking box appears.
2. Click on Pick All.
3. Choose menu path Utility Menu> Plot> Elements.
2.2.8. Apply Displacement Boundary Condition
1. Choose menu path Main Menu> Solution> Define Loads> Apply> Structural>
Displacement> on keypoints. The Apply U,ROT on Nodes picking menu appears.
2. Click on Pick All. The Apply U,ROT on Nodes dialog box appears.
3. In the scroll list for DOFs to be constrained, click on "ALL DOF."
4. Click on OK.
2.2.9. Apply Pressure
1. Choose menu path Main Menu> Solution> Define Loads> Apply> Structural>
Pressure> on lines or on beams or on areas. The Apply PRES on Nodes picking menu
appears.
2. Click on Pick All. The Apply PRES on lines dialog box appears.
3. Enter value for Load PRES value and click on OK.
2.2.10. Exit ANSYS
1. Choose QUIT from the ANSYS Toolbar.
2. Choose Quit - No Save!
3. Click on OK.
Stress Analysis of a Rectangular Plate with Circular Hole
Ex No:1 Date:

Aim:

To perform static stress analysis for the given rectangular plate with circular hole using
ANSYS

Description:

A steel plate of dimension ( 100 × 15 × 25mm ) having 3 holes of diameter 3mm,


5mm & 10mm. It is fixed at one end and force of 20 KN acts on the other end of the plate.
The stress induced at the holes due to the force is to be determined.

DIAGRAM:
Φ5mm Φ10mm
Φ3mm

25mm 20KN

25mm 25mm 25mm 25mm

Formula used:
P
1. Normal stress = w−d t

P – Load (N), w – Width of the plate (mm), d – Diameter of hole (mm).

t – Thickness of the plate (mm).

2. Maximum stress = ςN × k f , Kf – Stress concentration factor.

PROCEDURE:

Pre-processing: Defining the Problem

1. Open ANSYS APDL from start menu.


2. Define the type of problem,
Pre-processor → preference → structural → ok
3. Define the Type of Element
Pre-processor → Element Type → Add/Edit/Delete [Add the element: Solid – quad4
node 182 → option → K3 → Plane stress with thickness]
4. Define Geometric Properties
Pre-processor → Real Constants → Add/Edit/Delete [Enter a thickness as 15mm]
5. Element Material Properties
Pre-processor → Material Properties → Material models → Structural → linear →
Elastic → Isotropic [We are going to give the properties of Steel. Enter the following when
prompted: EX – 2.1E5, PRXY – 0.3]
6. Create the main rectangular shape
Pre-processor → Modelling → Create → Areas → Rectangle → By 2 Corners [Enter
the following values: WPX – 0, WPY – 0, Width – 100, Height – 25]
7. Create the circle
Pre-processor → Modelling → Create → Areas → Circle → Solid Circle [Enter the
following values: Circle 1: WPX – 25, WPY – 12.5, Radius – 1.5; Circle 2: WPX – 50,
WPY – 12.5, Radius – 2.5; Circle 3: WPX – 75, WPY – 12.5, Radius – 5]
8. Subtraction of circles
Pre-processor → Modelling → Operate → Booleans → Subtract → Areas [First
select the base area from which the area has to be deleted (rectangle) and then select the area
that has to be deleted (circle).
9. Meshing
Pre-processor → mesh → mesh tool → Areas [set] → select the area → apply →
enter element size as 10 → ok
Click mesh → select the area → ok

Solution Phase: Assigning Loads and Solving

10. Define constraints

Solution → define load → apply → structural → displacement → on lines [Select the


line, select all DOF & click ok]

11. Define load

Solution → define load → apply → structural → pressure → on line [Select the line,
enter the pressure value as 53.33 N/mm2]

12. Solving the System

Solution → Solve → Current LS

Post processing: Viewing the Results

13. Deflection :General Postproc → Plot Results → Nodal Solution → DOF solution → X-
component

14. Stress:General Postproc → Plot Results → Nodal Solution → von mises stress
15. Stress values: General postproc → list result → nodal solution → von mises stress [Note
down the stress values on respective nodes.

Result:
Thus static stress analysis for the given rectangular plate with circular hole has been
successfully done using ANSYS.

Calculation:

1. For 3mm hole


P
ςN = w−d t

P = 20KN ; d = 3mm

w = 25mm ; t = 15mm

20×10 3
ςN = 25−3 ×15

= 60.61 N/mm2

From PSG Data book page 7.10, kf = 2.65 (d/w = 0.12)

ςmax = ςN × k f = 60.61 x 2.65 𝛔𝐦𝐚𝐱 =161.62 N/mm2

2. For 5mm hole


P
ςN = w−d t

P = 20KN ; d = 5mm

w = 25mm ; t = 15mm
20×10 3
ςN = 25−5 ×15

= 66.67 N/mm2

From PSG Data book, kf = 2.5 (d/w = 0.2)

ςmax = ςN × k f = 66.67 x 2.5

𝛔𝐦𝐚𝐱 =166.68 N/mm2

3) For 10mm hole


P
ςN = w−d t

P = 20KN ; d = 10mm

w = 25mm ; t = 15mm
20×10 3
ςN = 25−10 ×15
= 88.89 N/mm2

From PSG Data book, kf = 2.25 (d/w = 0.4)

ςmax = ςN × k f = 88.89 x 2.25

𝛔𝐦𝐚𝐱 =200 N/mm2

Observation:

SL.No Hole size Analytical Simulation

1 3 161.62 136.87

2 5 166.68 144.60

3 10 200 191.48
Stress Analysis of A Rectangular L-Bracket
Ex No: 2 Date:
AIM:
To determine a deform shape and stress analysis for a given L- bracket using ANSYS
software.

FORMULA USED:
M / I = ςb / Y
Where, M - Bending moment, I - Moment of inertia of cross sectional area
ςb - Bending stress Y - Distance from neutral axis to the outer most fiber

PROCEDURE:
Pre-processing: Defining the Problem

1. Preferences > Structural > OK


2. In Pre Processor module, element type for analysis in chosen by Pre- Processor > Element
type > Add > Solid >Quad 4 node 182
2. The Material properties are given by Pre – Processor > Material modal > Linear > Elastic >
Isotropic >Define young’s modulus and Poisson ratio
3. Modeling of the L section
Modeling > Create >Area > Rectangle > By 2 Corners > X=0,Y=0,Width= 335,Height= 70
Modeling > Create >Area > Rectangle > By 2 Corners > X=165,Y=70,Width= 70, Height =
150
Modeling > Create >Area > Circle > Solid circle > X=300, Y=220,Radius=45
Modeling >Operate > Boolean > Add > Areas> Pick all > OK
Modeling > Create >Area > Circle > Solid circle > X=300, Y=220,Radius=35
Modeling >Delete > Areas Only > Pick the areas to be deleted > OK.
4. The area is divided into finite no. of elements by Meshing > mesh tool > Area >Pick
all>Edge Length = 20 >mesh tool > mesh.
Solution Phase: Assigning Loads and Solving

5. The boundary condition is defined at the both end after beam by arresting displacements in
Y- direction by Solution > loads > structural > displacement > on areas >arrest All DOF.
6. Load is applied on the nodes at the top edge by solution> loads >Structural > Force > on
nodes
7. Now the system is ready to solve and is done by solution > solve > current L.S.
Post processing: Viewing the Results
8. By general post processor > Plot result > counter plot > nodal solution.> DOF solution >
displacement
9. The stress is also obtained by General post processor > plot result > counter plot > Nodal
solution> Von-Mises Stress

RESULT:
Thus the deformed shape and stress analysis for the L bracket is done
CALCULATION:
Resolving the forces 5KN Horizontal component P H = P Sin 60°= 4.33 KN
Vertical component PV = P Cos 60° = 5 cos 60 ° = 2.5 KN
Bending moment due to PH :
MH = 4.33x150x100, MH = 649.5x103 N mm
Bending stress ςbh = My /Z ,649.5x103x6/3.5x102 = 22.72 N/mm2
Bending moment due to Pv : MV = 2.5x106x300 = 750 x 103 N mm
Bending moment due to Pv : ςbv = MY /Z, ςbv = 750x103x6/35x102 = 26.33 N\ mm2
Direct stress due to Vertical force PV
ςdv = PV / A = 2.5x 103/ 70x35 = 1.02 N\ mm2
Total Stress = ςbh+ ςbv + ςdv = 50.16 N\ mm
Stress Analysis of an Axis -Symmetric Component
Ex No: 3 Date :

AIM:

To analyze a cylindrical pressure vessel (axis symmetric) for hoop stress and longitudinal
stress

DIAGRAM:

PROCEDURE:

Preprocessing: Defining the Problem:

1. Give example a Title


Utility Menu > File > Change Title...
2. Open preprocessor menu
ANSYS Main Menu > Preprocessor
3. Create Areas
Preprocessor > Modeling > Create > Areas > Rectangle > By Dimensions
4. Add Areas Together
Preprocessor > Modeling > Operate > Booleans > Add > Areas
5. Define the Type of Element
Preprocessor > Element Type > Add/Edit/Delete... For this problem we will use the PLANE2
[Axisymmetric]
6. Define Element Material Properties
Preprocessor > Material Props > Material Models > Structural > Linear > Elastic > Isotropic
7. Define Mesh Size
Preprocessor > Meshing > Size Cntrls>ManualSize> Areas > All Areas [An element edge
length of 2mm]
8. Mesh the frame
Preprocessor > Meshing > Mesh > Areas > Free > click 'Pick All'

Solution Phase: Assigning Loads and Solving:

1. Define Analysis Type


Solution > Analysis Type > New Analysis > Static
2. Apply Constraints
Solution > Define Loads > Apply > Structural > Displacement > Symmetry B.C. > On Lines
Pick the two edges on the left, at x=0. Utility Menu > Select > Entities [Select Nodes and By
Location from the scroll down menus. Click Y coordinates and type in 50] Solution > Define
Loads > Apply > Structural > Displacement > On Nodes > Pick All Constrain the nodes in
the y-direction (UY).
3. Utility Menu > Select > Entities [In the select entities window, click Select All to reselect all
nodes.]

4. Apply Loads

Solution > Define Loads > Apply > Structural > Force/Moment > On Key points [Pick the
top left corner of the area and click OK. Apply a load of 100 in the FY direction. Pick the
bottom left corner of the area and click OK. Apply a load of -100 in the FY direction. ]
5. Solve the System

Solution > Solve > Current LS

Post processing: Viewing the Results

1. Determine the Stress Through the Thickness of the Tube

 Utility Menu > Select > Entities...


Select Nodes > By Location > Y coordinates and type 45, 55 in the Min, Max box.

 General Postproc> List Results > Nodal Solution > Stress > Components SCOMP
2. Plotting the Elements as Axisymmetric

Utility Menu >PlotCtrls> Style > Symmetry Expansion > 2-D Axi-symmetric...

RESULT:
Thus the analyze a cylindrical pressure vessel (axis symmetric) for hoop stress and
longitudinal stress

CALCULATION:

P=1.5MN/m2
P=1.5 N/mm2
d =1000 mm
t=15 mm
pd
ςc = 2t
1.5∗1000
ςC = 2∗15
ςC = 50 N/mm2
Stress Analysis of Truss
Ex No: 4 Date:

Aim: To analyze a truss for a given component using ANSYS.

Pre-processing: Defining the Problem

1. Open ANSYS APDL from start menu.

2. Define the type of problem,

Pre-processor → preference → structural → ok

3. Define the Type of Element

Pre-processor → Element Type → Add/Edit/Delete [Add the element: LINK-


3Dfinite 180]

4. Define Geometric Properties

Pre-processor → Real Constants → Add/Edit/Delete [Enter area value]

5. Element Material Properties

Pre-processor → Material Properties → Material models → Structural → linear →


Elastic → Isotropic [We are going to give the properties of Steel. Enter the following when
prompted: EX – 200GPa, PRXY – 0.3]

6. Create Truss

Pre-processor → Modeling → Create → Keypoint→

Keypoint 1.

0,0,0

Keypoint 2.

1.5 3 0

Keypoint 3.

300
Keypoint 4.

4.5 3 0 and so on

7. Meshing

Pre-processor → mesh → mesh tool → Line [set] → pick all → apply → enter no. of
division 1 → ok

Click mesh → select the line → ok.

Solution Phase: Assigning Loads and Solving:


8. Analysis type Solution → Analysis type → new analysis → static → ok

9. Define constraints

Solution → define load → apply → structural → displacement → on key point [1, 7]


select all DOF & click ok.

11. Define load

Solution → define load → apply → structural →Force/Moment → on keypoint


[Select the keypoint 1,3,5,7 enter the pressure value as 25,28,25,28,36 N/mm2 resp.]

12. Solving the System

Solution → Solve → Current LS.

Post processing: Viewing the Results


13. General Post Processor: Plot the result → Contour Plot→ Nodal Solution → Von mises
Stress.

Plot the result → Contour Plot→ reaction force.

Result

Thus static stress analysis for the given truss has been successfully done using ANSYS.
Stress Analysis of Beam

(Cantilever, Simply Supported and Fixed Beam)


Ex No: 5 Date:

Aim: To perform static stress analysis for the given beams using ansys.

Description:

PROCEDURE:

Pre-processing: Defining the Problem

1. Preference → structural → ok

2. Element type →add → beam → 2node188→ok

3. Material property material model → structural → linear → elastic → isotropic→


Ex (2e3) →PRxy (0.3)→ ok → close.

4. Modeling
CantileverPreprocessor → section → beam → common section → section ID-1 →
select sub type → rectangle → enter L*B (150* 300) → ok

Preprocessor→ modeling → create → keypoints→ in active CS

KEYPOINTS X Y Z
1 0 0 0
2 2000 0 0
3 1000 0 0

Preprocessor → modeling → create → line → straight line → draw the lines


b/w the keypoints

Simply Support

Preprocessor → section → beam → common section → section ID-1 → select sub


type → rectangle → enter L*B (132* 264) → ok
Preprocessor→ modeling → create → keypoints→ in active CS

Key points X Y
1. 0 0
2. 3000 0
3. 4000 0
4. 6000 0

Preprocessor → modeling → create → line → straight line → draw the lines b/w the
keypoints.

Fixed Beam

Preprocessor → section → beam → common section → section ID-1 → select sub


type → rectangle → enter L*B (572* 1144) → ok
Preprocessor→ modeling → create → keypoints→ in active CS

Key points X Y
1. 0 0
2. 4000 0
3. 6000 0
4. 8000 0
Preprocessor → modeling → create → line → straight line → draw the lines
b/w the keypoints
Meshing

Preprocessor→ meshing → mesh tool → set line option → pick line 1→ apply → ok

Select mesh → pick all →ok

Solution Phase: Assigning Loads and Solving:


Cantilever
Solution → define loads → apply →structural → displacement → on keypoints →
select first keypoint → ok → select all DOF → ok

Solution → define loads → apply → structural → force / moment → select third


keypoint 3 → select Fy (30e3) → ok

Solution → define loads → apply → structural → pressure → select element1 →


enter value 40

Solution → solve → current LS → ok

Simply Supported

Solution → define loads → apply →structural → displacement → on keypoints →


select first keypoint → ok → select all DOF → ok

Solution → define loads → apply → structural → force / moment → select third


keypoint 3 → select Fy (20e3) → ok

Solution → define loads → apply → structural → pressure → select element1 →


enter value 40

Solution → solve → current LS → ok

Fixed Beam

Solution → define loads → apply →structural → displacement → on keypoints →


select first keypoint → ok → select all DOF → ok
Solution → define loads → apply → structural → force / moment → select third
keypoint 3 → select Fy (80e3) → ok
Solution → define loads → apply → structural → pressure → select element1 →
enter value 160
Solution → solve → current LS → ok

Post processing: Viewing the Results

General postproc → plot result → deformed shape & undeformed shape

General postprocessor → list result → nodal solution

Utility menu → plot ctrl → animation deformed shape

RESULT:
Thus the stress analysis of beam is performed using ANSYS and results are
plotted.
Mode Frequency analysis of 2d component.
EX NO: 6 DATE:

Aim:

To perform a mode frequency analysis of the given component using ANSYS

Description:

 A simply supported steel plate of dimension (1000 × 500 × 25mm).


 A fixed circular plate with thickness 25mm and diameter 200mm

Diagram:

500

1000

Formula used:

D mπ 2 nπ 2
ω= +
ρ a b

∈ h3
D=
12 1 − γ2

∈ = 2.1 x 1011 N/m2

γ = 0.28 (Poisson Ratio)

ρ = 7700 kg/m3

h = thickness of plate for rectangular lamina

m = number of parts of modal value

n = number of parts value in horizontal direct

ρ
Circular lamina: λ2 = ωa2 D

λ = Wavelength a = radius ω = 2πs

S = Number of parts modal value in radial direction


n = number of parts modal value in circular direction.

Procedure:

Rectangular plate :

Pre-processing: Defining the Problem

1. Open ANSYS APDL from start menu.

2. Define the type of problem,

Pre-processor → preference → structural → ok

3. Define the Type of Element

Pre-processor → Element Type → Add/Edit/Delete [Add the element: Solid -


PLANE82]

4. Define Geometric Properties

Pre-processor → Real Constants → Add/Edit/Delete [Enter a thickness as 25mm]

5. Element Material Properties

Pre-processor → Material Properties → Material models → Structural → linear →


Elastic → Isotropic [We are going to give the properties of Steel. Enter the following when
prompted: EX – 2.1E11, PRXY – 0.3]

Pre-processor → Material Properties → Material models → Structural → Density [


Enter the density value as 7700]

6. Create the main rectangular shape

Pre-processor → Modelling → Create → Areas → Rectangle → By 2 Corners [Enter


the following values: WPX – 0, WPY – 0, Width – 1, Height – .5]

7. Meshing

Pre-processor → mesh → mesh tool → Areas [set] → select the area → apply →
enter element size as 10 → ok

Click mesh → select the area → ok

Solution Phase: Assigning Loads and Solving

8. Analysis type Solution → Analysis type → New analysis → Modal → ok

Analysis type → Analysis Option [ no of modes to extract – 10 ; Nmode number of


modes to expand 10] → ok

9. Define constraints

Solution → define load → apply → structural → displacement → on lines [Select the


left and right lines, select UY & click ok]
Solution → define load → apply → structural → displacement → on lines [Select the
Bottom and top lines, select UX & click ok]

10. Solving the System

Solution → Solve → Current LS

Post processing: Viewing the Results

11. Mode Shape

General Postproc → Read Results → by pick [Select the frequency and click read] →
close, Plot controls → animate → Mode shape [select DOF solution ; Deformed shape] → ok

12. Repeat step 11 for different frequency values.

Circular plate :

Pre-processing: Defining the Problem

1. Define the type of problem,

Pre-processor → preference → structural → ok

2. Define the Type of Element

Pre-processor → Element Type → Add/Edit/Delete [Add the element: Solid -


PLANE82]

3. Define Geometric Properties

Pre-processor → Real Constants → Add/Edit/Delete [Enter a thickness as 25mm]

4. Element Material Properties

Pre-processor → Material Properties → Material models → Structural → linear →


Elastic → Isotropic [We are going to give the properties of Steel. Enter the following when
prompted: EX – 2.1E11, PRXY – 0.3]

Pre-processor → Material Properties → Material models → Structural → Density [


Enter the density value as 7700]

5. Create the circular shape

Pre-processor → Modelling → Create → Areas → circle → solid circle [Enter the


following values: WPX – 0, WPY – 0, Radius = .1]

7. Meshing

Pre-processor → mesh → mesh tool → Areas [set] → select the area → apply →
enter element size as 10 → ok

Click mesh → select the area → ok

Solution Phase: Assigning Loads and Solving

8. Analysis type
Solution → Analysis type → New analysis → Modal → ok

Analysis type → Analysis Option [ no of modes to extract – 10 ; Nmode number of


modes to expand 10] → ok

9. Define constraints

Solution → define load → apply → structural → displacement → on lines [Select


Circumference, select all Dof & click ok]

10. Solving the System

Solution → Solve → Current LS

Post processing: Viewing the Results

11. Mode Shape

General Postproc → Read Results → by pick [Select the frequency and click read] →
close Plot controls → animate → Mode shape [select DOF solution ; Deformed shape] → ok

12. Repeat step 11 for different frequency values. Result:

RESULT:

The mode frequency analysis of given 2D component has been successfully done
using ANSYS.

Calculation:

For Rectangular plate :


∈h 3 2.1 ×10 11 ×0.025 3
D= = = 296698.67
12 1−γ 2 12 1−0.28 2

D mπ 2 nπ 2 296698 .67 π 2 π 2
ω1 = + = +
ρ a b 192.5 1 .5

296698 .67 2π 2 π 2
+
192 .5 1 .5
ω
f1 = 2π =308.34 Hz f2 = = 493.3Hz

296698 .67 3π 2 π 2 296698 .67 π 2 2π 2


+ +
192 .5 1 .5 192 .5 1 .5
f3 = = 801.75Hz f4 = = 1048.36Hz
2π 2π

296698 .67 2π 2 2π 2 296698 .67 4π 2 π 2


+ +
192 .5 1 .5 192 .5 1 .5
f5 = = 1233.36Hz f6 = = 1233.36Hz
2π 2π

296698 .67 3π 2 2π 2 296698 .67 5π 2 π 2


+ +
192 .5 1 .5 192 .5 1 .5
f7 = = 1547.71Hz f8 = = 1788.38Hz
2π 2π
296698 .67 4π 2 2π 2 296698 .67 π 2 3π 2
+ +
192 .5 1 .5 192 .5 1 .5
f9 = = 1973.38Hz f10 = = 2281.72Hz
2π 2π

For circular plate :

D= 296698.67 a = 1m ρ= 192.5 ω= 2πF

ρ
λ2 = ωa2 D

192.5
10.2158 = 2πF1 × 12 F1 = 63.83Hz
296698 .67

192.5
21.26 = 2πF2 × 12 F2 = 132.84Hz
296698 .67

192.5
34.83 = 2πF4 × 12 F4 = 217.63Hz
296698.67

192.5
34.771 = 2πF6 × 12 F6 = 248.5Hz
296698 .67

192.5
51.04 = 2πF7 × 12 F7 = 318.92Hz
296698 .67

192.5
60.82 = 2πF9 × 12 F9 = 380.03Hz
296698 .67

RESULT :

Frequency
Mode M n Mode shape
Analytical Simulated

1 1 1 308.34 307.93

2 2 1 493.3 492.29

3 3 2 801.73 798.97

4 1 3 1048.36 1043.2

5 4 1 1233.36 1226.8

6 2 2 1233.36 1226.8

7 3 2 1541.71 1531.5

8 5 1 1788.4 1774.8

9 4 2 1968.38 1956.6

10 1 3 2281.72 2260.0
Mode M n Mode Wavelength Frequency
shape
λ Analytical simulated

1 0 0 10.158 63.81 63.812

2 0 1 21.26 132.71 132.77

3 0 1 21.26 132.71 132.77

4 0 2 34.83 217.63 217.63

5 0 2 34.83 217.63 217.63

6 1 0 34.73 248.5 248.24

7 0 3 51.04 318.92 318.37

8 0 3 51.04 318.07 318.45

9 1 1 60.82 380.07 379.45

10 1 1 60.82 380.07 379.45


Modal Analysis of Beam
(Cantilever, Simply supported and Fixed Beam)
EX NO: 7 DATE:

Aim:

To perform a mode frequency analysis of the given component using ANSYS

Procedure:
Pre-processing: Defining the Problem

1.Element type → Preprocessor → element type →add → beam → 2node188→ok


2.Material property → Preprocessor → material property → material model → structural →
linear → elastic → isotropic→ Ex (2.1e5) →PRxy (0.3)→Dens→ 7.84e-6 →ok → close.
3.Modeling > Create > Keypoints > inactive CS > 0 > Apply > 1000 > ok
4.Lines > St lines > pick two points > Apply > ok
5.Meshing > Mesh tool > Lines set > Apply > No. of division: 20 > ok

Solution Phase: Assigning Loads and Solving

6. Solution > analysis type > new analysis > modal > ok Pick analysis option and select sub space
7.Analysis option > select Sub space > No. of modes to extract = 5 > No. of modes to expand
= 5 > ok > ok .
Fixed Beam
Load > define load > apply > structural > displacement > on keypoints > click two ends of
beam > ok > All DOF > ok
SS Beam
Load > define load > apply > structural > displacement > on keypoints > click two ends of
beam > ok > UY > ok
Cantilever
Load > define load > apply > structural > displacement > on keypoints > click left ends of
beam > ok > All DOF > ok.
8.Solution > Solve > Current LS > ok

Post processing: Viewing the Results

9.General postprocessor > read result > First / Next set > Plot result > deformed shape > Def
+ undeformed > ok

10.Plot the result

General post processor > read result > last set > plot result > contour plot > nodal solution >
DOF solution > Y – component of displacement > ok

Result: Thus the modal analysis of beam analysis was done.


Harmonic Analysis of 2D Component

EXT: 8 DATE:

Aim: To perform the harmonic analysis of a 2D component using ANSYS

Procedure:
Pre-processing: Defining the Problem

1. Preferences > Structural > OK


2. Preprocessor > Element type > Add/Edit > Add > Beams > 2node188>ok
3. Preprocessor → section → beam → common section → section ID-1 → select sub type
→ rectangle → enter L*B (10* 10) → ok
4. Material prop > Material model > Structural > Linear > Elastic > Isotropic > E: 2e5 ; Pxy:
0.3 > OK Material model > Density > DENS: 7.84e-6 > OK
5. Modeling > Create > Key points > Inactive CS > Apply > 100 > OK Modeling > Create >
Lines > Straight lines (pick 2 points on the window)
6. Meshing > Mesh tool > Line – select line > Apply > Division value – 20 > OK
Solution Phase: Assigning Loads and Solving

7. Load > Define load > Apply > Structural > Displacement > ON keypoint > Click one end
of the beam > OK > All DOF > OK > Force/moment > On nodes > Apply > Fy: -1000 >
OK
8. Solution > Analysis type > New analysis > Harmonic > OK
9. Analysis option > Amplitude and phase > OK
10. Load step option > Output control > Solutions printout > Every substep > OK
11. Time/Frequency > frequency substep > Frequency range (0, 100) > substep; 100 > select
stepped > OK
12. Solve > Current LS > OK
Post processing: Viewing the Results

13. Time history post proc > Click on “Add data” icon > Give DOF solutions > Select Uy >
OK > give value 2 > OK > Click on “List data” icon & look through the answers > close
it > click on “graph data” > close the time history variable dialog box.
14. Plot ctrls > Capture image > File > Save as
15. Plot ctrls > style > graph > modify axes > select single axis (Y axis) > Select logarithm in
Y-component > ok > Plot > replot.

RESULT
Thus the harmonic analysis of a 2D component was done using ANSYS
Convective Heat Transfer Analysis of a 2D Component
EX NO: 9 DATE:

AIM:

To find the convective heat transfer analysis of a 2 D component

DIAGRAM:

PROCEDURE:

Pre-processing: Defining the Problem

1) Preference > Thermal > ok


2) Preprocessor > Element type > Add/edit/delete > add > solid > Quad4node55 > ok
3) Material properties > material models > thermal > conductivity (Enter the value 50 w/mk)
4) Modeling > create > areas > rectangle > by 2 corners (Enter the value w=0.012m;
h=0.1m)
5) Meshing > mesh tool > area set > pick the area > ok > size element > edge length(0.02m)
> okMesh tool > mesh > pick the area > ok
Solution Phase: Assigning Loads and Solving and Post Processing
6) Loads > define loads > apply > thermal > convection > on lines > pick the inside lines >
ok(Enter the value of inside h and inside T) > on lines > pick the outside lines > ok(Enter
the value of outside h and outside T)
7) Solution > solve > current LS
8) See the result in General post processor > list results > nodal solution > DOF solution >
nodal temperature > ok.

RESULT: The temperature and heat flux are shown and results are completed.
Conductive Heat Transfer Analysis of a 2D Element
Ex No: 10 Date:

AIM:

To Conduct heat transfer analysis of a 2-D element for the given example and
determine the temperature at the specified points

FORMULAE USED:

Q = ∆Toverall/R
l1 l2 l3
h1 = k1a1 + k2a2 + k3a3

T1, T2, T3, T4 = Temperatures of wall section


R = Resistance
k1, k2, k3 = Thermal Conductivity (W/mK)
A1, A2, A3 = Area of wall, q = heat flux
PROCEDURE:
 Preprocessing: Defining the Problem

1. Pre-processor >ANSYS Main Menu >


Preprocessor> Thermal
2. Element Type > Add/Edit/Delete> click 'Add' > Select Link 3D conduction 33
3. Real Constants>Add>Select the element>Define Cross-sectional area as 1
4. Material Props > Material Models > Thermal > Conductivity > Isotropic > KXX1 = 1.05
(Thermal conductivity) > Select New Model > KXX2 = 0.15> Select new model> KXX3 =
0.85.
5. Preprocessor > Modeling > Create >Key points>On active CS >By dimensions> X=0,
Y=0, Z=0 , X=0.25, X=0.37, X=0.57. Preprocessor > Modeling > Create >lines>Straight
lines.
6. Meshing > Mesh Attributes>Picked Lines > Pick the line>OK> Define the Material
Number
7. Meshing > Mesh Tool> Pick Lines> OK> Edge Length > .05> OK> Mesh.
Solution Phase: Assigning Loads and Solving
8. Loads > Define Loads > Apply > Thermal > Temperature > On Keypoints> Define The
Temp at T1=850 and T2= 65.
9. Solution > Solve > Current LS
Post processing: Viewing the Results

10. Results Using ANSYS Plot Temperature General Postproc> Plot Results > Contour Plot
> Nodal Solution > DOF solution, Temperature.
11. General Postproc> List Results > Nodal Solution > Report for Node 7 and 9.

Result: Thus the conductive heat transfer analysis of a 2-d element was analysed.
Thermal Stress Analysis of 2D Component
Ex No : 11 Date :

AIM:

To perform thermal stress analysis of a given 2D component using solid works


simulation software.

DIAGRAM

PROBLEM DESCRIPTION:

A rectangular plate of dimensions 50mm×25mm×2.5mm in subjected to a uniform


temperature from 0oC to 38oC. Determine the maximum displacement and normal stress in X
direction. The properties of the plate are, Young’s modulus (E) =2.1×10ˆ5 N/mm2, Poisson’s
ratio (ν) =.28 and thermal coefficient of expansion (α) =1.3×10ˆ-5 K-1

FORMULA USED:

Normal stress in X direction = EαΔΤ


1. Displacement in Y direction = αΔTb(1+ ν)

Where, E → Young’s modulus

α → Thermal co-efficient

ΔΤ → Temperature difference

b → Breadth

ν → Poisson’s ratio
PROCEDURE:

Pre-processor and Define the type of problem


1. Preferences → structural & thermal→ ok
2. Pre-processor → Element Type → Add/Edit/Delete → Add → Solid → Quad 4 node
182 → ok → options → plane strs w/thk → ok → close.
Preprocessor → Real Constants → Add/Edit/Delete → Add → ok → THK = 0.0025m
→ ok → close
3. Pre-processor → Material Properties → Material models → Structural → linear →
Elastic → Isotropic → EX = 2.1×10ˆ11 & PRXY = 0.24 → ok → Thermal expansion
→ Secant coefficient →Isotropic → ALPX = 1.3×10ˆ-5 → ok → close.
4. Pre-processor → Modeling → Create → Areas → Rectangle → By 2 Corners → WP
X – 0, WP Y = 0, Width = .05, Height .025 → ok.
5. Pre-processor → mesh → mesh tool → Areas [set] → select the area → apply →
enter element size = .001 → ok → mesh → select the area → ok
Solution Phase: Assigning Loads and Solving
6. Solution → define loads → apply → structural →temperature → on lines → Pick line
→ ok → VAL1 temperature = 273 → apply → Pick line → ok → VAL1 temperature
= 311 → ok.
7. Solution → Solve → Current LS.

General postprocessor and viewing of result:

8. General Postproc → Plot Results → Contour Plot → Nodal Solution → Nodal


Solution → X component of stress → ok.
9. General postproc → list result → Nodal Solution → Nodal Solution → X component
of stress → ok → Note values from the table.

CALCULATION:

Normal stress in X- direction,

σx = EαΔΤ

σx = 2.1×10ˆ5×1.3×10ˆ-5×38

= 103.74 N/mm2

Displacement in Y-direction

y = αΔTb(1+ ν)

= 1.3×10ˆ-5×38×25×(1+0.25)

= 1.524×10ˆ-2mm

Note: Restrain geometry along X direction and rotation on all directions.

RESULT: Thus the thermal stress analysis of 2D component has been done and results are
obtained.
Modal Analysis of a Spring-Mass System
EXP:12 Date:
Aim: To Perform the modal analysis of Spring-Mass System.

x1 x2

K= 5 N/m K= 20 N/m
M= 2 kg M= 1 kg

Procedure:
Preprocessor -> Element Type -> Add/Edit/Delete> click 'Add'>solid>quad 4 node 182
Element Type -> Add/Edit/Delete> click 'Add'>Combination>Spring Damper
Material Props -> -Constant- Isotropic
[Enter “1” in the “EX” input field (EX is the modulus of elasticity), and enter “2” in the
“DENS” input field, as shown, then click on “APPLY”. Note that an arbitrary value was
entered for EX, because we will couple all DOF on each mass so that they move as rigid
bodies. So, the modulus of elasticity for each mass, in this particular analysis, is irrelevant.
However, we chose the density to produce a block of mass=2 kg. Our block will have a
volume of 1 m3.
After entering the input, click on “APPLY”. The “Isotropic Materials Box” should be
showing on the screen, and at this point, the material number is still set to “1”. Change the
material number to “2”, and click on “OK”. The material properties box, like that below, re-
opens. Again, enter “1” for EX, but this time, enter “1” for density. Click on “OK”.]

Real Constant
Preprocessor -> Real Constants -> Add/Edit/Delete -> Add > “Type 2 COMBIN14” For real
constant set “1”, choose “K=5”, Leave the other fields blank, and click on “Apply”.
Then, change the Set Number to “2”, and enter a value of “20” for K, then click on “OK”,
then “Close”.

Modeling
Preprocessor -> Modeling- Create -> -Areas- Rectangle -> By Dimensions
Fill in (X1,X2)=(5,6), and (Y1,Y2)=(0,1), >“Apply”.
Fill in (X1,X2)=(11,12), and (Y1,Y2)=(0,1), > “OK”.

Meshing

Meshing- Size Cntrls -> -Lines- Picked Lines ->Pickall-> No. Of Division->1

Meshing of mass-1

Plot -> Areas


Preprocessor -> -Meshing- Mesh -> -Areas- Mapped -> 3 or 4 sided [“Mesh Areas” at the top
of the menu). Click on the block on the left (which will be the 2 kg mass]

Plot -> Areas

Preprocessor -> -Modeling- Create -> Elements -> Elem Attributes

Change the [MAT] entry to “2”,->Ok

Meshing of mass-2

Preprocessor -> -Meshing- Mesh -> -Areas- Mapped -> 3 or 4 sided [“Mesh Areas” at the top
of the menu). Click on the block on the right (which will be the 1 kg mass]

Create a node at the wall:

Preprocessor –> Create -> Nodes -> In Active CS->x,y,z=0,0,0

“PlotCtrls”, then “Numbering”, and the box below opens.

Create the spring elements

Preprocessor -> -Modeling- Create -> Elements -> Elem Attributes ->element 2
combine14
A picking menu opens. It should be that the numbered nodes are plotted on screen at this
time. Node number 9 should be the node at the wall, and node number 1 should be the node
at the bottom left-hand side of the 2 kg mass. Click once, with the left mouse button, on node
9, then click again, once, on node 1. Then, in the picking menu, click on “OK”
Now, before creating the other spring, the real constant set number needs to be changed to set
2, because the spring constant is different for the two springs. To do this, use the path:

Preprocessor -> -Modeling- Create -> Elements -> Elem Attributes

In the box that opens, change the [REAL] entry to “2”. No other changes are needed at this
time, so click “OK”. Then, choose:

Preprocessor -> -Modeling- Create -> Elements -> -Auto Numbered – Thru Nodes

A picking menu opens. Node number 2 should be the node at the bottom-right corner of the
left-hand mass, and node 5 should be the node at the bottom-left corner of the right-hand
mass. Click once, with the left mouse button, on node 2, then click again, once, on node 5.
Then, in the picking menu, click on “OK”.

Plot the elements, by choosing, on the top toolbar: Plot-> Elements

Apply constraints
Preprocessor -> Loads -> Apply -> Displacement -> On Nodes
A picking menu applies. We want this constraint to apply to all nodes in the model. So, in
the picking menu, choose “Pick All”. Another box opens. Be sure to Un-highlight “All
DOF”, by clicking on it. Then, highlight “UY” and “UZ” by clicking on these labels, as
shown, and then click on “Apply”.
The picking menu should remain open. Click on the node at the wall (this should be node
number 9), and then click on “OK” in the Picking Menu. This node should not move in any
direction. So, choose, in the box that opens, as shown on the previous page, click on “All
DOF”, and then click on “OK”.

Make rigid body constraints for each mass

Preprocessor -> Coupling / Ceqn -> Couple DOFs

A picking menu opens. Click on nodes 1-2-3-4, to highlight all four nodes that define the
left-hand mass. Then, in the Picking Menu, click on “Apply”. A box, as shown below,
opens. Enter “1” for “NSET”, as shown, and leave the label “UX” for “Lab”. Then, click on
“Apply”.
The picking menu should re-open. Click on nodes 5-6-7-8, to highlight all four nodes that
define the right-hand mass. Then, in the Picking Menu, click on “OK”. A box, as shown
above, re-opens. This time, Enter “2” for “NSET”, and again leave the label “UX” for “Lab”.
Then, click on “OK”.

Specify analysis type and options

Solution -> Analysis Type New Analysis-> Modal -> “OK”.


Solution -> Analysis Options
Enter “2” for “No. of modes to extract” and “2” for “NMODE No. of modes to expand”.
Choose “OK”, and the box at bottom opens. Enter “1000” for “FREQE”, as shown, then
click on “OK”.
Solve- Current LS

Postproc -> Results Summary

General Postproc -> -Read Results- First Set, Read Results- Next Set

General Postproc -> List Results -> Nodal Solution.

Result: Thus the modal analysis of Spring mass System was done.
Simulation of Air conditioning system

Exp: Date:

Aim: To calculate COP of air conditioning system using evaporator and condenser temperature.

Program:

T2
Formaula: COP= , T1-Evporator Temp. in 0C, T2-Condensor Temp. in 0C
T1  T 2

>> T1=30;

>>T2=linspace(1,25,25);

>> COP=T2\T1-T2

>>plot(T2,COP);

>>xlabel(‘Condenser Temperature\Cir C’);

>>ylabel(‘COP’);

>>title(‘COP of Air Conditioning System);

>>grid on;

Result: Thus the calculation of COP of AC was done


Graphing function using Octave

Exp: Date:

AIM: To plot a different types Graphing function in octave

Program:

1. The plot(x,y) and area(x,y)Function

1 >> x = linspace(0,100,100);
2 >> y = x.ˆ2
3 >> plot(x,y)
4>>area(x,Y)
2. The bar(), barh(), and hist() Functions
1 >> x = [1,2,3,4,5,6];
2 >> y = [0.5,2.2,0.7,1.5,2.5,0.9];
3>>figure
4 >> bar(x,y)
5>>Figure
6>>barh(x,y)
7>>figure
8 >> z = rande(100);
9>> hist(z)
3. Plotting Multiple Plots on the Same Graph Using M-file
clear all;

clf;

x = linspace(1,100,100);

y1 = x.^2.0;

y2 = x.^2.1;

y3 = x.^2.2;

y4 = x.^2.3;

plot(x,y1,"@12",x,y2,x,y3,"4",x,y4,"+")

grid on

legend('xˆ2','xˆ{2.1}','xˆ{2.2}','xˆ{2.3}');

xlabel('x-axis')

ylabel('y-axis')
title('Multiple Graphs')

%plot y with points of type 2 (displayed as '+')

%and color 1 (red), y2 with lines, y3 with lines

%of color 4 (magenta) and y4 with points displayed as '+'

%@12 12th line.

4. The pie() Function

x = [3,2,1,4,1,2];

figure;

h=pie(x);

5. The surf() Function

a = b = linspace(-8,8,10)';

[xx,yy] = meshgrid(a,b);

c = sqrt(xx.^2 + yy.^2) + eps;

d = sin(c)./c;

surf(c,d);

6. The Mesh and Meshc function

tx = ty = linspace (-8, 8, 41)';

[xx, yy] = meshgrid (tx, ty);

r = sqrt (xx .^ 2 + yy .^ 2) + eps;

tz = sin (r) ./ r;

mesh (tx, ty, tz);

figure

meshc(tx,ty,tz)

Result: Thus the Graphing function of octave was studied.


Simulation of Spring Mass system

EXP: Date

Aim: To simulate the Spring mass system with damper

Program:

k=100;

m=10;

x0=1;

x0d=0;

t=0:0.01:10

w=sqrt(k/m);

x=x0*cos(w*t)+((x0d/w)*sin(w*t));

figure;

plot(t,x,'k');

xlabel('Time (s)');

ylabel('x(t)');

axis([0 10 -2 2]);
Matrix and Graph Plotting
EXP: Date:

m = 1;

k = 1;

dy_dt = @(t,y) [y(2);...

-(k/m) * y(1) ];

odeopt = odeset('RelTol', 0.00001, 'AbsTol', 0.00001,'InitialStep',0.5,'MaxStep',0.5);

[t,y] = ode45(dy_dt,[0 25], [0.0 1.0],odeopt);

subplot(1,2,1);

plot(t,y(:,1),'r-',t,y(:,2),'b-');

xlabel('time');

ylim([-1.2 1.2]);

legend('y1(t)','y2(t)');

subplot(1,2,2);

plot(y(:,1),y(:,2),'b-');

xlabel('y(2)');

ylabel('y(1)');

xlim([-1.2 1.2]);

ylim([-1.2 1.2]);

Vous aimerez peut-être aussi