0% found this document useful (0 votes)
493 views7 pages

Basic of Finite Difference Method

The finite difference method is a numerical method for solving differential equations by approximating them with difference equations. It works by discretizing the domain into a grid and using Taylor series expansions to approximate derivatives as finite differences. The accuracy and stability of solutions depend on the choice of discretization. Common examples include explicit and implicit methods for heat equations.

Uploaded by

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

Basic of Finite Difference Method

The finite difference method is a numerical method for solving differential equations by approximating them with difference equations. It works by discretizing the domain into a grid and using Taylor series expansions to approximate derivatives as finite differences. The accuracy and stability of solutions depend on the choice of discretization. Common examples include explicit and implicit methods for heat equations.

Uploaded by

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

8/1/2015

FinitedifferencemethodWikipedia,thefreeencyclopedia

Finitedifferencemethod
FromWikipedia,thefreeencyclopedia

Inmathematics,finitedifferencemethods(FDM)arenumericalmethodsforsolvingdifferential
equationsbyapproximatingthemwithdifferenceequations,inwhichfinitedifferencesapproximatethe
[Link].
Today,FDMsarethedominantapproachtonumericalsolutionsofpartialdifferentialequations.[1]

Contents
1DerivationfromTaylor'spolynomial
2Accuracyandorder
3Example:ordinarydifferentialequation
4Example:Theheatequation
4.1Explicitmethod
4.2Implicitmethod
4.3CrankNicolsonmethod
5Seealso
6References
7Externallinks
7.1Variouslecturesandlecturenotes

DerivationfromTaylor'spolynomial
First,assumingthefunctionwhosederivativesaretobeapproximatedisproperlybehaved,byTaylor's
theorem,wecancreateaTaylorSeriesexpansion

wheren!denotesthefactorialofn,andRn(x)isaremainderterm,denotingthedifferencebetweenthe
[Link]
derivativeofthefunction"f"byfirsttruncatingtheTaylorpolynomial:

Setting,x0=awehave,

Dividingacrossbyhgives:

Solvingforf'(a):
[Link]

1/7

8/1/2015

Assumingthat

FinitedifferencemethodWikipedia,thefreeencyclopedia

issufficientlysmall,theapproximationofthefirstderivativeof"f"is:

Accuracyandorder
Theerrorinamethod'ssolutionisdefinedasthedifferencebetweenitsapproximationandtheexact
[Link],thelossof
precisionduetocomputerroundingofdecimalquantities,andtruncationerrorordiscretizationerror,the
differencebetweentheexactsolutionofthefinitedifferenceequationandtheexactquantityassuming
perfectarithmetic(thatis,assumingnoroundoff).
Touseafinitedifferencemethodtoapproximatethesolutiontoa
problem,onemustfirstdiscretizetheproblem'[Link]
usuallydonebydividingthedomainintoauniformgrid(see
imagetotheright).Notethatthismeansthatfinitedifference
methodsproducesetsofdiscretenumericalapproximationstothe
derivative,oftenina"timestepping"manner.
Anexpressionofgeneralinterestisthelocaltruncationerrorofa
[Link],local
truncationerrorreferstotheerrorfromasingleapplicationofa
[Link],itisthequantity
if
refers
totheexactvalueand [Link]
remaindertermofaTaylorpolynomialisconvenientfor
[Link]
theremainderfromtheTaylorpolynomialfor
,
whichis

Thefinitedifferencemethodrelieson
discretizingafunctiononagrid.

,where
,
[Link],againusingtheforward
differenceformulaforthefirstderivative,knowingthat
,

andwithsomealgebraicmanipulation,thisleadsto

[Link]

2/7

8/1/2015

FinitedifferencemethodWikipedia,thefreeencyclopedia

andfurthernotingthatthequantityontheleftistheapproximationfromthefinitedifferencemethodand
thatthequantityontherightistheexactquantityofinterestplusaremainder,clearlythatremainderis
[Link]:

Thismeansthat,inthiscase,[Link]
durationofsimulatedFDMsolutiondependsonthediscretizationequationselectionandthestepsizes
(timeandspacesteps).Thedataqualityandsimulationdurationincreasesignificantlywithsmallerstep
size.[2]Therefore,areasonablebalancebetweendataqualityandsimulationdurationisnecessaryfor
[Link],however
toolargetimestepsmaycreateinstabilitiesandaffectingthedataquality.[3][4][5]
ThevonNeumannmethod(Fourierstabilityanalysis)usuallyappliedtodeterminethenumericalmodel
stability.[3][4][5][6][7]

Example:ordinarydifferentialequation
Forexample,considertheordinarydifferentialequation

TheEulermethodforsolvingthisequationusesthefinitedifferencequotient

toapproximatethedifferentialequationbyfirstsubstitutinginforu'(x)thenapplyingalittlealgebra
(multiplyingbothsidesbyh,andthenaddingu(x)tobothsides)toget

Thelastequationisafinitedifferenceequation,andsolvingthisequationgivesanapproximatesolution
tothedifferentialequation.

Example:Theheatequation
Considerthenormalizedheatequationinonedimension,withhomogeneousDirichletboundary
conditions
(boundarycondition)
(initialcondition)
Onewaytonumericallysolvethisequationistoapproximateallthederivativesbyfinitedifferences.
Wepartitionthedomaininspaceusingamesh
andintimeusingamesh
.We
assumeauniformpartitionbothinspaceandintime,sothedifferencebetweentwoconsecutivespace
[Link]
[Link]

