|
[Sponsors] |
October 23, 2013, 12:41 |
wrong behavior of functionObject volAverage
|
#1 |
New Member
Join Date: Jan 2012
Location: Germay - Stuttgart
Posts: 21
Rep Power: 0 |
Hi FOAMers!
There are some issues with the functionObjects in my simulation. I'm running an engine simulation and try to calculate the volume averages of some fields inside the cylinder. In order to this I defined a functionObject [1] in my controlDict. Unfortunately it's not behaving like I expected. Running this case (startTime 280, writeInterval 1) I get a directory ./volumeAverage_myAverage/280/ with files p,T,k... with the averages inside. So far, so good. But instead of getting new directories 281, 282 in ./volumeAverage_myAverage all the averages are written to the files p,T,k in ./volumeAverage_myAverage/280. And additionally the column "Time" in this files is some value with no relation to the timeStep or anything [2]. For "Time" I expected 280.25 280.5... I already play around with the valueOutput and outputControl options but whatever I set, it did always the same. Next problem is the volume taken for averaging. I need to use a cellZone to get rid of the intake and exhaust cells and just averaging the cylinder cells. The "source cellZone" option should be great for this. But I played a little bit with it and did the banana test with the cellZone name. I expected to get an error like "Could not find cellZone with the name "banana" but it didn't complain. My solver does already calculate a volume average of the complete field (including exhaust and intake) and it's exactly the same values as calculated with the functionObject and correct set "source cellZone" and "sourceName cylbox". So what am I doing wrong? I'm using OpenFOAM-1.5-dev and so I can't use swak4foam. Thanks for your help in advance. Regards, HaZe. [1] functions in controlDict Code:
functions ( myAverage { type volumeAverage; functionObjectLibs ("libsimpleFunctionObjects.so"); enabled true; outputControl outputTime; outputInterval 1; verbose true; valueOutput false; source cellZone; sourceName cylbox; operation volAverage; fields ( k kDiffusion EpsilonDiffusion p T ); } ); Code:
# Time average 0.0291927 99112 0.0292188 98202.7 0.0292448 97322.1 0.0292708 96473.4 0.0292969 95644.5 0.0293229 94824.6 0.029349 94006.4 0.029375 93184.4 0.029401 92354.2 0.0294271 91512.5 0.0294531 90657.8 0.0294792 89790.9 |
|
Tags |
field average, functionobject, volumeaverage |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
udf error | srihari | FLUENT | 1 | October 31, 2016 15:18 |
[OpenFOAM] turbineSiting tutorial and paraview-3.98.0 | pajot | ParaView | 4 | September 14, 2013 11:19 |
Create registered object at runtime using a functionObject | CedricVH | OpenFOAM Programming & Development | 21 | November 28, 2012 06:04 |
runTime out of scope in functionObject | Sune | OpenFOAM Programming & Development | 2 | September 26, 2012 03:11 |
BuoyantBoussinesqSimpleFoam and axial-symmetric results wrong mass flow | Thomas Baumann | OpenFOAM | 6 | December 21, 2009 11:31 |