Numerical Methods for Engineers
Numerical Methods for Engineers
7th Edition
ISBN: 9780073397924
Author: Steven C. Chapra Dr., Raymond P. Canale
Publisher: McGraw-Hill Education
bartleby

Concept explainers

bartleby

Videos

Textbook Question
Book Icon
Chapter 28, Problem 27P

The basic differential equation of the elastic curve for a uniformly loaded beam (Fig. P28.27) is given as

E I d 2 y d x 2 = w L x 2 w x 2 2

Where E = the modulus of elasticity and I = the moment of inertia. Solve for the deflection of the beam using (a) the finite difference approach ( Δ x = 2 ft ) and (b) the shooting method. The following parameter values apply: E = 30 , 000 ksi , I = 800 in 4 , w = 1 kip/ft,  L = 10 ft Compare your numerical results to the analytical solution,

y = w L x 3 12 E I w x 4 24 E I w L 3 x 24 E I

Chapter 28, Problem 27P, 28.27	The basic differential equation of the elastic curve for a uniformly loaded beam (Fig. P28.27)

FIGURE P28.27

(a)

Expert Solution
Check Mark
To determine

To calculate: The deflection of the beam by the finite-difference method with Δx=2 ft if the differential equation for the elastic curve for a uniformly loaded beam is given as EId2ydx2=wLx2wx22. Also, compare the result with the analytical solution.

Answer to Problem 27P

Solution:

The deflection of the beam by the finite-difference method is,

x y y-Analytical
0 0 0
24 0.00576 0.00557
48 0.009216 0.00892
72 0.009216 0.00892
96 0.00576 0.00557
120 0 0

Explanation of Solution

Given Information:

The differential equation for the elastic curve for a uniformly loaded beam is given as,

EId2ydx2=wLx2wx22

Formula to find analytical value,

y=wLx312EIwx424EIwL3x24EI

Where,

The modulus of elasticity, E=30,000 ksi.

The moment of inertia, I=800 in4.

The values,

w=1 kip/ftL=10 ft

Formula used:

The conversion formula,

1 ft=12 in

The value of second order derivative by finite difference method is given as,

d2Tdx2=Ti+12Ti+Ti1Δx2

Calculation:

Consider the equation,

EId2ydx2=wLx2wx22

Rewrite the above equation as,

d2ydx2=wx2EI(Lx)

Substitute the values, E=30,000 ksi, I=800 in4,w=0.0833 kip/in and L=120 in in the above equation,

d2ydx2=0.0833x2×30000×800(120x)=1.735×109x(120x)=208.2×109x1.735×109x2

Now, the second order derivative by finite difference method gives,

d2ydx2=yi+12yi+yi1(Δx)2

Therefore,

yi+12yi+yi1(24)2=208.2×109xi1.735×109xi2yi+12yi+yi1=576(208.2×109xi1.735×109xi2)yi+12yi+yi1=1.2×104xi1×106xi2

Put i=1 for the first node,

y1+12y1+y11=1.2×104x11×106x12y22y1+y0=1.2×104x11×106x12

The boundary condition is, y0=0 and x1=24.Thus,

y22y1+0=1.2×104(24)1×106(24)2y22y1=2.304×103

Put i=2 for the second node,

y2+12y2+y21=1.2×104x21×106x22y32y2+y1=1.2×104x21×106x22

Substitute x2=48 in the above equation,

y32y2+y1=1.2×104×481×106×(48)2=57.6×1042304×106=3.456×103

Put i=3 for the third node,

y3+12y3+y31=1.2×104x31×106x32y42y3+y2=1.2×104x31×106x32

Substitute x2=72 in the above equation,

y42y3+y2=1.2×104×721×106×(72)2=3.456×103

Put i=4 for the fourth node,

y4+12y4+y41=1.2×104x41×106x42y52y4+y3=1.2×104x41×106x42

Substitute x2=96 and the boundary condition y5=0 in the above equation,

y52y4+y3=1.2×104×961×106×(96)22y4+y3=2.304×103

The matrix form of the above equations is given as below,

[2100121001210012]{y1y2y3y4}={2.304×1033.456×1033.456×1032.304×103}

Use MATLAB to find the solution of the above system as below,

Code:

%Write the matrix

A=[-2 1 0 0; 1 -2 1 0; 0 1 -2 1; 0 0 1 -2];

%write the values of rhs

b=[0.002304 0.003456 0.003456 0.002304]';

%find the result

Y=A\b

Output:

Numerical Methods for Engineers, Chapter 28, Problem 27P , additional homework tip  1

Now, for the analytical value, consider the equation y=wLx312EIwx424EIwL3x24EI.

Substitute the values, E=30,000 ksi, I=800 in4,w=0.0833 kip/in and L=120 in in the above equation,

