|
[Sponsors] |
February 10, 2010, 16:09 |
Mixed/Robin boundary condition
|
#1 |
New Member
Anton Evgrafov
Join Date: Jun 2009
Posts: 3
Rep Power: 17 |
I am quite new to OpenFOAM and therefore am not entirely sure whether this is a bug or a feature, but results one obtains when selecting valueFraction in ]0,1[ when using 'mixed' boundary condition (i.e., a truly mixed/Robin-type boundary condition, not a pure Dirichlet or a Neumann one) depend on the grid size, which seems quite startling to me. For example, I attach a small effectively one-dimensional test-case (tar-ed gzip-ed test_bc.tar.gz) of a steady-state heat conduction problem on a unit square, where at the bottom boundary a mixed BC is prescribed with refValue=-1.0, and refGradient=2.0. The solution to this problem varies linearly from top (where T=0 is prescribed) to bottom, so for a purely Dirichlet problem (valueFraction=1) T_Dir=-1.0 at the "mixed" boundary, and for purely Neumann case (valueFraction=0) T_Neum=n*grad(T)=2.0 there. Therefore, say for valueFraction = 0.5 I would expect T=0.5*(T_Dir + T_Neum) = 0.5; however, one may easily check that this value depends on the number of elements in the mesh and in fact converges to T_Dir as the mesh is refined.
Such behaviour can be fixed if one uses newValueFraction_=valueFraction_/(valueFraction_ + (1.0-valueFraction_)*this->patch().deltaCoeffs()); in place of valueFraction_ in the implementation of the mixed boundary condition (I can sketch a small note why, and I tried to write a comment about this in my amateurish C++ implementation of mixed1 boundary condition-also in the attached archive), which now produces expected mesh-independent results. You can try it out by building the corrected mixed1 boundary condition (wmake libso in mixed1BC.d); and then changing mixed->mixed1 in test_bc/0/T file and uncommenting the 'libs' line in test_bc/system/controlDict to load the mixed1 BC. Please let me know if I mis-understand the purpose or the expected behaviour of the original mixed boundary condition in OpenFOAM. Sincerely, --Anton Evgrafov |
|
December 15, 2011, 15:03 |
|
#3 |
New Member
Anton Evgrafov
Join Date: Jun 2009
Posts: 3
Rep Power: 17 |
||
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Boundary Conditions | Thomas P. Abraham | Main CFD Forum | 20 | July 7, 2013 06:05 |
Transient outlet boundary condition problem | jwillie2000 | CFX | 1 | December 7, 2009 18:07 |
Axis Boundary Condition..what is it? | CFDtoy | FLUENT | 6 | February 13, 2007 06:51 |
How to set boundary condition in Fluent for the fo | Peiyong | FLUENT | 1 | November 10, 2006 12:44 |
How to resolve boundary condition problem? | sam | FLUENT | 2 | July 20, 2003 03:19 |