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

Pressure reference cell

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

Like Tree1Likes
  • 1 Post By maddalena

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 22, 2006, 04:16
Default There are two lines that need
  #1
Senior Member
 
Maka Mohu
Join Date: Mar 2009
Posts: 305
Rep Power: 18
maka is on a distinguished road
There are two lines that need to be commented in any channel solver that was written for OpenFOAM V 1.2 to work under V 1.3:

// fvScalarMatrix::reference pRef =
// pEqn.unsetReference(pRef);

otherwise we get errors like:
---------------------
channelOoddns.3.C: In function 'int main(int, char**)':
channelOoddns.3.C:126: error: 'reference' is not a member of 'Foam::fvScalarMatrix'
channelOoddns.3.C:126: error: expected `;' before 'pRef'
channelOoddns.3.C:129: error: 'struct Foam::fvScalarMatrix' has no member named 'unsetReference'
channelOoddns.3.C:129: error: 'pRef' was not declared in this scope
-----------------------------

My question, were unsetting the referenceCell unnecessary or it was included somewhere else in the code? I noticed that the same change was applied to icoFoam. Thanks.

Best regards,
Maka
maka is offline   Reply With Quote

Old   November 22, 2006, 04:42
Default I am not sure I know what you
  #2
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,905
Rep Power: 33
hjasak will become famous soon enough
I am not sure I know what you mean: if you have a pressure equations with boundaries that do not fix pressure level, you have to fix a reference pressure.

In OpenFOAM-1.3 the syntax has changed:

pEqn.setReference(pRefCell, pRefValue);

and you can see it in all the solvers.

Hrv
__________________
Hrvoje Jasak
Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk
hjasak is offline   Reply With Quote

Old   November 22, 2006, 05:17
Default I understand that but there we
  #3
Senior Member
 
Maka Mohu
Join Date: Mar 2009
Posts: 305
Rep Power: 18
maka is on a distinguished road
I understand that but there were a statement on V1.2 that used to unset the reference pressure after solving pEq.

pEqn.unsetReference(pRef);

where pRef used to be defined as :

fvScalarMatrix::reference pRef =
pEqn.setReference(pRefCell, pRefValue);

In V 1.3:
a) one can not define a variable of type fvScalarMatrix::reference; not a big problem.

b) one can not unset the reference pressure after solve pEq with a code like:

pEqn.unsetReference(pRef)

since the member function unsetReference does not exit any more.

my question, why we can not unset the reference cell pressure after solving in V1.3 (see b))? is such unsetReference process included by default in pEq.solve() implementation? Thanks for your prompt reply.

Best regards,
Maka
maka is offline   Reply With Quote

Old   November 22, 2006, 05:22
Default It is because the way the pres
  #4
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,905
Rep Power: 33
hjasak will become famous soon enough
It is because the way the pressure reference is set has changed: OF-1.2 uses a constraint, which needs to be removed and OF-1.3 uses a lighter touch method, slightly boosting the diagonal (does not need to be removed).

Hrv
__________________
Hrvoje Jasak
Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk
hjasak is offline   Reply With Quote

Old   November 22, 2006, 10:46
Default Thanks Hrv.
  #5
Senior Member
 
Maka Mohu
Join Date: Mar 2009
Posts: 305
Rep Power: 18
maka is on a distinguished road
Thanks Hrv.
maka is offline   Reply With Quote

Old   January 28, 2009, 05:47
Default Hi all, sorry for the stupid
  #6
Senior Member
 
maddalena's Avatar
 
maddalena
Join Date: Mar 2009
Posts: 436
Rep Power: 23
maddalena will become famous soon enough
Hi all,
sorry for the stupid question but... how can I get the pRefCell value? I am wondering if I can reference it using its coordinates (as I would do with Fluent) or if I have to extract the ref cell number from my grid... And in this case, how can I do that?
Thanks a lot.
Mad
maddalena is offline   Reply With Quote

Old   January 28, 2009, 09:40
Default As the user guide says: "Chang
  #7
Senior Member
 
maddalena's Avatar
 
maddalena
Join Date: Mar 2009
Posts: 436
Rep Power: 23
maddalena will become famous soon enough
As the user guide says: "Changing either of these values will change the absolute
pressure field, but not, of course, the relative pressure field or velocity field.
... Thus no need to know that value... ;-)
Cheers, mad
Owais Shabbir likes this.
maddalena is offline   Reply With Quote

Reply

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
Convergence control using reference Cell titio OpenFOAM Running, Solving & CFD 1 March 6, 2008 04:45
reference cell novice Siemens 1 April 30, 2004 09:00
reference pressure cell-where? Micha Siemens 6 June 20, 2003 05:27
Reference Pressure Danard CFX 2 November 12, 2002 14:11
Pressure Reference Cell mimě Siemens 1 June 17, 2002 08:29


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