CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > Siemens > STAR-CCM+

extracting data from simh history file?

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By me3840

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 2, 2017, 15:12
Default extracting data from simh history file?
  #1
New Member
 
Jasbir Singh Dhanoa
Join Date: Nov 2016
Posts: 14
Rep Power: 9
jasbirdhanoa is on a distinguished road
Hi Guys

I have ran a simulation with history saving at every time-step, now I have all the data, but now I want to extract the data for processing it in Matlab (for example, temperature ). I can manually go to every time-step and extract the data, but how can I extract the data (i.e. xyz coordinate and temp.) at all time-steps at once say in a .csv file?
jasbirdhanoa is offline   Reply With Quote

Old   June 2, 2017, 18:47
Default
  #2
Senior Member
 
Join Date: Nov 2010
Location: USA
Posts: 1,232
Rep Power: 24
me3840 is on a distinguished road
Unsure if there's another way, but you can certainly write a java macro to produce this.
me3840 is offline   Reply With Quote

Old   June 3, 2017, 03:08
Default
  #3
New Member
 
Jasbir Singh Dhanoa
Join Date: Nov 2016
Posts: 14
Rep Power: 9
jasbirdhanoa is on a distinguished road
I am new to starccm+,can you tell how to write the javascript?
jasbirdhanoa is offline   Reply With Quote

Old   June 3, 2017, 13:20
Default
  #4
Senior Member
 
Join Date: Nov 2010
Location: USA
Posts: 1,232
Rep Power: 24
me3840 is on a distinguished road
Java and Javascript are not the same thing, you would be writing the former.

You can easily generate a Java macro using STAR-CCM+'s built-in record function. It will write most of the code for you. I'd imagine your procedure would look something like:

1. Go to the first solution time
2. Make an internal table of the data you want
3. Extract said table
4. Go to the next solution
5. Repeat 2-4 for all solution times

STAR will not write step 5 for you, nor will it write the final table out as a file which you could import to MATLAB, but using loops and writing CSV files is pretty easy to learn if you google around.

Check out the Steve portal, there are articles on how to use the Java API with an IDE like netbeans to make the programming much, much simpler. They also offer a Java macro class if you can go to that.
lcarasik likes this.
me3840 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
how to calculate mass flow rate on patches and summation of that during the run? immortality OpenFOAM Post-Processing 104 February 16, 2021 08:46
polynomial BC srv537 OpenFOAM Pre-Processing 4 December 3, 2016 09:07
friction forces icoFoam ofslcm OpenFOAM 3 April 7, 2012 10:57
OpenFOAM on MinGW crosscompiler hosted on Linux allenzhao OpenFOAM Installation 127 January 30, 2009 19:08
ParaView Compilation jakaranda OpenFOAM Installation 3 October 27, 2008 11:46


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