y=0.0833x12×30000×800(120x2x32(120)32)=2.89236×1010x(120x20.5x3864000)

Use excel to find the values of y at different values of x as below,

Step 1: Name the column A as x and go to column A2 and put 0 then go to column A3 and write the formula as,

=A2+24

Then, Press enter and drag the column up to x=120.

Step 2: Now name the column B as y and go to column B2 andwrite the formula as,

=2.89236*10^(-10)*A2*(120*A2^2-0.5*A2^3-864000)

Step 3: Press enter and drag the column up to x=120.

The result obtained as,

x y-Analytical
0 0
24 0.00557
48 0.00892
72 0.00892
96 0.00557
120 0

(b)

Expert Solution
Check Mark
To determine

To calculate: The deflection of the beam by the shooting method with Δx=2 ft if the differential equation for the elastic curve for a uniformly loaded beam is given as EId2ydx2=wLx2wx22. Also, compare the result with the analytical solution.

Answer to Problem 27P

Solution:

A few values of deflection of the beam by the shooting method is,

x y z
0 0 -1.6E-06
0.25 -4.1E-07 -1.6E-06
0.5 -8.2E-07 -1.6E-06
0.75 -1.2E-06 -1.6E-06
1 -1.6E-06 -1.6E-06
1.25 -2E-06 -1.5E-06
1.5 -2.4E-06 -1.4E-06
1.75 -2.8E-06 -1.4E-06
2 -3.2E-06 -1.3E-06
2.25 -3.5E-06 -1.2E-06
2.5 -3.8E-06 -1.1E-06
2.75 -4.1E-06 -1E-06
3 -4.4E-06 -9E-07

Explanation of Solution

Given Information:

The differential equation for the elastic curve for a uniformly loaded beam is given as,

EId2ydx2=wLx2wx22

Formula to find analytical value,

y=wLx312EIwx424EIwL3x24EI

Where,

The modulus of elasticity, E=30,000 ksi.

The moment of inertia, I=800 in4.

The values,

w=1 kip/ftL=10 ft

Formula used:

The conversion formula,

1 ft=12 in

Calculation:

Consider the equation,

EId2ydx2=wLx2wx22

Rewrite the equation as,

d2ydx2=wLx2EIwx22EI

Assume dydx=z. Thus,

dzdx=wLx2EIwx22EI=w2EI(Lxx2)

Substitute the values, E=30,000 ksi, I=800 in4,w=0.0833 kip/in and L=120 in in the above equation,

dzdx=0.0833×120x2×30000×8000.0833x22×30000×800=1.73542×109(120xx2)

Use VBA program as below to solve the above differential equation as below,

Code:

OptionExplicit

'Create a function find

Subfind()

'declare the variables as integer

Dim n AsInteger, j AsInteger

'declare the variables as double

DimdydxAsDouble, x AsDouble, dy2dx AsDouble, yanalAsDouble, E AsDouble, I AsDouble, w AsDouble, L AsDouble

DimolddydxAsDouble, oldy AsDouble, y AsDouble, h AsDouble

'Set the values of the variables

E =30000

I =800

w =1

L =10

y =0

x =0

h =0.25

dydx=0

'store dydx and analytical solution

dydx= caldydx(w, E, I, L, x)

yanal= caly(w, E, I, L, x)

'use for loop to determine different value of y and y analytical

For j =1 To41

'store the value of y at oldy and dydx in olddydx

oldy = y

olddydx= dydx

'Store d2ydx, dydx and analytical solution

dy2dx = caldy2dx(w, E, I, L, x)

dydx= caldydx(w, E, I, L, x)

yanal= caly(w, E, I, L, x)

'move to the cell b3

Range("b1"). Select

ActiveCell.Value="shooting method"

'Assign name to the columns

ActiveCell.Offset(1,0). Select

ActiveCell.Value="x"

ActiveCell.Offset(0,1). Select

ActiveCell.Value="y"

ActiveCell.Offset(0,1). Select

ActiveCell.Value="z"

ActiveCell.Offset(0,1). Select

ActiveCell.Value="dy2dx"

ActiveCell.Offset(0,1). Select

ActiveCell.Value="y-anal"

'dislay values in cell

Range("b2"). Select

ActiveCell.Offset(j,0). Select

ActiveCell.Value= x

ActiveCell.Offset(0,1). Select

ActiveCell.Value= oldy

ActiveCell.Offset(0,1). Select

ActiveCell.Value= dydx

ActiveCell.Offset(0,1). Select

ActiveCell.Value= dy2dx

ActiveCell.Offset(0,1). Select

ActiveCell.Value= yanal

'Write the next value of x

x = x + h

'Write the next value of y by euler method

y = oldy + olddydx* h

Next

