CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Visualization & Post-Processing Software > ParaView

[OpenFOAM] Acquiring scalar names

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 8, 2006, 13:55
Default Acquiring scalar names
  #1
Member
 
Terry Jordan
Join Date: Mar 2009
Posts: 95
Rep Power: 17
tj22 is on a distinguished road
As discussed before I am writing a reader for paraview which does not require installing OpenFOAM. I am looking through the files to obtain the names of the scalars for the timesteps while the names for timestep 0 are available in fvSolution, I cannot locate a file containing the names of all the scalars available in the other timesteps. There seem to be more scalars in those timesteps than in timestep 0.

So is there a file that contains these names? Or will I have to do a directory dump? (which will cause a problem of not being cross platform).
tj22 is offline   Reply With Quote

Old   May 9, 2006, 06:01
Default I'm afraid there is no such fi
  #2
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51
gschaider will become famous soon enoughgschaider will become famous soon enough
I'm afraid there is no such file (and it's even worse: you'll have to look into the files to determine whether they're vol-Fields or not)
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request
gschaider is offline   Reply With Quote

Old   May 9, 2006, 10:58
Default It is really no problem to par
  #3
Member
 
Terry Jordan
Join Date: Mar 2009
Posts: 95
Rep Power: 17
tj22 is on a distinguished road
It is really no problem to parse the header to determine vector, scalar, etc, it is however a problem to have no idea what files are avaible to parse.

I guess my only option is to call a system command to acquire the directory structure, that is going to be painful.
tj22 is offline   Reply With Quote

Old   May 15, 2006, 14:50
Default Look at usage of IOobjectList,
  #4
Senior Member
 
Mattijs Janssens
Join Date: Mar 2009
Posts: 1,419
Rep Power: 26
mattijs is on a distinguished road
Look at usage of IOobjectList, e.g. in dataConversion/foamDataToFluent/foamDataToFluent.C

It will return you a list of all Foam files in a time directory. You can then use e.g. lookupClass to extract files of a certain type.
mattijs is offline   Reply With Quote

Old   May 17, 2006, 13:01
Default Actually the answer was to use
  #5
Member
 
Terry Jordan
Join Date: Mar 2009
Posts: 95
Rep Power: 17
tj22 is on a distinguished road
Actually the answer was to use vtkDirectory but thanks.
tj22 is offline   Reply With Quote

Reply


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
problem during mpi in server: expected Scalar, found on line 0 the word 'nan' muth OpenFOAM Running, Solving & CFD 3 August 27, 2018 04:18
Division by zero exception - loop over scalarField Pat84 OpenFOAM Programming & Development 6 February 18, 2017 05:57
Issue symmetryPlane 2.5d extruded airfoil simulation 281419 OpenFOAM Running, Solving & CFD 5 November 28, 2015 13:09
Diverging solution in transonicMRFDyMFoam tsalter OpenFOAM Running, Solving & CFD 30 July 7, 2014 06:20
compressible flow in turbocharger riesotto OpenFOAM 50 May 26, 2014 01:47


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