Engineering Computation: An Introduction Using MATLAB and Exce, 2nd Edition Musto - The ebook is ready for download with just one simple click
Engineering Computation: An Introduction Using MATLAB and Exce, 2nd Edition Musto - The ebook is ready for download with just one simple click
com
https://ebookmeta.com/product/engineering-computation-an-
introduction-using-matlab-and-exce-2nd-edition-musto/
OR CLICK HERE
DOWLOAD EBOOK
https://ebookmeta.com/product/engineering-biostatistics-an-
introduction-using-matlab-and-winbugs-1st-edition-brani-vidakovic/
ebookmeta.com
https://ebookmeta.com/product/an-introduction-to-bayesian-inference-
methods-and-computation-nick-heard/
ebookmeta.com
https://ebookmeta.com/product/textile-engineering-an-introduction-2nd-
edition-yasir-nawab/
ebookmeta.com
https://ebookmeta.com/product/customizing-dynamics-365-implementing-
and-releasing-business-solutions-1st-edition-sanjaya-yapa/
ebookmeta.com
Shifter Origins II Series Starter Shifter Variety Packs 2
1st Edition Aimee Easterling Easterling Aimee
https://ebookmeta.com/product/shifter-origins-ii-series-starter-
shifter-variety-packs-2-1st-edition-aimee-easterling-easterling-aimee/
ebookmeta.com
https://ebookmeta.com/product/500-act-science-questions-to-know-by-
test-day-3rd-edition-inc-anaxos/
ebookmeta.com
https://ebookmeta.com/product/the-fetish-of-theology-the-challenge-of-
the-fetish-object-to-modernity-1st-edition-colby-dickinson/
ebookmeta.com
https://ebookmeta.com/product/mechanics-of-the-middle-class-work-and-
politics-among-american-engineers-robert-zussman/
ebookmeta.com
ENGINEERING
COMPUTATIONS
An Introduction Using
MATLAB® and Excel®
Joseph C. Musto
Milwaukee School of Engineering
William E. Howard
East Carolina University
Richard R. Williams
Auburn University
Page ii
ENGINEERING COMPUTATION
Published by McGraw-Hill Education, 2 Penn Plaza, New York, NY
10121. Copyright ©2021 by McGraw-Hill Education. All rights
reserved. Printed in the United States of America. No part of this
publication may be reproduced or distributed in any form or by any
means, or stored in a database or retrieval system, without the prior
written consent of McGraw-Hill Education, including, but not limited
to, in any network or other electronic storage or transmission, or
broadcast for distance learning.
Some ancillaries, including electronic and print components, may not
be available to customers outside the United States.
This book is printed on acid-free paper.
1 2 3 4 5 6 7 8 9 QVS 24 23 22 21 20
ISBN 978-1-260-57071-7
MHID 1-260-57071-1
Cover Image: ©Ingram Publishing
All credits appearing on page or at the end of the book are
considered to be an extension of the copyright page.
The Internet addresses listed in the text were accurate at the time of
publication. The inclusion of a website does not indicate an
endorsement by the authors or McGraw-Hill Education, and McGraw-
Hill Education does not guarantee the accuracy of the information
presented at these sites.
mheducation.com/highered
Page iii
CONTENTS
Preface v
PART 1
Computational Tools 1
CHAPTER 1
Computing Tools 3
Introduction 3
1.1 Analytic and Algorithmic Solutions 4
1.2 Approaches to Engineering Computation 11
1.3 Data Representation 13
CHAPTER 2
Excel Fundamentals 21
Introduction 21
2.1 The Excel Interface 21
2.2 Tutorial: Entering and Formatting Data With Excel 24
2.3 Tutorial: Entering and Formatting Formulas With Excel 29
2.4 Tutorial: Using Built-in Functions 37
2.5 Tutorial: Performing Logical Tests Using the IF Statement
42
2.6 Tutorial: Using Lookup Tables 49
2.7 Tutorial: Interpolating With Excel 53
CHAPTER 3
MATLAB Fundamentals 63
Introduction 63
3.1 The MATLAB Interface 63
3.2 Tutorial: Using the Command Window for Interactive
Computation 65
3.3 Tutorial: Using MATLAB Script Files 74
3.4 Tutorial: Using MATLAB Function Files 81
3.5 Tutorial: Computing With One-Dimensional Arrays 85
3.6 Tutorial: Computing With Two-Dimensional Arrays 92
3.7 Tutorial: Saving a MATLAB Session 96
CHAPTER 4
MATLAB Programming 103
Introduction 103
4.1 Flowcharts 103
4.2 Tutorial: Loop Commands 106
4.3 Tutorial: Logical Branching Statements 115
4.4 Tutorial: Combining Loops and Logic 125
4.5 Tutorial: Formatting MATLAB Output 134
CHAPTER 5
Plotting Data 143
Introduction 143
5.1 Types of Graphs 143
5.2 XY Graphs 147
5.3 Guidelines for Producing Good Graphs 178
5.4 Tutorial: Creating Other Types of Graphs With Excel 180
Page iv
PART 2
Engineering Applications 193
CHAPTER 6
Finding the Roots of Equations 195
Introduction 195
6.1 Motivation 196
6.2 Roots of Equations: Theory 197
6.3 Tutorial: Solution of General Nonlinear Equations Using
MATLAB 207
6.4 Tutorial: Solution of Polynomial Equations Using MATLAB
210
6.5 Tutorial: Solution of General Nonlinear Equations Using
Excel 213
CHAPTER 7
Matrix Mathematics 219
Introduction 219
7.1 Properties of Matrices 219
7.2 Tutorial: Matrix Operations Using Excel 223
7.3 Tutorial: Matrix Operations Using MATLAB 228
CHAPTER 8
Solving Simultaneous Equations 237
Introduction 237
8.1 Systems of Linear Equations 237
8.2 Tutorial: Solutions of Linear Equations Using Excel 238
8.3 Tutorial: Solutions to Simultaneous Linear Equations Using
MATLAB 244
8.4 Tutorial: Solving Nonlinear Simultaneous Equations Using
Excel 248
8.5 Tutorial: Solving Nonlinear Simultaneous Equations Using
MATLAB 250
CHAPTER 9
Numerical Integration 263
Introduction 263
9.1 Concepts From Calculus 263
9.2 Tutorial: Numerical Integration of Functions 267
9.3 Tutorial: Numerical Integration of Measured Data 279
CHAPTER 10
Optimization 289
Introduction 289
10.1 Engineering Optimization 290
10.2 Formulating an Optimization Problem 292
10.3 Solution of an Optimization Problem 294
10.4 Solution of an Optimization Problem Using MATLAB 302
10.5 Solution of an Optimization Problem Using Excel 309
10.6 Tutorial: Engineering Application of Linear Constrained
Optimization 317
INDEX 327
Page v
PREFACE
With this in mind, the text was developed in two parts. The Page vi
first part generally covers the mechanics of programming
and spreadsheet usage; including:
▪ Root finding,
▪ Matrix methods,
▪ Simultaneous equations,
▪ Optimization.
Instructor Resources
Additional resources for instructors are available on the web at
www.mhhe.com/musto2e. These resources include solutions to the
end-of-chapter problems and book figures in PowerPoint format.
Instructors can contact a McGraw-Hill representative for a password.
Acknowledgments
We are grateful to our friends at McGraw-Hill for their support and
encouragement during this project. Theresa Collins, our production
developer, has provided invaluable support and guidance during this
project. We wish to thank Fleck’s Communications for page layout,
and Kim Haas for copyediting. Additionally, the cooperation and
support of the MathWorks Book Program was invaluable.
Feedback provided during the review process was greatly
appreciated, and helped to shape the final form of this text. We wish
to thank the following reviewers for their careful reviews of the initial
manuscript:
Ali Elkamel, University of Waterloo
Bill Elmore, Mississippi State University
Howard Fulmer, Villanova University
Brian Grady, Oklahoma University
Mark Kerstetter, Western Michigan University
Leo Pérez y Pérez, California State University at Long Beach
Michael Robinson, Rose-Hulman Institute of Technology
David Rockstraw, New Mexico State University
Scott Short, Northern Illinois University
Elisa H. Barney Smith, Boise State University
J. Steven Swinnea, University of Texas at Austin
Michael Weinstein, University of Rochester
Students in the Computing Applications in Engineering course at East
Carolina University class tested an early version of this text; their
feedback was appreciated. Also at East Carolina University, Scott
Martin provided a thorough reading and review of this text, and we
thank him for his insight and input.
Joe Musto
Ed Howard
Rick Williams
MATLAB is a registered trademark of TheMathWorks, Inc.
Excel is a registered trademark of The Microsoft Corporation.
Page 1
PART 1
COMPUTATIONAL TOOLS
Chapter 1: Computing Tools
Chapter 2: Excel Fundamentals
Chapter 3: MATLAB Fundamentals
Chapter 4: MATLAB Programming
Chapter 5: Plotting Data
Page 2
Page 3
CHAPTER 1
Computing Tools
Introduction
The engineering profession is a discipline devoted to problem
solving, applying principles of mathematics and science to develop
solutions to practical problems involving structures, machines,
electrical circuits, and various other physical systems and devices.
With their ability to perform numerical analysis and data handling,
computers are important tools for practicing engineers. Engineering
graduates from all disciplines are expected to have proficiency in a
wide range of computational tools and software. New engineering
graduates should expect to have proficiency in:
Figure 1.2
(1.1)
(1.2)
where h is the height of the cannon ball, x is the horizontal distance
travelled, ν is the initial speed of the cannonball, θ is the launch
angle, g is gravitational acceleration, and t is the time after launch
(in seconds). With this model in place, the engineer must now select
a solution technique to solve the equations. We will now contrast the
analytic solution to the algorithmic solution of this problem.
(1.4)
(1.5)
or t = 0.585 seconds. This indicates that the ball will reach its peak
height after 0.585 seconds of flight time. Substituting this value for
time into Equation 1.1 yields:
(1.6)
(1.7)
(1.9)
▪ Step 3: Plug the new value of tnew into Equation 1.1 to get a new
value of h, which we will call hnew.
▪ If h < hnew, then the height is still increasing, and the peak
has not been reached. Set t = tnew, h = hnew, and return to
Step 2.
▪ If h > hnew, then the height has started decreasing. This tells
us that the ball reached its peak somewhere in the
neighborhood of h (either in the interval between h and hnew,
or in the previous interval).
▪ Step 3: Plug the new value of tnew into Equation 1.1 to get a new
value of h, which we will call hnew.
Figure 1.3
Figure 1.4
(1.10)
In this equation, x and y are variables, since they can take on many
values. We often refer to variables as independent or dependent. A
variable is dependent when its value depends on the value of other
variables. Usually we write equations so that the dependent variable
is on the left side of the equal sign. For example, in Equation 1.10,
we would assume that y is the dependent variable, since its value
depends on the value of the independent variable x. Of course, we
could rearrange the equation so that x is on the left side:
(1.11)
(1.12)