SlideShare a Scribd company logo
1 of 8
Download to read offline
Numerical solution of ordinary and
partial dierential Equations
Module 21: Finite dierence methods - I
Dr.rer.nat. Narni Nageswara Rao
£
August 2011
1 Introduction:
Consider the two point boundary value problem
yHH = f(t; y; yH); t P (a; b) (1)
where a prime denotes dierentiation with respect to t, with one of the fol-
lowing three boundary conditions.
Boundary conditions of
rst kind:
y(a) = 
1; y(b) = 
2 (2)
Boundary conditions of second kind
yH(a) = 
1; yH(b) = 
2 (3)
Boundary conditions of the thirdking (or mixed kind)
a0y(a)  a1yH(a) = 
1 b0y(b) + b1yH(b) = 
2 (4)
where a0, b0, a1, b1, 
1 and 
2 are constants such that
a0a1 ! 0; ja0j+ ja1j T= 0
b0b1 ! 0; jb0j+ jb1j T= 0 and ja0j+ jb0j T= 0
£nnrao maths@yahoo.co.in
1
2 Finite dierence methods
These are the explicit or implicit realtions between the derivatives and the
function values at the adjecent nodal points. The nodal points on an interval
[a; b] may be de
ned by
tj = a + jh; j = 1; 2; ¡¡¡ ; N
where t0 = a; tN+1 = b h =
b  a
(N + 1)
The
nite dierence solution of a boundary value problem is obtained by
replacing the dierential equation at each nodal point by a dierence equa-
tion. Incorporating the boundary conditions in the dierence equations, the
resulting algebraic system of equations is solved. This gives the approximate
numerical solution of the boundary value problem.
3 Linear second order dierential equations
We consider the linear second order dierential equation
 yHH + p(t)yH + q(t)y = r(t); a  t  b (5)
subject to the boundary conditions of the
rst kind
y(a) = 
1; y(b) = 
2 (6)
The exact value of y(t) at tj is denoted by Yj and its approximate value by
yj. Using Taylor series, we can have
yH(tj) =
y(tj+1)  y(tj 1)
2h
+ y(h2) (7)
yHH(tj) =
y(tj+1)  2y(tj) + y(tj 1)
h2 + y(h2) (8)
Neglecting the y(h2) terms in (7) and (8) and substituting in (5). The
nite
dierence approximation of the dierential equation at t = tj is given by
 
yj+1  2yj + yj 1
h2

+p(tj)
yj+1  yj 1
2h

+q(tj)yj = r(tj); j = 1; 2; ¡¡¡ ; N
(9)
The boundary conditions (6) become
y0 = 
1; yN+1 = 
2 (10)
2
upon multiplication by h2
2 , (9) may be written in the form
Ajyj 1 + Bjyj + Cjyj+1 =
h2
2
r(tj); j = 1; 2; ¡¡¡ ; N (11)
where
Aj =  1
2

1 +
h
2
p(tj)

;
Bj = 1 +
h2
2
q(tj);
Cj =  1
2

1   h
2
p(tj)

The system (11) in matrix notation, after incorporating the boundary con-
ditions, becomes
Ay = b (12)
where
y = [y1; y2; ¡¡¡ ; yN]T
b =
h2
2

r(t1)   1A1r1
h2 ; r(t2); ¡¡¡ ; r(tN 1); r(tN)   2CNr2
h2
T
A =
0
BBBB@
B1 C1 0
A2 B2 C2
¡¡¡ ¡¡¡ ¡¡¡ ¡¡¡ ¡¡¡
AN 1 BN 1 CN 1
0 AN BN
1
CCCCA
The solution of the system of linear equations (12) gives the

More Related Content

What's hot

Finite difference method
Finite difference methodFinite difference method
Finite difference methodDivyansh Verma
 
Mcq differential and ordinary differential equation
Mcq differential and ordinary differential equationMcq differential and ordinary differential equation
Mcq differential and ordinary differential equationSayyad Shafi
 
