Page 1 of 2

particle simulation

Posted: Tue Jul 31, 2012 9:38 am
by Fabio89
Hello everybody,

I'm designing an inertial impactor for particles sampling and I need to test particles path into the chambers of instrument and above all where biggest ones settle.
To do it I'm using Code-Saturne GUI; neverthless a lot of attempts, I'm not able to solve my problem yet.
Looking carfully "listing" file in the specific folder, I understood (even though my french knowledge is not very well) that Code-Saturne couldn't simulate particles tracking with laminar flow conditions (that are mine).

So I have only three simple questions:

1. Is possible to simulate particles tracking filling in "Boundary Statistic" and "Volume Statistic" in the GUI, respectively showing off where particles settle and their path in the flow?

2. What format do I need to achieve my aim and what software do I have to use?

3. To carry out Plot 2D graph in Salome, do I need to process in Code-Saturne with "format = text (not binary)", or something different?

please help me if anyone can, because I think I'm near the solution, but I'm sure I miss a step.

Thank you in advance

Fabio
:)

Re: particle simulation

Posted: Tue Jul 31, 2012 4:12 pm
by guingo
Hello Fabio,

Concerning your attempt to use the particle-tracking module in laminar flow, it should be possible by deactivating "Particle Turbulent dispersion" which is set by default in the GUI in

Particle and Droplets tracking > Global Settings > Advanced Options

(if possible, please post your listing to confirm this point)

Best regards,
Mathieu

Re: particle simulation

Posted: Wed Aug 01, 2012 5:37 pm
by Fabio89
Hi Mathieu,

first of all I'm grateful about your useful help. I looked everywhere in the GUI but I didn't think into Advanced Options. I thought I didn't need to change it whereas my work is not a very complex one.
However, after deactived "Particle Turbulent dispersion", Code-Saturne finally RUN, but after few minuts the message "Error in Calculation Stage" is shown on the Terminal.
In "listing" I read:

ATTENTION : ARRET LORS DE L'ENTREE DES COND. LIM.
@ =========
@ MODULE LAGRANGIEN :
@ LE SOUS-PROGRAMME UTILISATEUR uslapr DOIT ETRE COMPLETE
@
@ Le calcul ne sera pas execute.
@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@

Call stack:
1: 0x7fdcf8b5aeed <uslapr_+0x69> (libsaturne.so.0)
2: 0x7fdcf8b29fbd <lagent_+0x6f7d> (libsaturne.so.0)
3: 0x7fdcf8b52f5f <lagune_+0x7bf> (libsaturne.so.0)
4: 0x7fdcf8843193 <caltri_+0x59a3> (libsaturne.so.0)
5: 0x7fdcf881d9e3 <cs_run+0x843> (libsaturne.so.0)
6: 0x7fdcf881dcc5 <main+0x1f5> (libsaturne.so.0)
7: 0x7fdcf4fbcc4d <__libc_start_main+0xfd> (libc.so.6)
8: 0x40a359 <> (cs_solver)
End of stack

I controlled soubroutine "uslapr" but I don't know what I have to do to complete it, using GUI too.
If you want I could post all steps I did in the GUI concerning "Particles and Droplets Tracking".
At last but not least, I'm using Caelinux 2011 on Ubuntu 10.04 LTS with Code-Saturne 2.0.2

Thank you one more time

Hear you soon

Fabio
:)

Re: particle simulation

Posted: Sat Aug 04, 2012 9:32 pm
by Yvan Fournier
Hello,

Im am not sure I understand your issue: did you copy the uslapr.f90 file from your case's SRC/REFERENCE/lagr directory to its SRC directory and adapt the example to your case ?

The example is "minimalist", to say the least, bit it seems the subroutine is called for each particle, and among the input arguments, you have the particle's position and velocity, so you can define profiles using this (only flat profiles are given in the example).

Regards,

Yvan

Re: particle simulation

Posted: Mon Aug 06, 2012 8:42 am
by guingo
Hi Fabio,

As Yvan said, the purpose of uslapr is to allow the user to define more complex inlet profiles than flat profiles for particle velocity, diameter, and/or temperature.

The error you get seems to indicate that you copied directly the source file from the src dir of Code_Saturne, since the version of uslapr in the SRC/REFERENCE/lagr directory of your case should be stripped from the test bringing about this particular error

