使用OpenFoam9后处理fieldAverage出现错误
-
使用OpenFoam9进行数值模拟。我现在想要对求出来的速度长计算时间的均值。发现有个后处理命令可以使用 postProcess -func fieldAverage -field U。但是终端运行后,仅仅是在每个算例文件夹下生成了一个uniform文件夹,文件夹里有一个fieldAverageProperties.gz,内容如下:
FoamFile { format ascii; class dictionary; location "0/uniform"; object fieldAverageProperties; }
不知道是为什么?
我又清除了算例,在controDict字典下输入
functions { fieldAverage1 { type fieldAverage; functionObjectLibs ("libfieldFunctionObjects.so"); enabled true; writeControl timeStep; writeInterval 1; fields { U { mean on; prime2Mean off; base time; } } } }
运行后,报错了。报错内容如下,
--> FOAM FATAL IO ERROR: Attempt to return dictionary entry as a primitive file: /home/tk/OpenFOAM/run/XXY/INLET-1.2e-8-Wi-7.5/system/controlDict/functions/fieldAverage1/fields from line 68 to line 70. From function virtual Foam::ITstream& Foam::dictionaryEntry::stream() const in file db/dictionary/dictionaryEntry/dictionaryEntry.C at line 83.
提示下面几行有错
U { mean on; prime2Mean off; base time; }
但是我不知道为什么?请求各位前辈指点。
-
@wangfei9088 多谢指教,已解决