14257017 metode-frobenius (1)
14257017 metode-frobenius (1)14257017 metode-frobenius (1)
14257017 metode-frobenius (1)Sanre Tambunan
 
Numerical Solution of Nth - Order Fuzzy Initial Value Problems by Fourth Orde...
Numerical Solution of Nth - Order Fuzzy Initial Value Problems by Fourth Orde...Numerical Solution of Nth - Order Fuzzy Initial Value Problems by Fourth Orde...
Numerical Solution of Nth - Order Fuzzy Initial Value Problems by Fourth Orde...IOSR Journals
 
Higherorder non homogeneous partial differrential equations (Maths 3) Power P...
Higherorder non homogeneous partial differrential equations (Maths 3) Power P...Higherorder non homogeneous partial differrential equations (Maths 3) Power P...
Higherorder non homogeneous partial differrential equations (Maths 3) Power P...vrajes
 
Exact & non differential equation
Exact & non differential equationExact & non differential equation
Exact & non differential equationSiddhi Shrivas
 
Partial Differential Equation - Notes
Partial Differential Equation - NotesPartial Differential Equation - Notes
Partial Differential Equation - NotesDr. Nirav Vyas
 
Constant-Coefficient Linear Differential Equations
Constant-Coefficient Linear Differential  EquationsConstant-Coefficient Linear Differential  Equations
Constant-Coefficient Linear Differential Equationsashikul akash
 
Linear differential equation with constant coefficient
Linear differential equation with constant coefficientLinear differential equation with constant coefficient
Linear differential equation with constant coefficientSanjay Singh
 
First order non-linear partial differential equation & its applications
First order non-linear partial differential equation & its applicationsFirst order non-linear partial differential equation & its applications
First order non-linear partial differential equation & its applicationsJayanshu Gundaniya
 
formulation of first order linear and nonlinear 2nd order differential equation
formulation of first order linear and nonlinear 2nd order differential equationformulation of first order linear and nonlinear 2nd order differential equation
formulation of first order linear and nonlinear 2nd order differential equationMahaswari Jogia
 

What's hot (20)

Conformal mapping
Conformal mappingConformal mapping
Conformal mapping
 
Improper integral
Improper integralImproper integral
Improper integral
 
Finite difference method
Finite difference methodFinite difference method
Finite difference method
 
Ma2002 1.20 rm
Ma2002 1.20 rmMa2002 1.20 rm
Ma2002 1.20 rm
 
Differential Equation
Differential EquationDifferential Equation
Differential Equation
 
Ch03 1
Ch03 1Ch03 1
Ch03 1
 
Mcq differential and ordinary differential equation
Mcq differential and ordinary differential equationMcq differential and ordinary differential equation
Mcq differential and ordinary differential equation
 
Optimal Finite Difference Grids
Optimal Finite Difference GridsOptimal Finite Difference Grids
Optimal Finite Difference Grids
 
14257017 metode-frobenius (1)
14257017 metode-frobenius (1)14257017 metode-frobenius (1)
14257017 metode-frobenius (1)
 
Numerical Solution of Nth - Order Fuzzy Initial Value Problems by Fourth Orde...
Numerical Solution of Nth - Order Fuzzy Initial Value Problems by Fourth Orde...Numerical Solution of Nth - Order Fuzzy Initial Value Problems by Fourth Orde...
Numerical Solution of Nth - Order Fuzzy Initial Value Problems by Fourth Orde...
 
Higherorder non homogeneous partial differrential equations (Maths 3) Power P...
Higherorder non homogeneous partial differrential equations (Maths 3) Power P...Higherorder non homogeneous partial differrential equations (Maths 3) Power P...
Higherorder non homogeneous partial differrential equations (Maths 3) Power P...
 
Exact & non differential equation
Exact & non differential equationExact & non differential equation
Exact & non differential equation
 
Partial Differential Equation - Notes
Partial Differential Equation - NotesPartial Differential Equation - Notes
Partial Differential Equation - Notes
 
Ch04 2
Ch04 2Ch04 2
Ch04 2
 
