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

C programming question eg simpleFoam

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

Reply
 
LinkBack Thread Tools Display Modes
Old   January 27, 2009, 08:57
Default Hi together, I am currently
  #1
New Member
 
Marc Wattenberg
Join Date: Mar 2009
Posts: 3
Rep Power: 8
marc_wattenberg is on a distinguished road
Hi together,

I am currently working on understanding the basics of the solver code. I am a litte bit familar with programming, but do not understand e.g.

UEqn().A()
UEqn().H()
mesh.Sf()
etc

For me its clear that some fuction A,H,AU... will act on the momentum equation, but where is the function defined. I already searched in the source guide but can not find A or H. I am sure someone can tell me the right procedure for understanding this

Thanks a lot
Marc
marc_wattenberg is offline   Reply With Quote

Old   January 27, 2009, 09:05
Default This is part of the PISO algor
  #2
Senior Member
 
Gavin Tabor
Join Date: Mar 2009
Posts: 181
Rep Power: 8
grtabor is on a distinguished road
This is part of the PISO algorithm. The momentum equation can be written as

a_p U_p = H(U) - grad(p)

for a point p. We need to be able to rearange this to solve it. .A() and .H() give access to the relevant components; roughly the diagonal of the matrix and the off-diagonal non-pressure components, respectively.

.Sf() gives the face normal vectors IIRC

Gavin
grtabor is offline   Reply With Quote

Old   January 27, 2009, 09:12
Default Thanks Gavin, but this was
  #3
New Member
 
Marc Wattenberg
Join Date: Mar 2009
Posts: 3
Rep Power: 8
marc_wattenberg is on a distinguished road
Thanks Gavin,

but this was clear to me. I want to know where to find the definitions of A()... inside the code

Marc
marc_wattenberg is offline   Reply With Quote

Old   January 27, 2009, 19:32
Default Dear Marc, Try rummaging ar
  #4
Senior Member
 
Gavin Tabor
Join Date: Mar 2009
Posts: 181
Rep Power: 8
grtabor is on a distinguished road
Dear Marc,

Try rummaging around in OpenFOAM-1.5/src/finiteVolume/fvMatrices

Gavin
grtabor is offline   Reply With Quote

Reply

Thread Tools
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
UDF programming fullmonty FLUENT 5 June 30, 2011 02:40
Question about simplefoam and turbFoam rogerio OpenFOAM Running, Solving & CFD 2 June 13, 2005 07:16
Programming Question Leo Main CFD Forum 2 June 14, 2004 06:54
Programming in CFD Lam Main CFD Forum 7 May 27, 2004 05:12
Programming question tom Main CFD Forum 2 August 11, 2003 13:24


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