CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Post-Processing

postProcess Utility Errors

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 24, 2021, 11:57
Question postProcess Utility Errors
  #1
New Member
 
Jeffrey Johnston
Join Date: Oct 2020
Location: Belfast, Northern Ireland
Posts: 6
Rep Power: 2
NotDrJeff is on a distinguished road
Hello,

I am working on a case were I have defined some function objects in my controlDict including forces, fieldAverage, and some probes etc.

Code:
forces_object
{
    type    forces;
    libs    ("libforces.so");
    patches ("square");
    p       p;
    U       U;
    rho     rhoInf; //only use rhoInf for incompressible flows
    rhoInf  1000;
    CofR    (0 0 0); //Centre of rotation
    enabled true;
}
///////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////
probes1
{
    type probes;
    libs ("libsampling.so");
    //dictionary probesDict;
    probeLocations
    (
	(0.025 0 0)
	(0.05 0 0)
	(0.075 0 0)
	(0.1 0 0)
	(0.15 0 0)
	(0.3 0 0)
	(0.5 0 0)
    );
    
    fields
    (
        p pMean pPrime2Mean
        U UMean UPrime2Mean
        k kMean kPrime2Mean
        omega omegaMean omegaPrime2Mean
    );
}
///////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////
yplus
{
    type    yPlus;
    libs    (fieldFunctionObjects);

    enabled true;
    writeControl writeTime;
}
///////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////
Q
{
    type    Q;
    libs    (fieldFunctionObjects);

    enabled true;
    writeControl writeTime;
}
///////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////
fieldAverage
{
    type    fieldAverage;
    libs    (fieldFunctionObjects);
    
    fields
    (
        U
        {
            mean        yes;
            prime2Mean  yes;
            base        time;
        }
        
        p
        {
            mean        yes;
            prime2Mean  yes;
            base        time;
        }
        
        k
        {
            mean        yes;
            prime2Mean  yes;
            base        time;
        }
        
        omega
        {
            mean        yes;
            prime2Mean  yes;
            base        time;
        }
    );
    
    enabled         true;
    timeStart       0.1;
    writeControl writeTime;
}
I forgot to make a change to my fieldAverage sub-dictionary before running my solver which means averages weren't calculated (I had a startTime of 100 when I was only running the case for 10s. The above was corrected after the simulation was complete).

No problem. I can just run the postProcessing utility and calculate these values after the fact can't I?

But I ran into an error. I think the error is something to do with the forces. This is strange as the forces were calculated during the actual run.

Code:
Create time

--> FOAM Warning : 
    From void Foam::Time::setControls()
    in file db/Time/Time.C at line 244
    Increasing the timePrecision from 6 to 16 to support the formatting of the current time directory 10.00012

Create mesh for time = 0

forces forces_object:
    p: p
    U: U
    rho: rhoInf
    Freestream density (rhoInf) set to 1000
    Not including porosity effects

fieldAverage fieldAverage:
    Restarting averaging for fields:
        U: starting averaging at time 0
        p: starting averaging at time 0
        k: starting averaging at time 0
        omega: starting averaging at time 0

Time = 0

Reading fields:

Executing functionObjects


--> FOAM FATAL ERROR: 
Could not find U: U or p:p in database

    From void Foam::functionObjects::forces::initialise()
    in file forces/forces.C at line 227.

FOAM exiting
Strange, but I don't care about the forces. I just need to calculate my fieldAverages, then probe those values.

So I try entering
Code:
postProcess -func fieldAverage
I assumed that this would look in the controlDict first for parameters. Am I correct?

The utility runs, but doesn't actually calculate anything. Here's an extract:

Code:
Time = 9.60012

Reading fields:

Executing functionObjects

Time = 9.70012

Reading fields:

Executing functionObjects

Time = 9.80012

Reading fields:

Executing functionObjects

Time = 9.90012

Reading fields:

Executing functionObjects

Time = 10.00012

Reading fields:

Executing functionObjects

End
What am I missing?

Thanks,
Jeffrey
NotDrJeff is offline   Reply With Quote

Reply

Tags
fieldaverage, forces, postprocess

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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
PostProcess streamline utility ErenC OpenFOAM Post-Processing 1 March 26, 2021 18:16
LES, Courant Number, Crash, Sudden Alhasan OpenFOAM Running, Solving & CFD 5 November 22, 2019 02:05
PostProcess utility with swakExpression fchagas OpenFOAM Post-Processing 1 October 20, 2019 11:47
Convergence moving mesh lr103476 OpenFOAM Running, Solving & CFD 30 November 19, 2007 14:09
IcoFoam parallel woes msrinath80 OpenFOAM Running, Solving & CFD 9 July 22, 2007 02:58


All times are GMT -4. The time now is 15:24.