CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM (https://www.cfd-online.com/Forums/openfoam/)
-   -   Paraview sphere size (https://www.cfd-online.com/Forums/openfoam/94963-paraview-sphere-size.html)

afo December 1, 2011 05:21

Paraview sphere size
 
1 Attachment(s)
Hi Foamers,

I'm simulating a granular flow with icoUncoupledKinematicParcelFoam, I was able to give a normal distribution to the particle size, paraview sees that radius varies from particle to particle, but it visualizes particles with a constant radius. I can see that particles don't touch, because actual radius is different from the visualized one, how can i show particles with different diameters?

p.s. : In the attached picture you can see what happens.

andrea.pasquali December 1, 2011 06:54

Hi Paolo,
Are you using the PointSprite plug-in in ParaView?
If yes in the "Object Inspector - Display" select "Scale by - radius", then push the button "Edit Radius Transfer Function" and finally select "Proportionnal" instead "Use scalar range".
Now the radius of your particles will be the correct one

Andrea

afo December 1, 2011 09:28

Actually I'm not using that plug-in. How can I use it?

AMahrla December 2, 2011 06:53

foamToVTK and paraview
 
Hi!

If you use foamToVTK and paraview, you can scale the sphere-glyphs to particle radius.

Please refer to http://openfoamwiki.net/index.php/Ma...gian_particles. for creating the sphere-glyphs.

After having created the glyphs (type: sphere, scalar: radius), choose scaling by scalar, set scale factor to 1.

A tutorial collection for particle based methods can be found here.

Best,

Astrid

afo December 2, 2011 08:04

many thanks :)

afo December 5, 2011 02:46

How to use foamToVTK
 
Hi Astrid, I've run foamToVTK and it generated a number of files, how do I open them in paraView? sorry for the boring question, but I'm new to this. Thanks

AMahrla December 5, 2011 03:16

Please follow the instructions in
http://www.openfoamwiki.net/index.ph...idParticleFoam
and
http://openfoamwiki.net/index.php/Ma...gian_particles

Best,

Astrid

afo December 5, 2011 08:16

thanks astrid

afo December 16, 2011 02:53

Hi Andrea,

I tried to use that plug-in, but if I zoom in, spheres don't touch. Any suggestion?

andrea.pasquali December 16, 2011 03:16

It depends on the n. pixels used to reproduce your sphere.
You have to increase the "max pixel size". I think 512 is enough.

Andrea

afo December 16, 2011 04:45

Dear Andrea,

I've just resolved the problem. I don't need to use pointSprite, glyph filter is enough, here are the settings:

In Glyph properties:

Scalars d // which is the particle diameter
Glyph type Sphere
Radius 0.5 // since Scalars is a diameter, if it was a radius, Radius must be 1 ( obviously! )
Scale Mode Scalar
Set Scale Factor 1

Thanks anyway for your help and your time

Paolo Tria

andrea.pasquali December 16, 2011 07:03

Ciao Paolo,
I think, if you can, that it's better to use the point sprite plugin than the glyph filter.
The glyph filter has to be re-generated each timestep and if you have many particles and many times this could be very very onerous!
The point sprite plugin is just a different view mode (like point, surface ...) to see you data and it is very fast!
Anyway for not big model glyph filter could be enough

Andrea


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