CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Programming & Development

Writing face centre values

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

Reply
 
LinkBack Thread Tools Display Modes
Old   February 8, 2014, 08:09
Default Writing face centre values
  #1
Member
 
Ashwani
Join Date: Sep 2013
Location: Hyderabad
Posts: 88
Rep Power: 3
AshwaniAssam is on a distinguished road
Hi all,

Is runTime.write() is only for writing volume fields? If yes what is the equivalent for writing face values.

For

surfaceScalarField Mach_sf = M_Lplus +M_Rminus;

I want to write at runtime value of Mach_sf.

Ashwani
AshwaniAssam is offline   Reply With Quote

Old   February 28, 2014, 12:11
Default
  #2
Senior Member
 
Mohammad Shakil Ahmmed
Join Date: Oct 2012
Location: AU
Posts: 123
Rep Power: 5
ahmmedshakil is on a distinguished road
You can have a look at the writeCellCentres utility, and Mach_sf.write() should work .
ahmmedshakil is offline   Reply With Quote

Old   March 2, 2014, 05:01
Default
  #3
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,619
Rep Power: 25
ngj will become famous soon enoughngj will become famous soon enough
Good morning,

No, runTime outputting also works for surfaceField<Type>, but you should make sure that you do not define your field inside a scope, such that it is deleted, once runTime.write() is executed.

If these things is not a problem, then it might be the write properties of the field, which can be changed with something along the following line:

Code:
fieldName.regIOobject::writeOpt() = IOobject::AUTO_WRITE;
Kind regards,

Niels
__________________
Please note that I do not use the Friend-feature, so do not be offended, if I do not accept a request.
ngj 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
how to set periodic boundary conditions Ganesh FLUENT 13 January 22, 2014 05:11
FvMatrix coefficients shrina OpenFOAM Running, Solving & CFD 10 October 3, 2013 14:38
non-orthogonal faces and incorrect orientation? nennbs OpenFOAM Native Meshers: blockMesh 7 April 17, 2013 05:42
Assigning face values into nodes syavash FLUENT 2 September 19, 2012 20:46
face and cell centered values danihuso OpenFOAM 0 July 17, 2009 11:01


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