Create-destroy Lagrangian parcels
I am working on a combined VOF and Eulerian-Lagrangian solver. It works fine, but I need to destroy Lagrangian parcels once they enter in a given fluid phase.
Is there anyone who can indicate me how I can implement this system?
No ideas about how to make it?
not quite sure where you are stuck but I do my best to help you.
Also: I'm not familiar with the solver you are using, I use DSMC, also a Lagrangian solver, so things might be the similar.
You should check the move() method of the cloud class found in the lagrangian basic library (Cloud.C).
You will see that it is calling a move routine of the particle class and this routine is either returning true or false. If true, the particle is kept after the movement, if false, the particle is going to be deleted after movement (which would be exactly what you want right?).
What you need to do is to identify the move routine of the parcel class that your solver is using. As the Lagrangian Basic particle class has no move routine it must be found somewhere in the particle class of your specific solver.
In the DsmcCase it is found in the DsmcParcel Class (DsmcParcel::move()). What it does: It calls the trackToFace routine (which is again from the lagrangian basic particle class) over and over until the movement of the particle is completed. trackToFace tracks the particles movement until it hits a face or until the movement is completed. When it hits a face, it calls a specific routine and returns the value of how much of its trajectory is already done....
So with this routine it would be easy to implement that the particle is deleted after movement. Just check in the trackToFace routine whether its crossing a boundary and is in a specific fluid type, if yes: set the keepParticle value to false and it is going to be deleted after the movement automatically...
Hope that helped...
Thank you for the answer. In Cloud.C there is a void move(...) method.
At a certain point it calls a bool ParticleType method that moves a single particle and returns true if it has to be kept, fals otherwise:
Now I am wondering how to do this without touching the original class files. Since I use the basicKinematicCollidingCloud template class, it seems that I have to define subclasses for every single class, that is CollidingCloud, KinematicCloud, Cloud, CollidingParcel, KinematicParcel.:eek:
|All times are GMT -4. The time now is 20:46.|