0% found this document useful (0 votes)
45 views84 pages

MATH130 Lec 2.0 Review of Mathematical Functions

Numerical solution

Uploaded by

kentdiocares
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
45 views84 pages

MATH130 Lec 2.0 Review of Mathematical Functions

Numerical solution

Uploaded by

kentdiocares
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 84

MATH 130:

NUMERICAL
SOLUTIONS TO CE
PROBLEMS
ENGR. OWEN FRANCIS A. MAONGAT, CE, RMP, RES, SO2
Instructor
1st Sem, SY 2024-2025
Lecture No. 1
Numerical Solutions to CE Problems – Introduction
Desired Learning Outcomes (DLO)

• To evaluate the students' ability to comprehend and apply


the mathematical foundations relevant to civil engineering
problems.
Numerical Solutions to CE Problems – Introduction
Numerical Methods
 Numerical methods are techniques by which mathematical
problems are formulated so that they can be solved with
arithmetic and logical operations.
 Because digital computers excel at performing such
operations, numerical methods are sometimes referred to as
computer mathematics.
 MATLAB software will be used in this course. It is a high-level
computer language for scientific computation and data
visualization built around an interactive programming
environment.
Numerical Solutions to CE Problems – Introduction
Numerical Methods

 It is becoming the premier platform for scientific computing at


educational institutions and research establishments.

 The great advantage of an interactive system is that


programs can be tested and debugged quickly, allowing the
user to concentrate more on the principles behind the
program and less on programming itself.
Numerical Solutions to CE Problems – Introduction
1.1 Physical Meaning of Derivatives and Integrals
 Foundational working tools in calculus, the derivative and
integral permeate all aspects of modeling nature in the physical
sciences.
Numerical Solutions to CE Problems – Introduction
The derivative of a function can be as the slope of the curve of
the mathematical function f(x) plotted as a function of x.
geometrically interpreted

Its importance lies in the fact that many physical entities such
as velocity, acceleration, force and so on are defined as
instantaneous rates of change of some other quantity.

The derivative can give you a precise instantaneous value for


that rate of change and lead to precise modeling of the desired
quantity.
Numerical Solutions to CE Problems – Introduction
The integral of a function can be geometrically interpreted as
the area under the curve of the mathematical function f(x)
plotted as a function of x.

The integral gives you a mathematical way of drawing an


infinite number of blocks and getting a precise analytical
expression for the area.

The area of a little block under the curve can be thought of as


the width of the strip weighted by (i.e, multiplied by) the height
of the strip.
Numerical Solutions to CE Problems – Introduction
Many properties of continuous bodies depend upon weighted
sums, which to be exact must be infinite weighted sums – a
problem tailor-made for the integral.

For example, finding the center of mass of a continuous body


involves weighting each element of mass by its distance from
an axis of rotation, a process of which the integral is necessary
if you are going to get a precise value.

A vast number of physical problems involve such infinite sums


in their solutions, making the integral an essential tool for the
physical scientist.
Numerical Solutions to CE Problems – Introduction
1.2 Analytical and Numerical Analysis
 The solutions of engineering problems can be obtained using
analytical methods or numerical methods.

 Analytical differentiation and integration provide a closed-form


derivative and integral, respectively, only for simple functions.

 Very often analytical solutions cannot be obtained.

 Numerical methods can be used where analytical methods are not


capable of or practical for providing solutions.
Numerical Solutions to CE Problems – Introduction
1.2 Analytical and Numerical Analysis

The procedure for solving a problem

1. Identify the problem


2. State the objectives
3. Develop alternative solutions
4. Evaluate the alternatives
5. Implement the best alternative
Numerical Solutions to CE Problems – Introduction
Analytical vs Numerical Analysis

To find minimum of y = – 3x +2

Analytical: after differentiate 2x - 3


the minimum solution occurs at x = 1.5

Numerical: define the interval from 1 to 2 increment of 0.20,


min falls in 1.4 < x < 1.6

To improve the accuracy, we can search in 1.4 < x < 1.6 with
a small increment, such as 0.04.
Numerical Solutions to CE Problems – Introduction
Analytical VS Numerical Analysis

 Analytical techniques provide a direct solution and will


