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

Reading a CSV file using interpolationTable

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   September 3, 2016, 07:42
Default Reading a CSV file using interpolationTable
  #1
Senior Member
 
Join Date: Sep 2015
Location: Singapore
Posts: 102
Rep Power: 11
usv001 is on a distinguished road
Hello all,

I am trying to use the interpolationTable<type> class. I am constructing it from a dictionary. I have no problems reading a table in the 'openFoam' format but when I try to use the 'csv' format, the constructor function results in the following error:

Code:
--> FOAM FATAL ERROR: 
table read from "/media/usv/Linux/OpenFOAM/JET/nozzle/3D/NPR4/postProcessing/surfaces/0.0120/inlet/Rrr.csv" is empty


    From function Foam::interpolationTable<Type>::readTable()
    in file /home/usv/OpenFOAM/OpenFOAM-2.4.0/src/OpenFOAM/lnInclude/interpolationTable.C at line 49.

FOAM exiting
I am not too sure of the reason. The csv file does exist at the correct location and it is in the following form:

Code:
y/R,Rrr
0,0
0.001,1.30551E-05
0.002,5.22203E-05
...
My dictionary file looks like this:

Code:
readerType      csv;
fileName        "$FOAM_CASE/postProcessing/surfaces/0.0120/inlet/Rrr.csv";
outOfBounds	clamp;
hasHeaderLine   true;
timeColumn      0;
valueColumns    (1);
Anyone has any idea as to why the table is unable to read the csv file?

Thanks in advance.
usv001 is offline   Reply With Quote

Old   May 25, 2022, 13:22
Default
  #2
New Member
 
Utkan Erdem
Join Date: Sep 2020
Posts: 19
Rep Power: 6
Utkan is on a distinguished road
Hello,
How did you solve this problem? I am trying to perform a similar task and receiving the same error.
Utkan 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
[foam-extend.org] problem when installing foam-extend-1.6 Thomas pan OpenFOAM Installation 7 September 9, 2015 22:53
2.0.x on Mac OSX niklas OpenFOAM Installation 74 March 28, 2012 17:46
pisoFoam compiling error with OF 1.7.1 on MAC OSX Greg Givogue OpenFOAM Programming & Development 3 March 4, 2011 18:18
OpenFOAM on MinGW crosscompiler hosted on Linux allenzhao OpenFOAM Installation 127 January 30, 2009 20:08
DxFoam reader update hjasak OpenFOAM Post-Processing 69 April 24, 2008 02:24


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