Ch02 6
Ch02 6Ch02 6
Ch02 6
 
Constant-Coefficient Linear Differential Equations
Constant-Coefficient Linear Differential  EquationsConstant-Coefficient Linear Differential  Equations
Constant-Coefficient Linear Differential Equations
 
Ch08 3
Ch08 3Ch08 3
Ch08 3
 
Linear differential equation with constant coefficient
Linear differential equation with constant coefficientLinear differential equation with constant coefficient
Linear differential equation with constant coefficient
 
First order non-linear partial differential equation & its applications
First order non-linear partial differential equation & its applicationsFirst order non-linear partial differential equation & its applications
First order non-linear partial differential equation & its applications
 
formulation of first order linear and nonlinear 2nd order differential equation
formulation of first order linear and nonlinear 2nd order differential equationformulation of first order linear and nonlinear 2nd order differential equation
formulation of first order linear and nonlinear 2nd order differential equation
 

Similar to Ma2002 1.21 rm

Assignment no4
Assignment no4Assignment no4
Assignment no4Ali Baig
 
Shahjahan notes:Mathematicsinphysicstheorysampleproblematc
Shahjahan notes:MathematicsinphysicstheorysampleproblematcShahjahan notes:Mathematicsinphysicstheorysampleproblematc
Shahjahan notes:MathematicsinphysicstheorysampleproblematcShahjahan Physics
 
Advanced Engineering Mathematics Solutions Manual.pdf
Advanced Engineering Mathematics Solutions Manual.pdfAdvanced Engineering Mathematics Solutions Manual.pdf
Advanced Engineering Mathematics Solutions Manual.pdfWhitney Anderson
 
SUCCESSIVE LINEARIZATION SOLUTION OF A BOUNDARY LAYER CONVECTIVE HEAT TRANSFE...
SUCCESSIVE LINEARIZATION SOLUTION OF A BOUNDARY LAYER CONVECTIVE HEAT TRANSFE...SUCCESSIVE LINEARIZATION SOLUTION OF A BOUNDARY LAYER CONVECTIVE HEAT TRANSFE...
SUCCESSIVE LINEARIZATION SOLUTION OF A BOUNDARY LAYER CONVECTIVE HEAT TRANSFE...ijcsa
 
Lecture -Earthquake Engineering (2).pdf
Lecture -Earthquake Engineering (2).pdfLecture -Earthquake Engineering (2).pdf
Lecture -Earthquake Engineering (2).pdfRayRabara
 
OrthogonalFunctionsPaper
OrthogonalFunctionsPaperOrthogonalFunctionsPaper
OrthogonalFunctionsPaperTyler Otto
 
A family of implicit higher order methods for the numerical integration of se...
A family of implicit higher order methods for the numerical integration of se...A family of implicit higher order methods for the numerical integration of se...
A family of implicit higher order methods for the numerical integration of se...Alexander Decker
 
Calculus of variation problems
Calculus of variation   problemsCalculus of variation   problems
Calculus of variation problemsSolo Hermelin
 
Heat problems
Heat problemsHeat problems
Heat problemsHo Linh
 
Trapezoidal Method IN Numerical Analysis
Trapezoidal Method IN  Numerical AnalysisTrapezoidal Method IN  Numerical Analysis
Trapezoidal Method IN Numerical AnalysisMostafijur Rahman
 
BIOL 364 - assignment 3
BIOL 364 - assignment 3BIOL 364 - assignment 3
BIOL 364 - assignment 3Nanjun Li
 

Similar to Ma2002 1.21 rm (20)

Ma2002 1.19 rm
Ma2002 1.19 rmMa2002 1.19 rm
Ma2002 1.19 rm
 
Ma2002 1.23 rm
Ma2002 1.23 rmMa2002 1.23 rm
Ma2002 1.23 rm
 
Ch03 2
Ch03 2Ch03 2
Ch03 2
 
Assignment no4
Assignment no4Assignment no4
Assignment no4
 
Ch07 9
Ch07 9Ch07 9
Ch07 9
 
