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

OpenFOAM] Can I plot the lagrangian particle velocity to field velocity

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

Like Tree2Likes
  • 1 Post By massive_turbulence
  • 1 Post By massive_turbulence

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 11, 2019, 21:53
Default OpenFOAM] Can I plot the lagrangian particle velocity to field velocity
  #1
New Member
 
Seokwon Whang
Join Date: May 2012
Posts: 25
Rep Power: 9
hswzzz is on a distinguished road
I tried to post the Lagrangian data. Especially, I want to post the particle velocity on certain line.* (I use reactingParcelFoam, and there are*no particles which are exactly on the line.)


Therefore, I think that the Lagrangian particle data in the time folder (0/reactingCloud1/ U, T, position,*etc.) should be converted into the field data. (Is it right?)


How can I*convert the Lagrangian data to*Eulerian data in OpenFOAM?
hswzzz is offline   Reply With Quote

Old   February 12, 2019, 07:44
Default
  #2
Senior Member
 
Andrew Somorjai
Join Date: May 2013
Posts: 171
Rep Power: 8
massive_turbulence is on a distinguished road
Quote:
Originally Posted by hswzzz View Post
I tried to post the Lagrangian data. Especially, I want to post the particle velocity on certain line.* (I use reactingParcelFoam, and there are*no particles which are exactly on the line.)


Therefore, I think that the Lagrangian particle data in the time folder (0/reactingCloud1/ U, T, position,*etc.) should be converted into the field data. (Is it right?)


How can I*convert the Lagrangian data to*Eulerian data in OpenFOAM?
From what I know theoretically, in order for you to convert particle motion into a field (volume) you'd have to keep your momentum equation conserved which is probably much too difficult in my opinion.

The best solution I've see so far for plotting your data was this thread

Sampling lagrangian data

"1. start paraFoam
2. load the lagrangian data in addition to the "regular" data
3. "Split off" the lagrangian data using the "Extract Block"-filter
4. Open a new view on the result and make that view a "Spreadsheet view". In that view you will see the raw lagrangian data
5. File->Export that view to a CSV-file
"
hswzzz likes this.
massive_turbulence is offline   Reply With Quote

Old   February 13, 2019, 21:36
Default
  #3
New Member
 
Seokwon Whang
Join Date: May 2012
Posts: 25
Rep Power: 9
hswzzz is on a distinguished road
Thank you for answering my question.

If I follow your answer, I get the “point data” for each lagranian particle, not the “field data”.
What I want to do is to convert this “point data” to “field data”.

Thank you again for your reply.
hswzzz is offline   Reply With Quote

Old   February 13, 2019, 22:30
Default
  #4
Senior Member
 
Andrew Somorjai
Join Date: May 2013
Posts: 171
Rep Power: 8
massive_turbulence is on a distinguished road
Quote:
Originally Posted by hswzzz View Post
Thank you for answering my question.

If I follow your answer, I get the “point data” for each lagranian particle, not the “field data”.
What I want to do is to convert this “point data” to “field data”.

Thank you again for your reply.
Fields are just generalizations of velocity, pressure, etc. They are more like cells or volumes. Lagrangian motion is specifically a particle with the attributes of mass and velocity, the difference is that density in a volume can change and this is the part that makes conversion from one to another difficult.

Say you have two equally massed particles in a cubic cm at an instant and they have a mass of 2 grams, so then in that cell you can compute what density is and there's your Euler data, but two seconds later the particles with different vectors now occupy two cells each and now each cell has half the density.

Writing the program to do this is possible, just use hashing like octrees or something, it's just complicated and needs tons of ram.

Maybe someone else could explain a better solution, regards.
hswzzz likes this.
massive_turbulence is offline   Reply With Quote

Old   September 8, 2019, 22:07
Default
  #5
New Member
 
liguangze
Join Date: Apr 2019
Posts: 4
Rep Power: 2
xgyn is on a distinguished road
Quote:
Originally Posted by hswzzz View Post
I tried to post the Lagrangian data. Especially, I want to post the particle velocity on certain line.* (I use reactingParcelFoam, and there are*no particles which are exactly on the line.)


Therefore, I think that the Lagrangian particle data in the time folder (0/reactingCloud1/ U, T, position,*etc.) should be converted into the field data. (Is it right?)


How can I*convert the Lagrangian data to*Eulerian data in OpenFOAM?
Hi, I have met the same question with you. Have you fixed the problem? In addition, do you know which 'Class' determine the output file of particle's velocities (0/reactingCloud1/ U) ?
xgyn is offline   Reply With Quote

Old   September 11, 2019, 16:15
Default
  #6
Member
 
Join Date: Dec 2018
Location: Darmstadt, Germany
Posts: 49
Rep Power: 2
raumpolizei is on a distinguished road
I have some doubts if this is really what you want. Usually, you will have a limited amount of parcels (or real particles) in each computational cell. The number will probably not be large enough to create meaningful statistics in one cell. If you want a representative velocity for your particle phase in a cell, I think you have to gather the particles crossing that cell over time and calculate a mean or rms velocity by using the velocity moments of the resulting distribution. This a similar to calculating the SMD of a distribution, only that you are working with velocities. Hope this helps. Cheers RP
raumpolizei is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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
[OpenFOAM] Plot over line average magnitude of particle velocity in paraview maysmech ParaView 11 June 28, 2017 09:25
[swak4Foam] Validation of swak4Foam for lagrangian particle tracking nero235 OpenFOAM Community Contributions 13 March 28, 2017 05:45
Unsteady field advected by steady velocity field t.oliveira OpenFOAM Running, Solving & CFD 2 December 28, 2015 13:42
injection problem Mark New FLUENT 0 August 4, 2013 01:30
Check particle impaction with User Fortran Julian K. CFX 3 January 12, 2012 09:46


All times are GMT -4. The time now is 04:17.