So, I have exactly the same question than Yvan :-)

Best regards,
Mathieu

Re: particle simulation

Posted: Tue Aug 21, 2012 11:54 am
by Fabio89
Hi Yvan and Mathieu,

I'm sorry for these weeks but I didn't have internet connection. However, looking better at user's guide manual I realized that in the GUI (Boundary conditions/Particles boundary conditions) I need to set a statistical weight to particles in order to calculate statistics. So, I sat at Inlet/Number of Classes = 3, to simulate 3 different particles size and used:

Statistcal weight set by values = 1.0

Fluid Velocity

Diameter set by values:

mean value ------ standard deviation

1e-06 --------------------- 1e-07 ----- class 1
2.5e-06 ------------------- 1e-06 ----- class 2
1e-05 --------------------- 1e-06 ----- class 3

Before, I try setting with "User Defined Statistical weight and Defined Diameter" but I had my error in soubroutine uslapr; now Code-Saturne RUNS and I have my output but I need to understand how showing it off.

Hence, I have two questions:

-Could you give me more information about:
Boundary outputs : Yplus, Efforts, impacts, lagrangian boundary zones, velocity (boundary), velocity, mass flux
Fluid volume outputs : Courant Nb, Fourier Nb, maen mass (grp_1, grp_2, grp_3), mean mass fraction, mean residence time, statistical weight, mean velocity (grp_1, grp_2, grp_3)

What are their units and how do I read/understand them?

-How can I show files "trajectorie." and "deplacement.", in folder "LAGR."? What format do I need in order to do it?
(my aim is to show particles path into instrument chambers)

Thank you VERY MUCH for you help and your attention in advance.

Regards,

Fabio

Re: particle simulation

Posted: Fri Aug 31, 2012 10:21 pm
by guingo
Hi Fabio,

To read the files "deplacement.***" and trajectoire.CASE (which, as you may have guessed, are french words for displacement and trajectory), I use the EnSight software. I suppose other software such as Paraview can read them too, but I never tried. The files "deplacement.**" make it possible to get an animated view of the particles you selected, whereas "trajectoire" is a set of motionless filaments representing particles trajectories.

Concerning the various outputs you cite, a number of them are not related to the particle-tracking module (Yplus, effort, Courant Nb, for instance).

I do not have the code at hand, but Lagrangian outputs are, for the boundary : "impacts", which record the number of particle- wall boundary interaction, "mass flux" is the particulate boundary mass flux (in kg/m^2/s), velocity is the particle impact velocity. The names of the volume outputs are normally quite straightforward (see also my other post concerning the not-that-easy variable "statistical weight".)


Best regards,

Mathieu

Re: particle simulation

Posted: Mon Sep 03, 2012 11:18 am
by Fabio89
I say goodbye to you one more time

At first thanks for your explanation about "Boundary and Fluid Volume outputs"

Sacondly, if I simulate 3 different particles size, does "impact" output show off the number of particle- wall boundary interaction for all classes together?
And about "Volume outputs" and "statistical weight", on the other post you wrote: "this notion was introduced to enable the user to run a calculation with realistic particle mass flow rate"; if I have only a volumic flow rate to simulate, in which I introduce 3 different particles size with X particles for class, can I ignore this output?

At last but the most important question now, (I'm working with Caelinux-2011 on Ubuntu 10.04 LTS) I don't have any programme in Application -> Caelinux, called Ensight; I show off my outputs now using Salome -> Post-pro.
Where can I find the Ensight software?

Best Regards,

Fabio

Re: particle simulation

Posted: Mon Sep 03, 2012 3:38 pm
by Yvan Fournier
Hello,

EnSight is a high-end commercial visualization tool

IN CAELinux, you should be able to use ParaView to read EnSight format files.

Best regards,

Yvan

Re: particle simulation

Posted: Tue Sep 04, 2012 10:09 am
by Fabio89
Hi Yvan,

Good!
Using ParaView, can I get the animated view of the particles which I selected (with files "deplacement.") and show off motionless filaments representing particles trajectories (with files "trajectorie.")?
If possible, How can I do this two things? Is there any similar tutorial to see?

Thanks in advance

Best Regards,

Fabio