Ma2002 1.13 rm
Ma2002 1.13 rmMa2002 1.13 rm
Ma2002 1.13 rm
 
Shahjahan notes:Mathematicsinphysicstheorysampleproblematc
Shahjahan notes:MathematicsinphysicstheorysampleproblematcShahjahan notes:Mathematicsinphysicstheorysampleproblematc
Shahjahan notes:Mathematicsinphysicstheorysampleproblematc
 
Advanced Engineering Mathematics Solutions Manual.pdf
Advanced Engineering Mathematics Solutions Manual.pdfAdvanced Engineering Mathematics Solutions Manual.pdf
Advanced Engineering Mathematics Solutions Manual.pdf
 
SUCCESSIVE LINEARIZATION SOLUTION OF A BOUNDARY LAYER CONVECTIVE HEAT TRANSFE...
SUCCESSIVE LINEARIZATION SOLUTION OF A BOUNDARY LAYER CONVECTIVE HEAT TRANSFE...SUCCESSIVE LINEARIZATION SOLUTION OF A BOUNDARY LAYER CONVECTIVE HEAT TRANSFE...
SUCCESSIVE LINEARIZATION SOLUTION OF A BOUNDARY LAYER CONVECTIVE HEAT TRANSFE...
 
Lecture -Earthquake Engineering (2).pdf
Lecture -Earthquake Engineering (2).pdfLecture -Earthquake Engineering (2).pdf
Lecture -Earthquake Engineering (2).pdf
 
OrthogonalFunctionsPaper
OrthogonalFunctionsPaperOrthogonalFunctionsPaper
OrthogonalFunctionsPaper
 
Ma2002 1.16 rm
Ma2002 1.16 rmMa2002 1.16 rm
Ma2002 1.16 rm
 
A family of implicit higher order methods for the numerical integration of se...
A family of implicit higher order methods for the numerical integration of se...A family of implicit higher order methods for the numerical integration of se...
A family of implicit higher order methods for the numerical integration of se...
 
Calculus of variation problems
Calculus of variation   problemsCalculus of variation   problems
Calculus of variation problems
 
Heat problems
Heat problemsHeat problems
Heat problems
 
Trapezoidal Method IN Numerical Analysis
Trapezoidal Method IN  Numerical AnalysisTrapezoidal Method IN  Numerical Analysis
Trapezoidal Method IN Numerical Analysis
 
05_AJMS_332_21.pdf
05_AJMS_332_21.pdf05_AJMS_332_21.pdf
05_AJMS_332_21.pdf
 
Ch05 2
Ch05 2Ch05 2
Ch05 2
 
BIOL 364 - assignment 3
BIOL 364 - assignment 3BIOL 364 - assignment 3
BIOL 364 - assignment 3
 
Ma2002 1.7 rm
Ma2002 1.7 rmMa2002 1.7 rm
Ma2002 1.7 rm
 

More from Ramakrishna Paduchuri (20)

M 1.5 rm
M 1.5 rmM 1.5 rm
M 1.5 rm
 
M 1.5 p4.s
M 1.5 p4.sM 1.5 p4.s
M 1.5 p4.s
 
M 1.5 p4.q
M 1.5 p4.qM 1.5 p4.q
M 1.5 p4.q
 
M 1.5 p3.s
M 1.5 p3.sM 1.5 p3.s
M 1.5 p3.s
 
M 1.5 p3.q
M 1.5 p3.qM 1.5 p3.q
M 1.5 p3.q
 
M 1.5 p2.s
M 1.5 p2.sM 1.5 p2.s
M 1.5 p2.s
 
M 1.5 p2.q
M 1.5 p2.qM 1.5 p2.q
M 1.5 p2.q
 
M 1.5 p1.s
M 1.5 p1.sM 1.5 p1.s
M 1.5 p1.s
 
M 1.5 p1.q
M 1.5 p1.qM 1.5 p1.q
M 1.5 p1.q
 
M 1.4 rm
M 1.4 rmM 1.4 rm
M 1.4 rm
 
