Nonlinear Algebraic Systems 1.Iterative solution methods 2.Fixed-point iteration 3.Newton-Raphson method 4.Secant method 5.Matlab tutorial 6.Matlab exercise.

Slides:



Advertisements
Similar presentations
Lecture 5 Fixed point iteration Download fixedpoint.m From math.unm.edu/~plushnik/375.
Advertisements

Numerical Computation Lecture 4: Root Finding Methods - II United International College.
Chapter 6: Roots: Open Methods
Lecture 5 Newton-Raphson Method
Fixed point iterations and solution of non-linear functions
Part 2 Chapter 6 Roots: Open Methods
Numerical Solution of Nonlinear Equations
Open Methods Chapter 6 The Islamic University of Gaza
Optimisation The general problem: Want to minimise some function F(x) subject to constraints, a i (x) = 0, i=1,2,…,m 1 b i (x)  0, i=1,2,…,m 2 where x.
Empirical Maximum Likelihood and Stochastic Process Lecture VIII.
Open Methods Chapter 6 The Islamic University of Gaza
ECE 552 Numerical Circuit Analysis
Chapter 4 Roots of Equations
Chapter 6 Open Methods.
A few words about convergence We have been looking at e a as our measure of convergence A more technical means of differentiating the speed of convergence.
Transfer Functions Convenient representation of a linear, dynamic model. A transfer function (TF) relates one input and one output: The following terminology.
Transfer Functions Convenient representation of a linear, dynamic model. A transfer function (TF) relates one input and one output: The following terminology.
CHE/ME 109 Heat Transfer in Electronics LECTURE 11 – ONE DIMENSIONAL NUMERICAL MODELS.
Systems of Non-Linear Equations
Open Methods Chapter 6 The Islamic University of Gaza
Advanced Topics in Optimization
Lecture Notes Dr. Rakhmad Arief Siregar Universiti Malaysia Perlis
ECE 552 Numerical Circuit Analysis Chapter Six NONLINEAR DC ANALYSIS OR: Solution of Nonlinear Algebraic Equations Copyright © I. Hajj 2012 All rights.
Newton's Method for Functions of Several Variables
Fin500J: Mathematical Foundations in Finance Topic 3: Numerical Methods for Solving Non-linear Equations Philip H. Dybvig Reference: Numerical Methods.
Chapter 3 Root Finding.
Roots of Equations Chapter 3. Roots of Equations Also called “zeroes” of the equation –A value x such that f(x) = 0 Extremely important in applications.
MATH 685/ CSI 700/ OR 682 Lecture Notes Lecture 8. Nonlinear equations.
Selected Differential System Examples from Lectures.
Solving Non-Linear Equations (Root Finding)
Algorithms for a large sparse nonlinear eigenvalue problem Yusaku Yamamoto Dept. of Computational Science & Engineering Nagoya University.
84 b Unidimensional Search Methods Most algorithms for unconstrained and constrained optimisation use an efficient unidimensional optimisation technique.
Lecture Notes Dr. Rakhmad Arief Siregar Universiti Malaysia Perlis
Selected Differential System Examples from Lectures
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 ~ Roots of Equations ~ Open Methods Chapter 6 Credit:
Lecture 6 Numerical Analysis. Solution of Non-Linear Equations Chapter 2.
1 Solution of Nonlinear Equation Dr. Asaf Varol
Chapter 3 Roots of Equations. Objectives Understanding what roots problems are and where they occur in engineering and science Knowing how to determine.
Quadrature rules 1Michael Sokolov / Numerical Methods for Chemical Engineers / Numerical Quadrature Michael Sokolov ETH Zurich, Institut für Chemie- und.
Solution of Nonlinear Functions
Numerical Methods Root Finding 4. Fixed-Point Iteration---- Successive Approximation Many problems also take on the specialized form: g(x)=x, where we.
Newton’s Method, Root Finding with MATLAB and Excel
Applied Numerical Methods
Dr. Jie Zou PHY Chapter 2 Solution of Nonlinear Equations: Lecture (II)
Today’s class Roots of equation Finish up incremental search
linear  2.3 Newton’s Method ( Newton-Raphson Method ) 1/12 Chapter 2 Solutions of Equations in One Variable – Newton’s Method Idea: Linearize a nonlinear.
Lecture 5 - Single Variable Problems CVEN 302 June 12, 2002.
Basis of Mathematical Modeling LECTURE 3 Numerical Analysis with MATLAB Dr. N.K. Sakhnenko, PhD, Professor Associate.
Selected Algebraic System Examples from Lectures.
CHAPTER VI BLOCK DIAGRAMS AND LINEARIZATION
Root Finding UC Berkeley Fall 2004, E77 Copyright 2005, Andy Packard. This work is licensed under the Creative.
ERT 210/4 Process Control & Dynamics DYNAMIC BEHAVIOR OF PROCESSES :
TRANSFER FUNCTION Prepared by Mrs. AZDUWIN KHASRI.
1 M 277 (60 h) Mathematics for Computer Sciences Bibliography  Discrete Mathematics and its applications, Kenneth H. Rosen  Numerical Analysis, Richard.
Transfer Functions Convenient representation of a linear, dynamic model. A transfer function (TF) relates one input and one output: The following terminology.
CS B553: Algorithms for Optimization and Learning
Part 2 Chapter 6 Roots: Open Methods
Zero of a Nonlinear Function f(x) = 0
ENGG 1801 Engineering Computing
Chapter 6.
Solution of Equations by Iteration
Computers in Civil Engineering 53:081 Spring 2003
Chapter 10. Numerical Solutions of Nonlinear Systems of Equations
SOLUTION OF NONLINEAR EQUATIONS
Some iterative methods free from second derivatives for nonlinear equation Muhammad Aslam Noor Dept. of Mathematics, COMSATS Institute of Information Technology,
Chapter 6.
Part 2 Chapter 6 Roots: Open Methods
1 Newton’s Method.
EE, NCKU Tien-Hao Chang (Darby Chang)
Pivoting, Perturbation Analysis, Scaling and Equilibration
Presentation transcript:

Nonlinear Algebraic Systems 1.Iterative solution methods 2.Fixed-point iteration 3.Newton-Raphson method 4.Secant method 5.Matlab tutorial 6.Matlab exercise

Single Nonlinear Equation l Nonlinear algebraic equation: f(x) = 0 »Analytical solution rarely possible »Need numerical techniques »Multiples solutions may exist l Iterative solution »Start with an initial guess x 0 »Algorithm generates x 1 from x 0 »Repeat to generate sequence x 0, x 1, x 2, … »Assume sequence convergences to solution »Terminate algorithm at iteration N when: l Many iterative algorithms available »Fixed-point iteration, Newton-Raphson method, secant method

Fixed-Point Iteration l Formulation of iterative equation »A solution of x = g(x) is called a fixed point l Convergence »The iterative process is convergent if the sequence x 0, x 1, x 2, … converges: »Let x = g(x) have a solution x = s and assume that g(x) has a continuous first-order derivative on some interval J containing s, then the fixed-point iteration converges for any x 0 in J & the limit of the sequence {x n } is s if: »A function satisfying the theorem is called a contraction mapping: »K determines the rate of convergence

Newton-Raphson Method l Iterative equation derived from first-order Taylor series expansion l Algorithm »Input data: f(x), df(x)/dx, x 0, tolerance (  ), maximum number of iterations (N) »Given x n, compute x n+1 as: »Continue until | x n+1 -x n | <  |x n | or n = N