result in exact solution if one exists.

 Analytical methods are practical only for functions that


have a simple, closed-form mathematical structure.
Numerical Solutions to CE Problems – Introduction
Analytical VS Numerical Analysis

 Numerical methods can be used with any function. They


often require many iterations to get the true solution.

 The numerical solution usually is not exact, and it is also


necessary to provide initial estimates of the unknowns.
Numerical Solutions to CE Problems – Introduction
1.3 Taylor Series Expansion
 A Taylor series is an infinite series of mathematical terms
that when summed together approximate a mathematical
function.
• Formula:
Numerical Solutions to CE Problems – Introduction
1.3 Taylor Series Expansion
 Convergence of Taylor Series

• Definition: The range over which the series conveges to the


function.
• Radius of Convergence: The distance from the center a within
which the series converges
Numerical Solutions to CE Problems – Introduction
1.3 Taylor Series Expansion
 Application of Taylor Series
 Uses in Engineering and Sciences
*Approximation complex functions
*Solving differential equations
*Numerical Analysis
 Example Applications: Physics (quantum mechanics, wave
functions), Finance (option pricing models)
Numerical Solutions to CE Problems – Introduction
1.3 Taylor Series Expansion
 Limitation of Taylor Series
 Accuracy depends on the number of terms.
 May not converge for some functions or intervals.

 Conclusion
 Summary: Taylor series is a powerful tool for approximating
functions and analyzing mathematical problems.
 Key Takeway: Understanding the basics of Taylor series is crucial
for advanced mathematical applications.
Numerical Solutions to CE Problems – Introduction
1.3 Taylor Series Expansion
• A Maclaurin Series, it is a special case when a = 0

• Formula:
Numerical Solutions to CE Problems – Introduction
1.3 Taylor Series Expansion

SAMPLE
PROBLEM NO.PROBLEM
1: Given the function around

Find the first three non-zero terms of the Taylor series expansion of f(x) centered at x = 3
Numerical Solutions to CE Problems – Introduction
1.3 Taylor Series Expansion

SAMPLE PROBLEM (Continuation)


Numerical Solutions to CE Problems – Introduction
1.3 Taylor Series Expansion

SAMPLE PROBLEM (Continuation)


Numerical Solutions to CE Problems – Introduction
1.3 Taylor Series Expansion

SAMPLE PROBLEM (Continuation)

This is the Taylor series expansion of the function around


Numerical Solutions to CE Problems – Introduction
1.3 Taylor Series Expansion

OTHER SAMPLES
Numerical Solutions to CE Problems – Introduction
1.3 Taylor Series Expansion

OTHER SAMPLES
Numerical Solutions to CE Problems – Matrix and Vector
1.4 Definition of a Matrix
 A matrix is a rectangular array of numbers, symbols, or
expressions arranged in rows and columns.
 The individual items in a matrix are called elements or
entries.
 Matrices are often used in various branches of mathematics,
including linear algebra, for solving systems of linear
equations, transformations, and more
Numerical Solutions to CE Problems – Matrix and Vector
1.4 Definition of a Matrix
 A matrix is defined as a rectangular array of quantities
arranged in rows and columns.
 A matrix with m rows and n columns can be expressed as
follows.
Numerical Solutions to CE Problems – Matrix and Vector
1.4 Definition of a Matrix
 As shown in Eq. (2.1), matrices are denoted either by boldface
letters (A) or by italic letters enclosed within brackets, [A].
 The quantities forming a matrix are referred to as its elements.
 The elements of a matrix are usually numbers, but they can be
symbols, equations, or even other matrices (called
submatrices).
 Each element of a matrix is represented by a double-
subscripted letter, with the first subscript identifying the row
and the second subscript identifying the column in which the
element is located.
Numerical Solutions to CE Problems – Matrix and Vector
1.4 Definition of a Matrix
 Thus, in Eq. (2.1), A23 represents the element located in the
second row and third column of matrix A. In general, Aij refers
to an element located in the ith row and jth column of matrix A.
 The size of a matrix is measured by the number of its rows and
columns and is referred to as the order of the matrix.
 Thus, matrix A in Eq. (2.1), which has m rows and n columns,