EndSub

'Define d2ydx function

Function caldy2dx(w, E, I, L, x)

'Declare the variables

Dim t AsDouble

'Write the formula

t =((w * L * x)/(2* E * I))-((w * x * x)/(2* E * I))

'Store the value

caldy2dx = t

EndFunction

'Define dydx

Functioncaldydx(w, E, I, L, x)

'Declare the variables

Dim t AsDouble, c AsDouble

'Set the values

c =-0.000001648

'Write the formula

t =((w * L * x * x)/(4* E * I))-((w * x * x * x)/(6* E * I))+ c

'Store the value

caldydx= t

EndFunction

'Define the function caly for analytical value

Functioncaly(w, E, I, L, x)

'Declare the variables

Dim t AsDouble

'Write the formula

t =((w * L * x * x * x)/(12* E * I))-((w * x * x * x * x)/(24* E * I))-((w * L * L * L * x)/(24* E * I))

'Store the value

caly= t

EndFunction

Output:

shooting method
x y z dy2dx y-anal
0 0 -1.6E-06 0 0
0.25 -4.1E-07 -1.6E-06 5.08E-08 -4.3E-07
0.5 -8.2E-07 -1.6E-06 9.9E-08 -8.6E-07
0.75 -1.2E-06 -1.6E-06 1.45E-07 -1.3E-06
1 -1.6E-06 -1.6E-06 1.88E-07 -1.7E-06
1.25 -2E-06 -1.5E-06 2.28E-07 -2.1E-06
1.5 -2.4E-06 -1.4E-06 2.66E-07 -2.5E-06
1.75 -2.8E-06 -1.4E-06 3.01E-07 -2.9E-06
2 -3.2E-06 -1.3E-06 3.33E-07 -3.2E-06
2.25 -3.5E-06 -1.2E-06 3.63E-07 -3.6E-06
2.5 -3.8E-06 -1.1E-06 3.91E-07 -3.9E-06
2.75 -4.1E-06 -1E-06 4.15E-07 -4.2E-06
3 -4.4E-06 -9E-07 4.38E-07 -4.4E-06
3.25 -4.7E-06 -7.9E-07 4.57E-07 -4.6E-06
3.5 -4.9E-06 -6.7E-07 4.74E-07 -4.8E-06
3.75 -5.1E-06 -5.5E-07 4.88E-07 -5E-06
4 -5.2E-06 -4.3E-07 5E-07 -5.2E-06
4.25 -5.4E-06 -3E-07 5.09E-07 -5.3E-06
4.5 -5.5E-06 -1.7E-07 5.16E-07 -5.4E-06
4.75 -5.6E-06 -4.2E-08 5.2E-07 -5.4E-06
5 -5.6E-06 8.81E-08 5.21E-07 -5.4E-06
5.25 -5.6E-06 2.18E-07 5.2E-07 -5.4E-06
5.5 -5.6E-06 3.48E-07 5.16E-07 -5.4E-06
5.75 -5.5E-06 4.76E-07 5.09E-07 -5.3E-06
6 -5.4E-06 6.02E-07 5E-07 -5.2E-06
6.25 -5.3E-06 7.26E-07 4.88E-07 -5E-06
6.5 -5.2E-06 8.46E-07 4.74E-07 -4.8E-06
6.75 -5E-06 9.62E-07 4.57E-07 -4.6E-06
7 -4.8E-06 1.07E-06 4.38E-07 -4.4E-06
7.25 -4.5E-06 1.18E-06 4.15E-07 -4.2E-06
7.5 -4.3E-06 1.28E-06 3.91E-07 -3.9E-06
7.75 -4E-06 1.38E-06 3.63E-07 -3.6E-06
8 -3.7E-06 1.46E-06 3.33E-07 -3.2E-06
8.25 -3.3E-06 1.54E-06 3.01E-07 -2.9E-06
8.5 -3E-06 1.61E-06 2.66E-07 -2.5E-06
8.75 -2.6E-06 1.68E-06 2.28E-07 -2.1E-06
9 -2.2E-06 1.73E-06 1.88E-07 -1.7E-06
9.25 -1.7E-06 1.77E-06 1.45E-07 -1.3E-06
9.5 -1.3E-06 1.8E-06 9.9E-08 -8.6E-07
9.75 -8.7E-07 1.82E-06 5.08E-08 -4.3E-07
10 -4.2E-07 1.82E-06 0 0

Now, to draw the graph of y and y-analytical follow the step as below,

Step 1: Select the cell from B2 to B43 and cell C2 to C43. Then, go to the Insert and select the scatter with smooth lines from the chart.

Step 2: Select the cell from B2 to B43 and cell F2 to F43. Then, go to the Insert and select the scatter with smooth lines from the chart.