M 1.4 ap1
M 1.4 ap1M 1.4 ap1
M 1.4 ap1
 
M 1.3 rm
M 1.3 rmM 1.3 rm
M 1.3 rm
 
M 1.1 rm
M 1.1 rmM 1.1 rm
M 1.1 rm
 
M 1.3 ap1
M 1.3 ap1M 1.3 ap1
M 1.3 ap1
 
Ma2002 1.22 rm
Ma2002 1.22 rmMa2002 1.22 rm
Ma2002 1.22 rm
 
Ma2002 1.18 rm
Ma2002 1.18 rmMa2002 1.18 rm
Ma2002 1.18 rm
 
Ma2002 1.17 rm
Ma2002 1.17 rmMa2002 1.17 rm
Ma2002 1.17 rm
 
Ma2002 1.12 rm
Ma2002 1.12 rmMa2002 1.12 rm
Ma2002 1.12 rm
 
Ma2002 1.10 rm
Ma2002 1.10 rmMa2002 1.10 rm
Ma2002 1.10 rm
 
Ma2002 1.9 rm
Ma2002 1.9 rmMa2002 1.9 rm
Ma2002 1.9 rm
 

Recently uploaded

CELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxCELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxJiesonDelaCerna
 
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxHistory Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxsocialsciencegdgrohi
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfSumit Tiwari
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon AUnboundStockton
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,Virag Sontakke
 
Final demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxFinal demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxAvyJaneVismanos
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxthorishapillay1
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxmanuelaromero2013
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationnomboosow
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...M56BOOKSTORE PRODUCT/SERVICE
 
Biting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdfBiting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdfadityarao40181
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentInMediaRes1
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersSabitha Banu
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Celine George
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
Types of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxTypes of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxEyham Joco
 

Recently uploaded (20)

CELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxCELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptx
 
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxHistory Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon A
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
 
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
 
Final demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxFinal demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptx
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptx
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptx
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communication
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
 
Biting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdfBiting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdf
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media Component
 
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginners
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
Types of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxTypes of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptx
 