is considered to be of order m x n (m by n).
Numerical Solutions to CE Problems – Matrix and Vector
1.4 Definition of a Matrix
 As an example, consider a matrix D given by

 The order of this matrix is 4 x 3, and its elements are


symbolically denoted by Dij with i = 1 to 4 and j = 1 to 3; for
example, D13 = 37, D31 = 12, D42 = 29, etc.
Numerical Solutions to CE Problems – Matrix and Vector
1.4.1 Types of Matrices
 Column Matrix (Vector)

 If all the elements of a matrix are arranged in a single column


(i.e., n =1), it is called a column matrix. Column matrices are
usually referred to as vectors, and are sometimes denoted by
italic letters enclosed within braces. An example of a column
matrix or vector is given by
Numerical Solutions to CE Problems – Matrix and Vector
1.4.1 Types of Matrices
 Row Matrix

 A matrix with all of its elements arranged in a single row (i.e.,


m = 1) is referred to as a row matrix. For example,
Numerical Solutions to CE Problems – Matrix and Vector
1.4.1 Types of Matrices
 Squre Matrix

 If a matrix has the same number of rows and columns (i.e., m


= n), it is called a square matrix.
 An example of a 4 x 4 square matrix is given by
Numerical Solutions to CE Problems – Matrix and Vector
1.4.1 Types of Matrices
 Square Matrix

 As shown in Eq. (2.2), the main diagonal of a square matrix


extends from the upper left corner to the lower right corner,
and it contains elements with matching subscripts—that is,
A11, A22, A33, . . . , Ann. The elements forming the main
diagonal are referred to as the diagonal elements; the
remaining elements of a square matrix are called the off-
diagonal elements.
Numerical Solutions to CE Problems – Matrix and Vector
1.4.1 Types of Matrices
 Symmetric Matrix

 When the elements of a square matrix are symmetric about


its main diagonal (i.e., Aij = Aji), it is termed a symmetric
matrix.
 For example,
Numerical Solutions to CE Problems – Matrix and Vector
1.4.1 Types of Matrices
 Lower Triangular Matrix

 If all the elements of a square matrix above its main diagonal


are zero, (i.e., A ij = 0 for j > i), it is referred to as a lower
triangular matrix.
 An example of a 4 x 4 lower triangular matrix is given by
Numerical Solutions to CE Problems – Matrix and Vector
1.4.1 Types of Matrices
 Upper Triangular Matrix

 When all the elements of a square matrix below its main


diagonal are zero (i.e., A ij = 0 for j < i), it is called an upper
triangular matrix.
 An example of a 3 x3 upper triangular matrix is given by
Numerical Solutions to CE Problems – Matrix and Vector
1.4.1 Types of Matrices
 Diagonal Matrix

 A square matrix with all of its off-diagonal elements equal to


zero (i.e., Aij =0 for i ≠ j), is called a diagonal matrix.
 For example,
Numerical Solutions to CE Problems – Matrix and Vector
1.4.1 Types of Matrices
 Unit or Identity Matrix

 If all the diagonal elements of a diagonal matrix are equal to 1


(i.e., Iij = 1 and Iij = 0 for i ≠ j), it is referred to as a unit (or
identity) matrix.
 Unit matrices are commonly denoted by I or [I].
 An example of a 3 x 3 unit matrix is given by
Numerical Solutions to CE Problems – Matrix and Vector
1.4.1 Types of Matrices
 Null Matrix

 If all the elements of a matrix are zero (i.e., Oij = 0), it is


termed a null matrix.
 Null matrices are usually denoted by O or [O].
 An example of a 3 x 4 null matrix is given by
Numerical Solutions to CE Problems – Matrix and Vector
1.4.2 Definition of Vector
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Equality
 Matrices A and B are considered to be equal if they are of the
same order and if their corresponding elements are identical
(i.e., Aij = Bij). Consider, for example, matrices

 Since both A and B are of order 3 x 2, and since each element


of A is equal to the corresponding element of B, the matrices A
and B are equal to each other; that is, A = B
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Addition and Subtraction
 Matrices can be added (or subtracted) only if they are of the
same order.
 The addition (or subtraction) of two matrices A and B is