Step 3: Select one of the graphs and paste it on another graph to merge the graphs.

The graph obtained is,

Numerical Methods for Engineers, Chapter 28, Problem 27P , additional homework tip  2

Want to see more full solutions like this?

Subscribe now to access step-by-step solutions to millions of textbook problems written by subject matter experts!

Chapter 28 Solutions

Numerical Methods for Engineers

Ch. 28 - An on is other malbatchre actor can be described...Ch. 28 - The following system is a classic example of stiff...Ch. 28 - 28.13 A biofilm with a thickness grows on the...Ch. 28 - 28.14 The following differential equation...Ch. 28 - Prob. 15PCh. 28 - 28.16 Bacteria growing in a batch reactor utilize...Ch. 28 - 28.17 Perform the same computation for the...Ch. 28 - Perform the same computation for the Lorenz...Ch. 28 - The following equation can be used to model the...Ch. 28 - Perform the same computation as in Prob. 28.19,...Ch. 28 - 28.21 An environmental engineer is interested in...Ch. 28 - 28.22 Population-growth dynamics are important in...Ch. 28 - 28.23 Although the model in Prob. 28.22 works...Ch. 28 - 28.25 A cable is hanging from two supports at A...Ch. 28 - 28.26 The basic differential equation of the...Ch. 28 - 28.27 The basic differential equation of the...Ch. 28 - A pond drains through a pipe, as shown in Fig....Ch. 28 - 28.29 Engineers and scientists use mass-spring...Ch. 28 - Under a number of simplifying assumptions, the...Ch. 28 - 28.31 In Prob. 28.30, a linearized groundwater...Ch. 28 - The Lotka-Volterra equations described in Sec....Ch. 28 - The growth of floating, unicellular algae below a...Ch. 28 - 28.34 The following ODEs have been proposed as a...Ch. 28 - 28.35 Perform the same computation as in the first...Ch. 28 - Solve the ODE in the first part of Sec. 8.3 from...Ch. 28 - 28.37 For a simple RL circuit, Kirchhoff’s voltage...Ch. 28 - In contrast to Prob. 28.37, real resistors may not...Ch. 28 - 28.39 Develop an eigenvalue problem for an LC...Ch. 28 - 28.40 Just as Fourier’s law and the heat balance...Ch. 28 - 28.41 Perform the same computation as in Sec....Ch. 28 - 28.42 The rate of cooling of a body can be...Ch. 28 - The rate of heat flow (conduction) between two...Ch. 28 - Repeat the falling parachutist problem (Example...Ch. 28 - 28.45 Suppose that, after falling for 13 s, the...Ch. 28 - 28.46 The following ordinary differential equation...Ch. 28 - 28.47 A forced damped spring-mass system (Fig....Ch. 28 - 28.48 The temperature distribution in a tapered...Ch. 28 - 28.49 The dynamics of a forced spring-mass-damper...Ch. 28 - The differential equation for the velocity of a...Ch. 28 - 28.51 Two masses are attached to a wall by linear...
Knowledge Booster
Background pattern image
Advanced Math
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, advanced-math and related others by exploring similar questions and additional content below.
Recommended textbooks for you
Text book image
Advanced Engineering Mathematics
Advanced Math
ISBN:9780470458365
Author:Erwin Kreyszig
Publisher:Wiley, John & Sons, Incorporated
Text book image
Numerical Methods for Engineers
Advanced Math
ISBN:9780073397924
Author:Steven C. Chapra Dr., Raymond P. Canale
Publisher:McGraw-Hill Education
Text book image
Introductory Mathematics for Engineering Applicat...
Advanced Math
ISBN:9781118141809
Author:Nathan Klingbeil
Publisher:WILEY
Text book image
Mathematics For Machine Technology
Advanced Math
ISBN:9781337798310
Author:Peterson, John.
Publisher:Cengage Learning,
Text book image
Basic Technical Mathematics
Advanced Math
ISBN:9780134437705
Author:Washington
Publisher:PEARSON
Text book image
Topology
Advanced Math
ISBN:9780134689517
Author:Munkres, James R.
Publisher:Pearson,
01 - What Is A Differential Equation in Calculus? Learn to Solve Ordinary Differential Equations.; Author: Math and Science;https://www.youtube.com/watch?v=K80YEHQpx9g;License: Standard YouTube License, CC-BY
Higher Order Differential Equation with constant coefficient (GATE) (Part 1) l GATE 2018; Author: GATE Lectures by Dishank;https://www.youtube.com/watch?v=ODxP7BbqAjA;License: Standard YouTube License, CC-BY
Solution of Differential Equations and Initial Value Problems; Author: Jefril Amboy;https://www.youtube.com/watch?v=Q68sk7XS-dc;License: Standard YouTube License, CC-BY