|
[Sponsors] |
June 11, 2020, 08:29 |
Looking for a 2-D SIMPLE code
|
#1 |
New Member
Join Date: Aug 2014
Posts: 18
Rep Power: 12 |
Hi,
I am looking for a SIMPLE 2-D demonstration code with following capacities: 1. 2-D lid-driven cavity and natural convection (Re value range: 1~1000) 2. based on SIMPLE algorithm 3. collocated arrangment 4. incompressible, Newtonian fluid 5. implemented using matlab Best, f |
|
June 14, 2020, 05:24 |
|
#2 | |
Senior Member
Troy Snyder
Join Date: Jul 2009
Location: Akron, OH
Posts: 220
Rep Power: 19 |
Quote:
But I do notice that you previously posted a lid-driven cavity code (written in matlab) for which you were having some difficulty. Problematic lid-driven cavity using SIMPLE on collocated grid I took a look at your code, and I think the issue is that you do not properly apply under-relaxation to the momentum equations. The momentum under-relaxation parameters are applied when solving the momentum equations and will therefore implictly impact the pressure-correction equation solution. They will affect the stability and convergence rates of both the momentum and pressure correction equations. See Section 6.4 in Versteeg and Malalasekera (1995 copy) for more details on this. In your code (see link above), you apply relaxation to the u- and v-velocity components at the point at which the pressure correction equations are applied. Something like --> This is NOT correct. Note that in equation 6.15 in the aforementioned text that . The under-relaxation has already impacted the computation via the momentum equations and via the mass imbalance (source) terms within the pressure-correction equation. Hopefully you can get your own code working as a result of this suggestion. |
||
June 14, 2020, 09:23 |
|
#3 |
New Member
Join Date: Aug 2014
Posts: 18
Rep Power: 12 |
Hi Troy,
Thank you for your reply, I will try to fix the bug you find. Best, f |
|
June 17, 2020, 06:23 |
Bug found and fixed.
|
#4 |
New Member
Join Date: Aug 2014
Posts: 18
Rep Power: 12 |
Indeed, a worng under-relaxation method was used. Now new code with this bug fixed are available here:
Problematic lid-driven cavity using SIMPLE on collocated grid Many thanks, Troy @tas38. |
|
Tags |
collocated, lid-driven cavity, natural convection, simple |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
code for SIMPLE algorithm - 2D Lid driven cavity flow problem - Collocated grid | h_amooie | OpenFOAM Programming & Development | 1 | January 22, 2022 12:33 |
suction force in simple code | sciense | Main CFD Forum | 0 | June 8, 2015 11:02 |
help!on simple method code | houkensjtu | Main CFD Forum | 0 | July 9, 2011 11:45 |
SIMPLE code for 3_D problem | bobby | Main CFD Forum | 1 | December 26, 2000 00:20 |
SIMPLE code | Bivan | Main CFD Forum | 8 | October 24, 2000 22:25 |