Convergence of the Newton-Raphson Method l Order »Provides a measure of convergence rate »Newton-Raphson method is second-order l Assume f(x) is three times differentiable, its first- and second-order derivatives are non-zero at the solution x = s & x 0 is sufficiently close to s, then the Newton method is second-order & exhibit quadratic converge to s l Caveats »The method can converge slowly or even diverge for poorly chosen x 0 »The solution obtained can depend on x 0 »The method fails if the first-order derivative becomes zero (singularity)

Secant Method l Motivation »Evaluation of df/dx may be computationally expensive »Want efficient, derivative-free method l Derivative approximation l Secant algorithm l Convergence »Superlinear: »Similar to Newton-Raphson (m = 2)

Matlab Tutorial l Solution of nonlinear algebraic equations with Matlab l FZERO – scalar nonlinear zero finding »Matlab function for solving a single nonlinear algebraic equation »Finds the root of a continuous function of one variable »Syntax: x = fzero(‘fun’,xo) –‘fun’ is the name of the user provided Matlab m-file function (fun.m) that evaluates & returns the LHS of f(x) = 0. –xo is an initial guess for the solution of f(x) = 0. »Algorithm uses a combination of bisection, secant, and inverse quadratic interpolation methods.

l Solution of a single nonlinear algebraic equation: l Write Matlab m-file function, fun.m: l Call fzero from the Matlab command line to find the solution: l Different initial guesses, xo, can give different solutions: Matlab Tutorial cont. >> xo = 0; >> fzero('fun',xo) ans = >> fzero('fun',1) ans = >> fzero('fun',4) ans =

Nonisothermal Chemical Reactor l Reaction: A  B l Assumptions »Pure A in feed »Perfect mixing » Negligible heat losses »Constant properties ( , C p,  H, U) »Constant cooling jacket temperature (T j ) l Constitutive relations »Reaction rate/volume: r = kc A = k 0 exp(-E/RT)c A »Heat transfer rate: Q = UA(T j -T)

Model Formulation l Mass balance l Component balance l Energy balance

Matlab Exercise l Steady-state model l Parameter values »k 0 = 3.493x10 7 h -1, E = kcal/kmol »(-  H) = 5960 kcal/kmol,  C p = 500 kcal/m 3 /K »UA = 150 kcal/h/K, R = kcal/kmol/K »V = 1 m 3, q =1 m 3 /h, »C Af = 10 kmol/m 3, T f = 298 K, T j = 298 K. l Problem »Find the three steady-state points:

Matlab Tutorial cont. l FSOLVE – multivariable nonlinear zero finding »Matlab function for solving a system of nonlinear algebraic equations »Syntax: x = fsolve(‘fun’,xo) –Same syntax as fzero, but x is a vector of variables and the function, ‘fun’, returns a vector of equation values, f(x). »Part of the Matlab Optimization toolbox »Multiple algorithms available in options settings (e.g. trust- region dogleg, Gauss-Newton, Levenberg-Marquardt)

l Syntax for fsolve »x = fsolve('cstr',xo,options) »'cstr' – name of the Matlab m-file function (cstr.m) for the CSTR model »xo – initial guess for the steady state, xo = [C A T] '; »options – Matlab structure of optimization parameter values created with the optimset function l Solution for first steady state, Matlab command line input and output: Matlab Exercise: Solution with fsolve >> xo = [10 300]'; >> x = fsolve('cstr',xo,optimset('Display','iter')) Norm of First-order Trust-region Iteration Func-count f(x) step optimality radius e e e e e e e e e e e e Optimization terminated: first-order optimality is less than options.TolFun. x =

Matlab Exercise: cstr.m function f = cstr(x) ko = 3.493e7; E = 11843; H = -5960; rhoCp = 500; UA = 150; R = 1.987; V = 1; q = 1; Caf = 10; Tf = 298; Tj = 298; Ca = x(1); T = x(2); f(1) = q*(Caf - Ca) - V*ko*exp(-E/R/T)*Ca; f(2) = rhoCp*q*(Tf - T) + -H*V*ko*exp(-E/R/T)*Ca + UA*(Tj-T); f=f';