3/7

8/1/2015

FinitedifferencemethodWikipedia,thefreeencyclopedia

willrepresentthenumericalapproximationof

Explicitmethod
Usingaforwarddifferenceattime andasecondordercentral
differenceforthespacederivativeatposition (FTCS)weget
therecurrenceequation:

Thisisanexplicitmethodforsolvingtheonedimensionalheat
equation.
Wecanobtain

Thestencilforthemostcommon
explicitmethodfortheheatequation.

fromtheothervaluesthisway:

where
So,withthisrecurrencerelation,andknowingthevaluesattimen,onecanobtainthecorresponding
valuesattimen+1. and mustbereplacedbytheboundaryconditions,inthisexampletheyare
both0.
Thisexplicitmethodisknowntobenumericallystableandconvergentwhenever
numericalerrorsareproportionaltothetimestepandthesquareofthespacestep:

.[8]The

Implicitmethod
Ifweusethebackwarddifferenceattime
andasecond
ordercentraldifferenceforthespacederivativeatposition
(TheBackwardTime,CenteredSpaceMethod"BTCS")weget
therecurrenceequation:

Thisisanimplicitmethodforsolvingtheonedimensionalheat
equation.
Wecanobtain

Theimplicitmethodstencil.

fromsolvingasystemoflinearequations:

[Link]

4/7

8/1/2015

FinitedifferencemethodWikipedia,thefreeencyclopedia

Theschemeisalwaysnumericallystableandconvergentbutusuallymorenumericallyintensivethanthe
[Link]
linearoverthetimestepandquadraticoverthespacestep:

CrankNicolsonmethod
Finallyifweusethecentraldifferenceattime
andasecondordercentraldifferenceforthe
spacederivativeatposition ("CTCS")wegettherecurrenceequation:

ThisformulaisknownastheCrankNicolsonmethod.
Wecanobtain

fromsolvingasystemoflinearequations:

TheCrankNicolsonstencil.

Theschemeisalwaysnumericallystableandconvergentbutusuallymorenumericallyintensiveasit
[Link]
thetimestepandthespacestep:

[Link]
schemeistheleastaccurateandcanbeunstable,butisalsotheeasiesttoimplementandtheleast
[Link].

Seealso
Finiteelementmethod
Finitedifference
Finitedifferencetimedomain
Stencil(numericalanalysis)
Finitedifferencecoefficients
Fivepointstencil
LaxRichtmyertheorem
Finitedifferencemethodsforoptionpricing
Upwinddifferencingschemeforconvection
Centraldifferencingscheme
[Link]

5/7

8/1/2015

FinitedifferencemethodWikipedia,thefreeencyclopedia

References
1. [Link](2007).NumericalTreatmentofPartialDifferential
[Link]&BusinessMedia.p.23.ISBN9783540715849.
2. AriehIserlas(2008).[Link]
Press.p.23.ISBN9780521734905.
3. HoffmanJDFrankelS(2001).[Link],BocaRaton.
4. JaluriaYAtluriS(1994)."Computationalheattransfer".ComputationalMechanics14:385386.
doi:10.1007/BF00377593([Link]
5. JMohdJaniSHuangMLearyASubic(2015)."Numericalmodelingofshapememoryalloylinear
actuator".ComputationalMechanics:[Link].1007/s004660151180z
([Link]
6. MajumdarP(2005).Computationalmethodsforheatandmasstransfer(1sted.).TaylorandFrancis,New
York.
7. SmithGD(1985).Numericalsolutionofpartialdifferentialequations:finitedifferencemethods(3rded.).
OxfordUniversityPress.
8. Crank,[Link].2ndEdition,Oxford,1975,p.143.

[Link],NumericalSolutionofPartialDifferentialEquations,An
[Link],2005.
[Link],NumericalMethodswithApplications,(2008)[1]
([Link]
orientedintroductiontoFDM(forODEs)inChapter08.07
([Link]
JohnStrikwerda(2004).FiniteDifferenceSchemesandPartialDifferentialEquations(2nded.).
SIAM.ISBN9780898716399.
Smith,G.D.(1985),NumericalSolutionofPartialDifferentialEquations:FiniteDifference
Methods,3rded.,OxfordUniversityPress
PeterOlver(2013).IntroductiontoPartialDifferentialEquations
([Link]
319020990..
[Link],FiniteDifferenceMethodsforOrdinaryandPartialDifferentialEquations
([Link]

Externallinks
ListofInternetResourcesfortheFiniteDifferenceMethodforPDEs
([Link]
rencePDEBib_lnk_1.html)

Variouslecturesandlecturenotes
FiniteDifferenceMethodinElectromagnetics(seeandlistentolecture9)
([Link]
LectureNotes
([Link]
[Link])ShihHungChen,NationalCentralUniversity
FiniteDifferenceMethodforBoundaryValueProblems
([Link]
NumericalMethodsfortimedependentPartialDifferentialEquations
([Link]

[Link]

6/7

8/1/2015

FinitedifferencemethodWikipedia,thefreeencyclopedia

Retrievedfrom"[Link]
title=Finite_difference_method&oldid=673732214"
Categories: Finitedifferences Numericaldifferentialequations
Thispagewaslastmodifiedon30July2015,at03:23.
TextisavailableundertheCreativeCommonsAttributionShareAlikeLicenseadditionalterms
[Link],[Link]
registeredtrademarkoftheWikimediaFoundation,Inc.,anonprofitorganization.

[Link]

7/7

You might also like