Ma2002 1.21 rm

  • 1. Numerical solution of ordinary and partial dierential Equations Module 21: Finite dierence methods - I Dr.rer.nat. Narni Nageswara Rao £ August 2011 1 Introduction: Consider the two point boundary value problem yHH = f(t; y; yH); t P (a; b) (1) where a prime denotes dierentiation with respect to t, with one of the fol- lowing three boundary conditions. Boundary conditions of
  • 2. rst kind: y(a) = 1; y(b) = 2 (2) Boundary conditions of second kind yH(a) = 1; yH(b) = 2 (3) Boundary conditions of the thirdking (or mixed kind) a0y(a)  a1yH(a) = 1 b0y(b) + b1yH(b) = 2 (4) where a0, b0, a1, b1, 1 and 2 are constants such that a0a1 ! 0; ja0j+ ja1j T= 0 b0b1 ! 0; jb0j+ jb1j T= 0 and ja0j+ jb0j T= 0 £nnrao maths@yahoo.co.in 1
  • 3. 2 Finite dierence methods These are the explicit or implicit realtions between the derivatives and the function values at the adjecent nodal points. The nodal points on an interval [a; b] may be de
  • 4. ned by tj = a + jh; j = 1; 2; ¡¡¡ ; N where t0 = a; tN+1 = b h = b  a (N + 1) The
  • 5. nite dierence solution of a boundary value problem is obtained by replacing the dierential equation at each nodal point by a dierence equa- tion. Incorporating the boundary conditions in the dierence equations, the resulting algebraic system of equations is solved. This gives the approximate numerical solution of the boundary value problem. 3 Linear second order dierential equations We consider the linear second order dierential equation  yHH + p(t)yH + q(t)y = r(t); a t b (5) subject to the boundary conditions of the
  • 6. rst kind y(a) = 1; y(b) = 2 (6) The exact value of y(t) at tj is denoted by Yj and its approximate value by yj. Using Taylor series, we can have yH(tj) = y(tj+1)  y(tj 1) 2h + y(h2) (7) yHH(tj) = y(tj+1)  2y(tj) + y(tj 1) h2 + y(h2) (8) Neglecting the y(h2) terms in (7) and (8) and substituting in (5). The
  • 7. nite dierence approximation of the dierential equation at t = tj is given by   yj+1  2yj + yj 1 h2 +p(tj) yj+1  yj 1 2h +q(tj)yj = r(tj); j = 1; 2; ¡¡¡ ; N (9) The boundary conditions (6) become y0 = 1; yN+1 = 2 (10) 2
  • 8. upon multiplication by h2 2 , (9) may be written in the form Ajyj 1 + Bjyj + Cjyj+1 = h2 2 r(tj); j = 1; 2; ¡¡¡ ; N (11) where Aj =  1 2 1 + h 2 p(tj) ; Bj = 1 + h2 2 q(tj); Cj =  1 2 1   h 2 p(tj) The system (11) in matrix notation, after incorporating the boundary con- ditions, becomes Ay = b (12) where y = [y1; y2; ¡¡¡ ; yN]T b = h2 2 r(t1)   1A1r1 h2 ; r(t2); ¡¡¡ ; r(tN 1); r(tN)   2CNr2 h2 T A = 0 BBBB@ B1 C1 0 A2 B2 C2 ¡¡¡ ¡¡¡ ¡¡¡ ¡¡¡ ¡¡¡ AN 1 BN 1 CN 1 0 AN BN 1 CCCCA The solution of the system of linear equations (12) gives the
  • 9. nite dier- ence solution of the dierential equation (5) satisfying the boundary condi- tions (6). 3.1 Derivative boundary conditions We now consider the boundary conditions of the third type a0y(a)  a1yH(a) = 1 b0y(b) + b1yH(b) = 2 (13) The dierence approximation of the dierential equation (5) at the internal nodes, j = 1; 2; ¡¡¡ ; N is given by (11), which has N + 2 unknowns in N 3
  • 11. nd two more equations corresponding to the bound- ary conditions (13). Ignoring y(h2) terms in (7), the
  • 12. nite dierence approximations of (13) are at t = t0, a0y0  a1 y1  y 1 2h = 1 or y 1 =  2ha0 a1 y0 + y1 + 2h a1 1 (14) at t = tN+1, b0yN+1 + b1 yN+2  yN 2h = 2 or yN+2 = yN   2hb0 b1 yN+1 + 2h b0 2 (15) where y 1 and yN+2 are the function values at t 1 and tN+2. The nodes t 1 and tN+2 outside the interval [a; b] and are called
  • 13. ctitious nodes. The values of y 1 and yN+2 may be eliminated by assuming that the dierence equation (11) holds also for j = 0 and N + 1, i.e, at the boundary points t0 and tN+1. Substituting the values of y 1 and yN+2 from (14) and (15) into the equations (11) for j = 0 and j = N + 1, we obtained (i) B0   2ha0 a1 A0 y0 + (A0 + C0)y1 = h2 2 r(t0)   2h a1 1A0 (ii) (AN+1+CN+1)yN+ BN+1   2hb0 b1 CN+1 yN+1 = h2 2 r(tN+1) 2h b1 2CN+1 (16) The equations (16)(i),(11), j = 1; 2; ¡¡¡ ; N and (16)(ii) form a tridiagonal system of equations. Since the dierence approximation (11) for the dier- ential equation (5) and the dierence approximations (16) for the bound- ary conditions (13) are all of second order, the totality of the equations for j = 0; 1; 2; ¡¡¡ ; N + 1 is also of second order. Alternately, we may not use the
  • 14. ctitious points y 1 and yN+1. In this case, we may use the following approximations. 4
  • 15. (a) (i) For j = 0 : a0y0  a1 y1  y0 h = 1 or [a0h + a1]y0  a1y1 = h 1 (17) (ii) For j = N + 1 : b0yN+1 + b1 yN+1  yN h = 2 or [b0h + b1]yN+1  b1yN = h 2 (18) Since, the approximations (17) and (18) are of
  • 16. rst order, the totality of the equations (17), (11) and (18) for j = 0; 1; 2; ¡¡¡ ; N + 1, can not retain the second order. These also form a tridiagonal system of equa- tions. (b) (i) For j = 0 : a0y0  a1 1 2h ( 3y0 + 4y1  y2) = 1 or (2ha0 + 3a1)y0  4a1y1 + a1y2 = 2h 1 (19) (ii) For j = N + 1 : b0yN+1 + b1 1 2h (3yN+1  4yN + yN 1) = 2 or b1yN 1  4b1yN + (2hb0 + 3b1)yN+1 = 2h 2 (20) Since the approximations (19) and (20) are of second order, the to- tality equations (19), (11), (20) for j = 0; 1; 2; ¡¡¡ ; N   1, are also of second order. If we eliminate y2 from (19) using the
  • 17. rst equation of the set (11), and eliminate yN 1 from (20) using the last equation of the set (11), then the resulting equations form a tridiagonal system of equations. 5
  • 18. 3.2 Solution of Tridiagonal System The dierence approximations to the linear second order dierential equation (5) and the boundary conditions (6) or (13) lead to the solution of a system of algebraic equations in N or N + 2 unknowns whose coecients give rise to a tridiagonal system. The system can be solved by Gaussian elimination. 3.3 Problems Example: Solve the boundary value problem yHH = y + t; y(0) = 0; y(1) = 0 with h = 1 4 by using the second order method. Solution: Here a = 0, b = 1 h = b a N+1 A N + 1 = 4 A N = 3 ) tj = a + jh j = 0; 1; 2; 3; 4: ) The nodal points are t0 = 0(= a), t1 = 0:25, t2 = 0:5, t3 = 0:75, t4 = 1(= b) The second order method gives the following system of equations yj 1  2yj + yj+1 h2 = yj + tj; j = 1; 2; 3: )  yj 1 + 2yj  yj+1 =  h2(yj + tj) j = 1; 2; 3 For h = 1 4, we get  16yj 1 + 33yj  16yj+1 =  tj we have for j = 1 :  16y0 + 33y1  16y2 =  t1 =  0:25 for j = 2 :  16y1 + 33y2  16y3 =  0:50 for j = 3 :  16y2 + 33y3  16y4 =  0:75 Using the boundary conditions y0 = 0, y4 = 0, we get the system of equations 0 @ 33  16 0  16 33  16 0  16 33 1 A 0 @ y1 y2 y3 1 A =   0 @ 0:25 0:5 0:75 1 A 6
  • 19. which gives y1 =  0:034885 y2 =  0:056326 y3 =  0:050037 Example: Solve the boundary value problem yHH = ty y(0) + yH(0) =  1 y(1) = 1 with h = 1 3 by using the second order method. Solution: With h = 1 3, a = 0, b = 1 N + 1 = b  a h = 3 A N = 2 ) The nodal points are t0 = 0, t1 = 1 3, t2 = 2 3, t3 = 1 The second order method gives the following system of equations yj 1  2yj + yj+1 = h2tjyj; j = 0; 1; 2; 3 we have for j = 0 : y 1  2y0 + y1 = 0 for j = 1 : y0  2y1 + y2 = y1 27 for j = 2 : y1  2y2 + y3 = 2 27 y2 Since the method is of second order, we may replace yH(0) in the boundary condition by the approximation yH(0) = (y1  y 1)=2h which is also of second order, thus, the boundary conditions become y0 + 3 2 (y1  y 1) = 1 and y3 = 1 7
  • 20. eliminating y 1, we get the equations  2y0 + 3y1 = 1 y0   55 27 y1 + y2 = 0 y1   56 27 y2 =  1 Solving the system of equations we get y(0) % y0 =  0:9879518 y 1 3 % y1 =  0:3253012 y 2 3 % y2 = 0:3253012 8