You are on page 1of 41

NUMERICS:

Lecture 1
Mathematic Modeling and
Engineering Problem Solving and
Approximations and Round-Off
Errors

Isabela Marie Mendez,


ECE, ECT, MTM (ongoing)
Motivation
Numerical methods are techniques where mathematical
problems are formulated so that they can be solved with
arithmetic operations.

Although there are many kinds of numerical methods, they have


one common characteristics: they invariably involve large
numbers of tedious arithmetic calculations

With the dev't of fast, efficient digital computers, the role of


numerical methods in engineering problem solving has increased
dramatically in recent years.
Mathematical areas in numerical methods
1. Roots of Equations
2. Systems of Linear Algebraic Equations
3. Optimization
4. Curve Fitting
5. Integration
6. Ordinary Differential Equations
7. Partial Differential Equations
Roots of
Equations

Systems of
Linear
Algebraic
Equations
Optimization

Curve Fitting
Integration

Ordinary
Differential
Equations
Partial
Differential
Equations
Orientation
Chapter 1:
Mathematical Modeling
and Engineering
Problem Solving
Background

Chapter 1: Over years and years of


observation and experimentation,
Mathematical engineers and scientists have
Modeling and noticed that certain aspects of their
empirical studies occur repeatedly.
Engineering Problem
Solving To understand this behavior,
fundamental knowledge is required
to develop a mathematical model
What is an algorithm?
The Engineering
Problem Solving Process
Mathematical Model
Dependent variable - a characteristic
that usually reflects the state of the
system.
a formulation or equation Independent variables - dimensions
that expresses the essential such as time and space along which
the system's behavior is being
features of a physical determined
Parameters - reflect the system’s
system or process in properties or composition
mathematical terms. Forcing functions - external influences
acting upon the system
Newton's Second Law

States that “the time rate change of momentum of a body is


equal to the resulting force acting on it.”

The model is formulated as


F=ma
1. F = net force acting on the body (N)
2. m = mass of the object (kg)
3. a = its acceleration (m/s2)
Newton's Second Law

Formulation of Newton’s 2nd law has several characteristics


that are typical of mathematical models of the physical
world:

1. It describes a natural process or system in mathematical


terms.
2. It represents an idealization and simplification of reality.
3. Finally, it yields reproducible results, consequently, can be
used for predictive purposes.
A modeling of a falling parachutist
Exact Solution (Analytical Solution)
This is a differential equation and is written in terms of the
differential rate of change dv/dt of the variable that we are
interested in predicting.
If the parachutist is initially at rest (v = 0 at t = 0), using calculus
Example 1: A parachutist of mass 68.1kg jumps out of a
stationary hot air balloon. Use the exact solution to
compute velocity prior to opening the chute. The drag
coefficient is equal to 12.5kg/s
Numerical Solution
In these methods, the mathematical problem is reformulated so it
can be solved by arithmetic operation.
Using Numerical Solution for Example 1:
Comparison of the numerical and analytical
solutions for the falling parachutist problem
Conservation Laws and Engineering

Conservation laws are the most important


and fundamental laws that are used in
engineering.

Change = increases – decreases


Change implies changes with time


(transient). If the change is nonexistent
(steady-state), becomes

Increases = Decreases
Conservation Laws and Engineering

For steady-state incompressible fluid flow


in pipes:

Flow in = Flow out


Chapter 3:
Approximation and
Round-Off Errors
Background

For many applied engineering


problems, we cannot obtain
analytical solutions.

Therefore, we cannot compute


Chapter 3: exactly the errors associated with
Approximation and our numerical methods. In these
cases, we must settle for
Round-Off Errors approximations or estimates of the
errors.

“How much error is present in our


calculation and is it tolerable?”
Significant Figures
An automobile speedometer
Significant Figures
The concept of significant figure has been developed to formally
designate the reliability of a numerical value
The Significant Digits of a number are those that can be used with
confidence.

Example:
53,800 How many significant figures?

4
5.38 x 10
4
5.380 x 10
4
5.3800 x 10

Zeros are sometimes used to locate the decimal point not significant figures.
0.00001753
0.0001753
0.0017534
Accuracy vs. Precision
Accuracy. How close is a computed or measured value to the true
value.
Precision (or reproducibility). How close is a computed or measured
value to previously computed or measured values.
Inaccuracy (or bias). A systematic deviation from the actual value.
Imprecision (or uncertainty). Magnitude of scatter.
Accuracy vs. Precision
Error Definitions
True Value = Approximation + Error True Value

True Error

True Fractional
Relative Error

True Percent Relative Error


Example:
Real-world Applications
One of the challenges of numerical methods is to determine error
estimates in the absence of knowledge regarding the true value

Approximate Percentage
Relative Error
where the subscript a signifi es that the error is
normalized to an approximate value

In case of Iterative Methods, percent relative error is determined


according to:
How Absolute Relative Error used as a
stopping criterion
Computations are repeated until stopping criterion is satisfied

Pre-specified % tolerance based


on your knowledge of the solution
(use absolute value)

If the following criterion is met, you can be sure that the result is correct
to at least n significant figures
Example
Solution to Problem
Determine the error criterion that ensures a result is correct to at least
three significant figures:

A true percent relative error Approximate estimate of error


Solution to Problem
Entire computation summary:

After six terms are included, the approximate error falls below 0.05%
satisfying the criterion.
Round-Off Errors

In addition, because computers use a base-2 representation, they cannot


precisely represent certain exact base-10 numbers.
The discrepancy introduced by this omission of significant figures is called
round-off or chopping errors.
Some machines use chopping, because rounding has additional
computation overhead.
Integer Representation
Integer Representation
The representation of -173 on a 16-bit computer using the signed magnitude
method:
Floating-Point Representation
Fractional quantities are typically represented in computer using “floating
point” form, e.g.,
Thank you for listening!

You might also like