carried out by adding (or subtracting) the corresponding
elements of the two matrices.
 Thus, if A + B = C, then Cij = Aij + Bij; and if A - B = D, then
Dij = Aij - Bij .
 The matrices C and D have the same order as matrices A
and B.
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Addition and Subtraction
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication by a Scalar

 The product of a scalar c and a matrix A is obtained by


multiplying each element of the matrix A by the scalar c.
 Thus, if cA = B, then Bij = cAij
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication by a Scalar
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices

 Two matrices can be multiplied only if the number of


columns of the first matrix equals the number of rows of
the second matrix.
 Such matrices are said to be conformable for multiplication.
 Consider, for example, the matrices
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices

 The product AB of these matrices is defined because the first


matrix, A, of the sequence AB has two columns and the
second matrix, B, has two rows.
 However, if the sequence of the matrices is reversed, then the
product BA does not exist, because now the first matrix, B,
has two columns and the second matrix, A, has three rows.
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices
 The product AB is referred to either as A postmultiplied by B, or
as B premultiplied by A.
 Conversely, the product BA is referred to either as B
postmultiplied by A, or as A premultiplied by B.
 When two conformable matrices are multiplied, the product matrix
thus obtained has the number of rows of the first matrix and the
number of columns of the second matrix.
 Thus, if a matrix A of order l x m is postmultiplied by a matrix B of
order m x n, then the product matrix C = AB has the order l x n;
that is,
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices

 Any element Cij of the product matrix C can be determined by


multiplying each element of the ith row of A by the
corresponding element of the jth column o f B (see Eq. 2.4),
and by algebraically summing the products; that is,
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices

 Eq. (2.5) can be expressed as

 in which m represents the number of columns of A, or the


number of rows of B. Equation (2.6) can be used to determine
all elements of the product matrix C = AB.
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices

Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices

Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices
 An important application of matrix multiplication is to express
simultaneous equations in compact matrix form.
 Consider the following system of linear simultaneous
equations:
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices

 in which xs are the unknowns and As and Ps represent the


coefficients and constants, respectively.
 By using the definition of multiplication of matrices, this
system of equations can be expressed in matrix form as
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices

 or, symbolically, as

 Matrix multiplication is generally not commutative; that is,


Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices

 Even when the orders of two matrices A and B are such that
both products AB and BA are defined and are of the same
order, the two products, in general, will not be equal.
 It is essential, therefore, to maintain the proper sequential
order of matrices when evaluating matrix products
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices

 Matrix multiplication is associative and distributive, provided


that the sequential order in which the matrices are to be
multiplied is maintained. Thus,
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices

 The product of any matrix A and a comformable null matrix O


equals a null matrix; that is

 For example,
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices

 The product of any matrix A and a conformable unit matrix I


equals the original matrix A; thus,

 For example,
Numerical Solutions to CE Problems – Matrix Algebra
1.5 Matrix Algebra
 Multiplication of Matrices

 We can see from Eqs. (2.13) and (2.14) that the null and unit
matrices serve purposes in matrix algebra that are similar to
those of the numbers 0 and 1, respectively, in scalar algebra.
Numerical Solutions to CE Problems – Transpose of a Matrix
1.6 Transpose of a Matrix

 The transpose of a matrix is obtained by interchanging its


corresponding rows and columns.
 The transposed matrix is commonly identified by placing a
superscript T on the symbol of the original matrix.
Numerical Solutions to CE Problems – Transpose of a Matrix
1.6 Transpose of a Matrix

 Consider the example,

 The transpose of B is given by

 Note that the first row of B becomes the first column of . Similarly, the second and
third rows of B become, respectively, the second and third columns of . The order of
thus obtained is 2 x 3.
Numerical Solutions to CE Problems – Transpose of a Matrix
1.6 Transpose of a Matrix
 As another example, consider the matrix

 Because the elements of C are symmetric about its main


diagonal (i.e., Cij = Cji for i ≠ j), interchanging the rows and
columns of this matrix produces a matrix that is identical to C
itself; that is, = C.
 Thus, the transpose of a symmetric matrix equals the
original matrix.
Numerical Solutions to CE Problems – Transpose of a Matrix
1.6 Transpose of a Matrix
 Another useful property of matrix transposition is that the
