CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

How to give following BC using GroovyBC

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 16, 2019, 08:06
Default How to give following BC using GroovyBC
  #1
Senior Member
 
Ashwani
Join Date: Sep 2013
Location: Hyderabad
Posts: 154
Rep Power: 13
AshwaniAssam is on a distinguished road
Hi,


I have to give the following boundary condition for pressure
\frac{dp}{dx} = -\rho\frac{d \phi_g}{dx}


where

\phi_g=x and it is a variable defined in the code.


I coded it like this

Code:
    side0
    {
    type groovyBC;
    gradientExpression "rho0";
        variables "rho0=-rho*snGrad(phig);";
    value uniform -1.0;
    fractionExpression "0";
    }
But it is giving a wrong value. For phi_g = x, gradient value at the boundary should be equal to -\rho but it is giving something different.
AshwaniAssam is offline   Reply With Quote

Reply


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
Mesh motion by groovyBc peyman.havaej OpenFOAM 4 August 23, 2019 06:51
[swak4Foam] groovyBC for oscillatory flow liybzd OpenFOAM Community Contributions 5 November 12, 2018 08:53
[swak4Foam] funkySetFields and groovyBC error otq OpenFOAM Community Contributions 7 September 9, 2014 17:42
[swak4Foam] OpenFOAM 1.6 and 1.7 with interFoam, groovyBC give different strange results Arnoldinho OpenFOAM Community Contributions 7 December 9, 2010 17:29
[swak4Foam] Scale discrete inlet velocity profile with groovyBC cboss OpenFOAM Community Contributions 1 June 20, 2010 14:02


All times are GMT -4. The time now is 09:02.