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

[OpenFOAM] How to plot time vs distance traveled by the interface interFoam

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 16, 2008, 12:15
Default How to plot time vs distance traveled by the interface interFoam
  #1
Member
 
vof_user
Join Date: Mar 2009
Posts: 67
Rep Power: 17
asaha is on a distinguished road
Hello,

Is there a easy way to plot time vs distance travelled by the interface (say tracking the intersection of gamma=0.5 along the axis of a 3-D channel with time) by using the log/foamLog file or paraFoam.

Kindly help me with your suggestions.

Regards,

AA Saha
asaha is offline   Reply With Quote

Old   August 16, 2008, 16:05
Default This is impossible unless you
  #2
nadine
Guest
 
Posts: n/a
This is impossible unless you modify the interFoam solver. The intersection of the gamma=0.5 contour with some axis is not necessarily unique, so without additional assumptions it cannot be written as a single time dependent function.

NB
  Reply With Quote

Old   August 17, 2008, 07:52
Default Hello Nadine, Thanks for yo
  #3
Member
 
vof_user
Join Date: Mar 2009
Posts: 67
Rep Power: 17
asaha is on a distinguished road
Hello Nadine,

Thanks for your post. Can you give some hint on modifying the interFoam solver to get the desired results.

For the moment, I achieve this manually via paraFoam by creating a contour of gamma=0.5 and intergrate attribute to get the coordinate points for each time step. This seems to be very time consuming and I wish I could find a easier way to achieving the same. Kindly help me in this regard.


Thanks and regards,

AA Saha
asaha is offline   Reply With Quote

Old   August 17, 2008, 08:33
Default Basically you would have to do
  #4
nadine
Guest
 
Posts: n/a
Basically you would have to do the same in interFoam yourself what you are doing now in paraview.

I have no idea how your problem and solution look like. If the intersection of the gamma=0.5 contour with the channel axis is a unique point at all times, you can of course use paraview. To increase speed I suggest, you first get a 1D cut of gamma along the axis and then find gamma=0.5 instead of first creating the contour and then cutting along the axis.

If your solution is not so well behaved, use some (eg. linear) interpolation algorithm within interFoam to extract the cut of the gamma GeometricField with your axis, then apply a root finding algorithm (eg. bisection) and some logic to choose those gamma=0.5 roots that you want to track.

NB
  Reply With Quote

Old   August 17, 2008, 12:41
Default Hello Nadine, Thank you ver
  #5
Member
 
vof_user
Join Date: Mar 2009
Posts: 67
Rep Power: 17
asaha is on a distinguished road
Hello Nadine,

Thank you very much for your suggestions. I will give this a try and update you on the progress.


Thanks and regards,

AA Saha
asaha is offline   Reply With Quote

Old   August 21, 2008, 02:27
Default Hello Nadine, -----------
  #6
Member
 
vof_user
Join Date: Mar 2009
Posts: 67
Rep Power: 17
asaha is on a distinguished road
Hello Nadine,


---------------------------------------------------
I have no idea how your problem and solution look like. If the intersection of the gamma=0.5 contour with the channel axis is a unique point at all times, you can of course use paraview. To increase speed I suggest, you first get a 1D cut of gamma along the axis and then find gamma=0.5 instead of first creating the contour and then cutting along the axis.
--------------------------------------------------

I have followed your suggestion given as above and could obtain the results in paraFoam. Thanks again for your valuable advise.

-------------------------------------------------
If your solution is not so well behaved, use some (eg. linear) interpolation algorithm within interFoam to extract the cut of the gamma GeometricField with your axis, then apply a root finding algorithm (eg. bisection) and some logic to choose those gamma=0.5 roots that you want to track.
--------------------------------------------------

Using paraFoam I can only use the data files written after the simulation. So I would also like to attempt the above suggestion, which may require some tweaking of the interFoam solver. This will enable me to get the results directly from the log file, if I am correct.

I have not modified the interFoam solver and have only used the solver as it is. I would appreciate if you can help me out with some suggestions in this regard.

Thanks and regards,

AA Saha.
asaha is offline   Reply With Quote

Old   August 21, 2008, 05:58
Default >This will enable me to get th
  #7
nadine
Guest
 
Posts: n/a
>This will enable me to get the results directly from the log file, if I am correct.

Yes. You could write the position of the interface at each integration time step, not only at those writeInterval steps when the complete solution is written into the time directories.

>I have not modified the interFoam solver and have only used the solver as it is. I would appreciate if you can help me out with some suggestions in this regard.

You will probably have to learn several details of the OpenFOAM implementation unless somebody else comes up with a complete solution to your request. If the meaning of any of the suggested steps is unclear, please ask. But I can't do your work and tell you how to do it within interFoam.

NB
  Reply With Quote

Old   August 21, 2008, 06:48
Default Hello Nadine, Thanks for pr
  #8
Member
 
vof_user
Join Date: Mar 2009
Posts: 67
Rep Power: 17
asaha is on a distinguished road
Hello Nadine,

Thanks for providing some useful hints. Now I will devote throughly a few days on knowing much more on interFoam solver and its implementation in OpenFOAM.

I will update you on the progress.


Thanks and regards,

AA Saha
asaha is offline   Reply With Quote

Old   August 26, 2010, 10:20
Default
  #9
Senior Member
 
Nima Samkhaniani
Join Date: Sep 2009
Location: Tehran, Iran
Posts: 1,267
Blog Entries: 1
Rep Power: 25
nimasam is on a distinguished road
hi asaha
could you find any way to calculate the interface distance (for example alpha = 0.5) from an specific axis ?any way to calculate interface position by time in interfoam?
nimasam is offline   Reply With Quote

Old   January 26, 2011, 09:05
Default
  #10
Senior Member
 
Nima Samkhaniani
Join Date: Sep 2009
Location: Tehran, Iran
Posts: 1,267
Blog Entries: 1
Rep Power: 25
nimasam is on a distinguished road
do following step in paraview
1) countour
alpha isoline 0.5
2)integrate variable
then in castcade choose countor
3)plotSelectionOverTime
choose a point from integrate variable table then click apply!

you will have interface position by time!!!
nimasam 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
AMI speed performance danny123 OpenFOAM 21 October 24, 2020 05:13
Setting up Lid driven Cavity Benchmark with 1M cells for multiple cores puneet336 OpenFOAM Running, Solving & CFD 11 April 7, 2019 01:58
Floating point exception error lpz_michele OpenFOAM Running, Solving & CFD 53 October 19, 2015 03:50
Star cd es-ice solver error ernarasimman STAR-CD 2 September 12, 2014 01:01
Upgraded from Karmic Koala 9.10 to Lucid Lynx10.04.3 bookie56 OpenFOAM Installation 8 August 13, 2011 05:03


All times are GMT -4. The time now is 14:47.