transpose of a product of matrices equals the product of
the transposed matrices in reverse order.
 Thus,

 Similarly,
Numerical Solutions to CE Problems – Transpose of a Matrix
1.6 Transpose of a Matrix
Numerical Solutions to CE Problems – Transpose of a Matrix
1.6 Transpose of a Matrix
Numerical Solutions to CE Problems – Determinant of a Matrix
1.7 Determinant of a Matrix
 The determinant of a square matrix is a scalar value that can be
computed from its elements and provides important properties of
the matrix.
 The determinant is especially useful in solving systems of linear
equations, finding the inverse of a matrix, and determining
whether a matrix is singular or non-singular.
Numerical Solutions to CE Problems – Determinant of a Matrix
1.7 Determinant of a Matrix
 Determinant of a 2x2 Matrix
For a 2x2 matrix:

The determinant is calculated as:


Numerical Solutions to CE Problems – Determinant of a Matrix
1.7 Determinant of a Matrix
 Determinant of a 3x3 Matrix
For a 3x3 matrix:

The determinant is calculated as:


Numerical Solutions to CE Problems – Determinant of a Matrix
1.7 Determinant of a Matrix
 Properties of Determinants
• If the determinant of a matrix is 0, the matrix is singular
(i.e., it does not have an inverse).
• If the determinant of a matrix is non-zero, the matrix is
non singular (i.e., it has an inverse).
• Swapping two rows (or columns) of a matrix changes the
sign of determinant.
• Multiplying a row (or column) by a scalar multiplies the
determinant by that scalar.
Numerical Solutions to CE Problems – Determinant of a Matrix
1.7 Determinant of a Matrix
 Properties of Determinants
• The determinant of a product of two matrices is the
product of their determinants:
 Summary
• The determinant of a matrix provides crucial information
about the matrix, such as whether it is invertible and the
nature of solutions to a system of linear equations.
Numerical Solutions to CE Problems – Rank of a Matrix
1.8 Rank of a Matrix
 The rank of a matrix is the maximum number of linearly
independent rows (or columns) in the matrix.
 It is a measure of the "non-degenerateness" of the system of
linear equations described by the matrix.

 Finding the Rank of a Matrix

1. Row Echelon Form (REF): One way to determine the rank is


to reduce the matrix to its row echelon form using elementary
row operations. The rank is the number of non-zero rows in this
form.
Numerical Solutions to CE Problems – Rank of a Matrix
1.8 Rank of a Matrix
 Finding the Rank of a Matrix

2. Reduced Row Echelon Form (RREF): The matrix can be


further reduced to the reduced row echelon form, where each
leading entry in the rows is 1, and all other elements in the column
of a leading 1 are zeros. The number of leading 1s gives the rank.
3. Determinants: For a square matrix, if the determinant is
non=zero, the rank is equal to the size of the matrix (i.e., rank = n
for an n x n matrix). If the determinant is zero, the matrix may
have a lower rank.
Numerical Solutions to CE Problems – Rank of a Matrix
1.8 Rank of a Matrix
SAMPLE PROBLEM (Rank of a 3 x 3 Matrix)
Consider the Matrix:
Numerical Solutions to CE Problems – Rank of a Matrix
1.8 Rank of a Matrix
SAMPLE PROBLEM (Rank of a 3 x 3 Matrix)
1. Convert to Row Echelon Form:

The third row is entirely zeros, so the matrix has 2 non-zero


rows.
2. Rank: The rank of this matrix is 2.
Numerical Solutions to CE Problems – Rank of a Matrix
1.8 Rank of a Matrix
 Key Points about Matrix Rank
• The rank gives the number of linearly independent equations
in a system.
• If a matrix is square and the rank equals the size of the matri,
the system has a unique solution.
• If the rank is less than the size of the matrix, the system may
have infinitely many solutions (if consistent) or no solution at
all.
Numerical Solutions to CE Problems – Determinant of a Matrix
1.8 Rank of a Matrix
 Summary
• The rank of a matrix tells us how many of its rows or columns
are linearly independent, which in turn gives insight into the
solutions of a system of linear equations.

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy