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

Unable to set reference cell for field p; Please supply either pRefCell or pRefPoi

Register Blogs Community New Posts Updated Threads Search

Like Tree26Likes
  • 26 Post By Antimony

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 5, 2017, 17:38
Default Unable to set reference cell for field p; Please supply either pRefCell or pRefPoi
  #1
New Member
 
UHGAR
Join Date: Sep 2016
Posts: 12
Rep Power: 10
UHGAR is on a distinguished road
Hello All,

I am getting this following error when I try to run an existing OpenFoam case setup. I request any of you to please advise on fixing this issue.

Code:
/*---------------------------------------------------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  2.1.RG                                |
|   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
Build  : 2.1.RG
Exec   : cmcSIMPLEFoam
Date   : Feb 05 2017
Time   : 16:27:04
Host   : "lab"
PID    : 6207
Case   : /media/WorkData2017/CMC_OF/BFS_sim_sCO2_Tables_sCO2BC
nProcs : 1
sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE).
fileModificationChecking : Monitoring run-time modified files using timeStampMaster
allowSystemOperations : Allowing user-supplied system call operations

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time

Create mesh for time = 0

Reading combustion properties

Reading thermophysical properties

Selecting thermodynamics package hPsiMixtureThermo<homogeneousMixture<sutherlandTransport<specieThermo<janafThermo<perfectGas>>>>>

Reading field U


Creating field T


create field c


create field cVar

Reading/calculating face flux field phi



--> FOAM FATAL IO ERROR: 
Unable to set reference cell for field p
    Please supply either pRefCell or pRefPoint


file: /media/WorkData/DOE_2017/CMC_OF/BFS_Carlos_sim_sCO2_Tables_sCO2BC/system/fvSolution::SIMPLE from line 117 to line 117.

    From function void Foam::setRefCell
(
    const volScalarField&,
    const volScalarField&,
    const dictionary&,
    label& scalar&,
    bool
)
    in file cfdTools/general/findRefCell/findRefCell.C at line 125.

FOAM exiting

Last edited by UHGAR; February 6, 2017 at 12:08.
UHGAR is offline   Reply With Quote

Old   February 6, 2017, 04:25
Default
  #2
Senior Member
 
Join Date: Aug 2013
Posts: 407
Rep Power: 16
Antimony is on a distinguished road
Hi,

My guess is that in 'p' you have given zeroGradient at all boundaries. From what I know you need to set value of pressure at least at one point so that you can get well-defined system that can be solved. Just add these two lines to your fvSolutions in the SIMPLE block:

Code:
pRefCell    0;
pRefValue    0;
Cheers,
Antimony
gaza, manishm.cfd, serles and 23 others like this.
Antimony is offline   Reply With Quote

Old   February 27, 2021, 10:00
Default
  #3
Member
 
Bushra Rasheed
Join Date: Dec 2020
Posts: 97
Rep Power: 5
B_R_Khan is on a distinguished road
Quote:
Originally Posted by Antimony View Post
Hi,

My guess is that in 'p' you have given zeroGradient at all boundaries. From what I know you need to set value of pressure at least at one point so that you can get well-defined system that can be solved. Just add these two lines to your fvSolutions in the SIMPLE block:

Code:
pRefCell    0;
pRefValue    0;
Cheers,
Antimony
Thank You for this! It really works!
However I don't know what values should I give in pRefCell and pRefValue. I got this error while using simpleFoam on lid driven cavity. Inserting this in Fv solutions removes the error but the results don't show any pressure contours . Is it the 0 pRefValue that is giving no pressure contours or is it something else?

Thanks
B_R_Khan is offline   Reply With Quote

Old   July 22, 2022, 13:08
Default
  #4
New Member
 
Join Date: Apr 2021
Posts: 1
Rep Power: 0
PJmec45 is on a distinguished road
I've got the same problem
PJmec45 is offline   Reply With Quote

Reply

Tags
prefcell, prefpoint


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
Setting the height of the stream in the free channel kevinmccartin CFX 12 October 13, 2022 22:43
Sig Density Based Solver installation with FOAM Extend 3.2 qjh888 OpenFOAM Bugs 0 September 21, 2016 09:16
Simple piston movement in cylinder- fluid models arun1994 CFX 4 July 8, 2016 03:54
G95 + CGNS Bruno Main CFD Forum 1 January 30, 2007 01:34
Building OpenFoAm on SGI Altix 64bits anne OpenFOAM Installation 8 June 15, 2006 10:27


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