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

fieldAverage over window complains about missing "windowType"

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By PositronCascade

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 4, 2023, 06:35
Default fieldAverage over window complains about missing "windowType"
  #1
New Member
 
Tobias
Join Date: Jul 2022
Posts: 14
Rep Power: 4
dalasrevo is on a distinguished road
Good morning (or whatever time it is with you).
I am using OF 2206 with interFoam and





I have a functionObject that looks and runs OK like this:
Code:
fieldAverage1
       {
        type                   fieldAverage;
        libs                    (fieldFunctionObjects);
        writeControl       writeTime;
        executeControl  writeTime;
              fields
              (
              U
                   {
                   mean               on;
                   prime2Mean     on;
                   base                time;
                    }
              );
       }
But actually during simulation I realized that I only want to calculate the average of the last 30 seconds. I looked into the User Guide (https://www.openfoam.com/documentati...ldAverage.html) and built the following FO:
Code:
       fieldAverage1
     {
         type                fieldAverage;
        libs            (fieldFunctionObjects);
         writeControl    writeTime;
         executeControl  writeTime;
         fields
         (
             U
             {
                 mean            on;
                 prime2Mean      on;
                 base            time;
                 window          2;
                 windowName      Uavg
                 windowType      exact;
             }
           );
         }
Now I always get an error message when I restart the simulation:
Quote:
2]
[2] --> FOAM FATAL IO ERROR: (openfoam-2206 patch=221104)
[2] Entry 'windowType' not found in dictionary "stream.functions.fieldAverage1.fields"
[2]
[2]
[2] file: stream.functions.fieldAverage1.fields at line 0.
[2]
[2] From bool Foam::dictionary::readEntry(const Foam::word&, T&, Foam::keyType:ption, bool) const [with T = Foam::word]
Does anyone have an idea what I am doing wrong here?
dalasrevo is offline   Reply With Quote

Old   February 5, 2023, 04:31
Default
  #2
Member
 
Hasan Celik
Join Date: Sep 2016
Posts: 64
Rep Power: 10
PositronCascade is on a distinguished road
You need a semicolon after
Code:
windowName      Uavg
probably, such that
Code:
windowName      Uavg;
Quote:
Originally Posted by dalasrevo View Post
Good morning (or whatever time it is with you).
I am using OF 2206 with interFoam and





I have a functionObject that looks and runs OK like this:
Code:
fieldAverage1
       {
        type                   fieldAverage;
        libs                    (fieldFunctionObjects);
        writeControl       writeTime;
        executeControl  writeTime;
              fields
              (
              U
                   {
                   mean               on;
                   prime2Mean     on;
                   base                time;
                    }
              );
       }
But actually during simulation I realized that I only want to calculate the average of the last 30 seconds. I looked into the User Guide (https://www.openfoam.com/documentati...ldAverage.html) and built the following FO:
Code:
       fieldAverage1
     {
         type                fieldAverage;
        libs            (fieldFunctionObjects);
         writeControl    writeTime;
         executeControl  writeTime;
         fields
         (
             U
             {
                 mean            on;
                 prime2Mean      on;
                 base            time;
                 window          2;
                 windowName      Uavg
                 windowType      exact;
             }
           );
         }
Now I always get an error message when I restart the simulation:
Does anyone have an idea what I am doing wrong here?
dalasrevo likes this.
PositronCascade is offline   Reply With Quote

Old   February 5, 2023, 06:50
Default
  #3
New Member
 
Tobias
Join Date: Jul 2022
Posts: 14
Rep Power: 4
dalasrevo is on a distinguished road
Do you also know such situations where you wish you hadn't written something because it's a bit ashaming?

Anyway, so I was a bit glad that there seemed to be other problems with my simulation:

I still got the following error

Code:
[13] 
[13] --> FOAM FATAL IO ERROR: (openfoam-2206 patch=221104)
[13] Entry 'windowTimes' not found in dictionary "stream.fieldAverage1.U"
[13] 
[13] 
[13] file: stream.fieldAverage1.U at line 0.
[13] 
[13] From bool Foam::dictionary::readEntry(const Foam::word&, T&, Foam::keyType::option, bool) const [with T = Foam::FIFOStack<double>]
[13] in file ./src/OpenFOAM/lnInclude/dictionaryTemplates.C at line
But the error together with

Quote:
Information regarding the number of averaging steps, and total averaging time are written on a per-field basis to the "<functionObject name>Properties" dictionary, located in <time>/uniform.
from https://www.openfoam.com/documentati...e.html#details

brought me to the conclusion that the uniform directory is the problem....

Many thanks for the input, it has brought me further!
dalasrevo 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
Mathematical meaning of window averaging in fieldAverage functionObject Tobermory OpenFOAM Post-Processing 2 December 31, 2022 10:44
fieldAverage - window and periodicRestart mechkween OpenFOAM 1 April 17, 2018 04:19
[OpenFOAM] Xlib: extension "GLX" missing on display goldbeard ParaView 5 March 24, 2013 14:12
errors when installing openfoam2.1 on ubuntu12.o4 hewei OpenFOAM Installation 5 May 29, 2012 08:43
Physics message window is missing Kindel CFX 3 August 18, 2010 17:45


All times are GMT -4. The time now is 21:03.