


















Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Community
Ask the community for help and clear up your study doubts
Discover the best universities in your country according to Docsity users
Free resources
Download our free guides on studying techniques, anxiety management strategies, and thesis advice from Docsity tutors
lecture number 1 in computational engineering
Typology: Lecture notes
1 / 26
This page cannot be seen from the preview
Don't miss anything!
with MATLAB®
for Engineers and Scientists
4th Edition
with MATLAB®
for Engineers and Scientists
4th Edition
Steven C. Chapra PowerPoints organized by Dr. Michael R. Gustafson II, Duke University andProf. Steve Chapra, Tufts University ©McGraw‐Hill Education. All rights reserved. Authorized only for instructor use in the classroom. No reproduction or further distribution permitted without the prior written consent of McGraw‐Hill Education.
©McGraw‐Hill Education. All rights reserved. Authorized only for instructor use in the classroom. No reproduction or further distribution permitted without the prior written consent of McGraw‐Hill Education.
©McGraw‐Hill Education.
A Simple Mathematical Model A mathematical model can be broadly definedas a formulation or equation that expressesthe essential features of a physical system orprocess in mathematical terms.Models can be represented by a functionalrelationship between dependent variables,independent variables, parameters, andforcing functions.
©McGraw‐Hill Education.
Model Function
Dependent
variable
ൌ
𝑓^
independent
variables
,^
parameters,
forcingfunctions
Dependent variable
the behavior or state of the system Independent variables
space, along which the system’s behavior is beingdetermined Parameters
or composition Forcing functions
system
©McGraw‐Hill Education.
Model Results
Using a computer (or a calculator), the model can be used togenerate a graphical representation of the system. Forexample, the graph below represents the velocity of a 68.1kilogram jumper, assuming a drag coefficient of 0.25kilograms per mile
©McGraw‐Hill Education.
Numerical Modeling
Some system models will be given as implicit functionsor as differential equations - these can be solved eitherusing analytical methods or numerical methods.Example - the bungee jumper velocity equation frombefore is the analytical solution to the differentialequation
𝑑^
2
where the change in velocity is determined by thegravitational forces acting on the jumper versus thedrag force.
©McGraw‐Hill Education.
Euler’s Method
Substituting the finite difference into thedifferential equation gives
𝑑^
2
i
𝑖
i
𝑖
𝑑^
2
Solve for
i
𝑖
𝑑
𝑖^
2
i
𝑖
©McGraw‐Hill Education.
Numerical Results
Applying Euler’s method in 2 s intervals yields: How do we improve the solution?•
Smaller steps
©McGraw‐Hill Education.
Summary of Numerical Methods
©McGraw‐Hill Education. All rights reserved. Authorized only for instructor use in the classroom. No reproduction or further distribution permitted without the prior written consent of McGraw‐Hill Education.
©McGraw‐Hill Education.
Calculator Mode
The MATLAB command widow can be usedas a calculator where you can type incommands line by line. Whenever acalculation is performed, MATLAB will assignthe result to the built-in variable
ans
Example:
ans
MATLAB Syntax
when developing MATLAB programs orsimply using the Command Window as acalculator.
MATLAB Syntax-Variables
between -1.7x
308
to 1.7x
308
(Version
R2014a).
‘>>whos’
used in the
Command Window will list the definedvariables along with their characteristics.
‘>>clear’
removes all
variables from the Command Window.
Special Variables
or smallest number available.
an undefined mathematical operation, e.g.,0/0.
to 15 significant figures.