# Mixed/Robin boundary condition

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

February 10, 2010, 15:09
Mixed/Robin boundary condition
#1
New Member

Anton Evgrafov
Join Date: Jun 2009
Posts: 3
Rep Power: 16
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
Attached Files
 test_bc.tar.gz (4.6 KB, 114 views)

 December 15, 2011, 13:18 Thanks #2 Member   Ilya Join Date: Dec 2011 Location: Russia Posts: 97 Blog Entries: 41 Rep Power: 14 Today I found that Robin BC give incorrect temperatures on the wall Twall>Tref. Your post could be useful. Tomorrow I'll try It. А ещё, Вы говорите по-русски?)

December 15, 2011, 14:03
#3
New Member

Anton Evgrafov
Join Date: Jun 2009
Posts: 3
Rep Power: 16
Quote:
 Originally Posted by skeptik А ещё, Вы говорите по-русски?)
da, govoru

 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 OffTrackbacks are Off Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post Thomas P. Abraham Main CFD Forum 20 July 7, 2013 05:05 jwillie2000 CFX 1 December 7, 2009 17:07 CFDtoy FLUENT 6 February 13, 2007 05:51 Peiyong FLUENT 1 November 10, 2006 11:44 sam FLUENT 2 July 20, 2003 02:19

All times are GMT -4. The time now is 06:13.