CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > General Forums > Main CFD Forum

Basic question on Crank-Nicolson method.

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree1Likes
  • 1 Post By FMDenaro

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   December 16, 2020, 11:34
Default Basic question on Crank-Nicolson method.
  #1
Senior Member
 
Mandeep Shetty
Join Date: Apr 2016
Posts: 185
Rep Power: 10
granzer is on a distinguished road
I had worked with the Crank Nicolson method in college to solve the diffusion equation.... but there I had always used central differencing to discretize the space terms. Even now when I look-up most of the texts and notes explain the CN method I find the use of central differencing for the space derivative terms. My question is can we use another method, like say forward differencing or backward differencing, instead of central differencing (I realize they are first order and I don't know if they will stable) to discretize the space terms?

I asking because in OpenFOAM we use CN scheme for time terms and can pick any other schemes for the Gradient or Laplacian or some other space terms, which are not central differencing. So this made me go back to what I had learned during my college days.
granzer is offline   Reply With Quote

Old   December 16, 2020, 12:15
Default
  #2
Senior Member
 
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,793
Rep Power: 71
FMDenaro has a spectacular aura aboutFMDenaro has a spectacular aura aboutFMDenaro has a spectacular aura about
Quote:
Originally Posted by granzer View Post
I had worked with the Crank Nicolson method in college to solve the diffusion equation.... but there I had always used central differencing to discretize the space terms. Even now when I look-up most of the texts and notes explain the CN method I find the use of central differencing for the space derivative terms. My question is can we use another method, like say forward differencing or backward differencing, instead of central differencing (I realize they are first order and I don't know if they will stable) to discretize the space terms?

I asking because in OpenFOAM we use CN scheme for time terms and can pick any other schemes for the Gradient or Laplacian or some other space terms, which are not central differencing. So this made me go back to what I had learned during my college days.



The answer is that you can formally use any type of spatial discretization, the CN can be seen as a second order trapezodial rule for the time integration. But your final goal is to have a stable and accurate solution and is suitable to use at least a second order accurate spatial discretization.

I used personally with success the CN scheme coupled to a fourth order accurate spatial discretization.
granzer likes this.
FMDenaro is offline   Reply With Quote

Old   December 16, 2020, 12:20
Default
  #3
Senior Member
 
Mandeep Shetty
Join Date: Apr 2016
Posts: 185
Rep Power: 10
granzer is on a distinguished road
Quote:
Originally Posted by FMDenaro View Post
The answer is that you can formally use any type of spatial discretization, the CN can be seen as a second order trapezodial rule for the time integration. But your final goal is to have a stable and accurate solution and is suitable to use at least a second order accurate spatial discretization.

I used personally with success the CN scheme coupled to a fourth order accurate spatial discretization.
Thank you so much! I don't know why most of the books or note that I found don't mention this...and only use th central differencing scheme for space terms.
granzer is offline   Reply With Quote

Reply

Tags
crank-nicolson

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Implementtaion of Crank Nicolson scheme in OpenFOAM hchen OpenFOAM Running, Solving & CFD 5 May 6, 2020 14:25
Fraction Step Method Question matdehaast Main CFD Forum 6 January 17, 2016 10:39
A fundamental question on FDF (Filtered density function) method for turbulent flow levinperson Main CFD Forum 0 December 20, 2015 14:51
Basic question about writing a differential equation related to finite element RbBb Main CFD Forum 1 April 10, 2014 03:50
Basic question forsumit OpenFOAM 0 April 7, 2010 10:46


All times are GMT -4. The time now is 08:03.