|
[Sponsors] |
November 16, 2014, 17:38 |
groovyBC using swakExpression
|
#1 |
New Member
Kalli
Join Date: Jul 2014
Posts: 9
Rep Power: 12 |
I am writing a BC for a patch in my computational domain using groovyBC which uses the average value of temperature on a faceSet created using topoSet utility.
I can write the average temperature on faceSet using swakExpression but I am not sure how to use it in groovyBC for a faceSet created from topoSet. Is it possible? Instead, one can access the temperature of other patches in groovyBC but is it possible to access field variables like temperature on a faceSet. Thank you for your insight and help. |
|
November 16, 2014, 19:07 |
|
#2 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
November 17, 2014, 02:45 |
|
#3 | ||
New Member
Kalli
Join Date: Jul 2014
Posts: 9
Rep Power: 12 |
Quote:
Thank you very much for pointing me to right direction. I apologize as I didn't pose the question as I should have. Your solution does answer the question I had asked in first post perfectly. I think I should give you a little more background on what I am trying to achieve. I have developed a multiRegion solver which is similar to chtMultiRegionFoam. A simple representation of my case is shown below. My sensor is a faceSet in different region, i.e. AIR and using the average temperature calculated on this faceSet I intend to calculate my boundary condition using an expression that I define using groovyBC on a patch defined in different region, i.e. SOLID. As the faceSet is defined for the region AIR, it doesn’t get accessed by groovyBC on the region SOLID. I get an error Quote:
Sorry again for curt explanation of my problem earlier. |
|||
November 17, 2014, 06:09 |
Solved
|
#4 | |
New Member
Kalli
Join Date: Jul 2014
Posts: 9
Rep Power: 12 |
I think I have figured it out. If someone else is facing similar problem like the one described above, you can refer to the example multiRegionHeaterFeedback in Examples/groovyBC folder.
the syntax is like this Quote:
|
||
November 17, 2014, 06:10 |
|
#5 |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Good. I was just going to point you to the same Example
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
|
November 17, 2014, 06:23 |
|
#6 |
New Member
Kalli
Join Date: Jul 2014
Posts: 9
Rep Power: 12 |
Thanks again Bernhard. As I explore OpenFOAM further I realize that no other tool improves FOAM's usability like swak4foam.
|
|
Tags |
faceset, groovybc, gschaider, swak4foam, wyldkat |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[swak4Foam] groovyBC for oscillatory flow | liybzd | OpenFOAM Community Contributions | 5 | November 12, 2018 08:53 |
[swak4Foam] reactingMultiPhaseEulerFoam problems with groovyBC | zanilu70 | OpenFOAM Community Contributions | 4 | December 13, 2016 07:46 |
[swak4Foam] Change in alpha and U with groovyBC in twoPhaseEulerFoam | dani2702 | OpenFOAM Community Contributions | 0 | November 17, 2016 04:30 |
[swak4Foam] groovyBC issue - k and epsilon | sagnikmazumdar | OpenFOAM Community Contributions | 24 | March 1, 2015 08:16 |
[swak4Foam] groovyBC and Eqn.setReference() | benk | OpenFOAM Community Contributions | 3 | June 2, 2011 09:49 |