[FLASH-USERS] Simple Question on Particles

Seyit Hocuk seyit at astro.rug.nl
Wed May 6 03:13:45 EDT 2009


Hi John,

With this, you don't get the problem that passive and active particles 
use the same variables, like 'Tag', 'xpos', xvel', 'yvel' etc.?
My setup doesn't complain, but I think both types use the same 
variables, such that I can only see the active particles.

So with particlemap from variable can solve this?

Kind Regards,
Seyit


John ZuHone wrote:
> Seyit,
>
> Your idea for a Config file to do this is on the right track. Below is 
> one I use to accomplish the same purpose.
>
> You'll have to figure out how to make the initialization routines for 
> both types of particles play nice with each other, but otherwise the 
> code should be set up for this already.
>
> Best,
>
> John ZuHone
>
> # Configuration file for ClusterSloshing problem.
>
> REQUIRES Driver/DriverMain
> REQUIRES Grid
> REQUIRES Grid/GridParticles
> REQUIRES physics/Hydro
> REQUIRES physics/Eos/EosMain/Gamma
> REQUIRES physics/materialProperties/Viscosity/ViscosityMain
> #REQUIRES physics/sourceTerms/Diffuse/DiffuseMain
>
> PARTICLETYPE active INITMETHOD custom MAPMETHOD weighted
> REQUIRES Particles/ParticlesForces/longRange/gravity/ParticleMesh
> REQUIRES Particles/ParticlesMain/active/Leapfrog
> REQUESTS Particles/ParticlesMapping/meshWeighting/CIC
> REQUIRES Particles/ParticlesMapping/meshWeighting/MapToMesh
>
> REQUIRES IO
> REQUIRES IO/IOParticles
> REQUIRES physics/Gravity/GravityMain/Poisson/Multigrid
> REQUIRES flashUtilities/interpolation/oneDim
>
> #Give the user the opportunity to also include passive tracer particles.
> #(Add withTracerParticles=True to the setup line)
> #----------------------------------------------------------------
> USESETUPVARS withTracerParticles
>
> IF withTracerParticles == True
>
> PARTICLETYPE passive INITMETHOD with_density MAPMETHOD quadratic
> #NOTE: This expands to PASSIVE_PART_PROP in Flash.h, and places the 
> pre-processor
> #definitions "LATTICE" and "QUADRATIC" (from Particles.h) in our 
> particles
> #data structure.
>
> REQUIRES Particles/ParticlesMain/passive
> REQUESTS Particles/ParticlesInitialization/WithDensity
> REQUESTS Particles/ParticlesMapping/Quadratic
>
> PARTICLEPROP pdens REAL
> PARTICLEPROP ptemp REAL
> PARTICLEPROP pmetl REAL
> PARTICLEPROP type REAL
>
> PARTICLEMAP TO ptemp FROM VARIABLE temp
> PARTICLEMAP TO pdens FROM VARIABLE dens
> PARTICLEMAP TO pmetl FROM MASS_SCALAR metl
>
> PARAMETER particle_attribute_1 STRING "pdens"
> PARAMETER particle_attribute_2 STRING "ptemp"
> PARAMETER particle_attribute_3 STRING "pmetl"
>
> END IF
>
> On May 4, 2009, at 6:30 AM, Seyit Hocuk wrote:
>
>> Hi Community,
>>
>> Is it possible with Flash3.1.1 to have both active particles and 
>> passive (grid tracer) particles?
>>
>> Kind Regards,
>> Seyit
>>
>>
>> Example Config:
>>
>> REQUIRES physics/Gravity/GravityMain/Poisson
>> REQUESTS physics/Gravity/GravityMain/Poisson/Multigrid
>>
>> PARTICLETYPE active INITMETHOD custom MAPMETHOD weighted
>> REQUIRES Particles/ParticlesMain/active/Leapfrog
>> REQUESTS Particles/ParticlesMapping/meshWeighting/CIC
>> REQUESTS Particles/ParticlesMapping/meshWeighting/MapToMesh
>> REQUESTS IO
>> REQUESTS IO/IOParticles
>>
>> USESETUPVARS withParticles
>> IF withParticles == True
>> PARTICLETYPE passive INITMETHOD With_Density MAPMETHOD quadratic
>> REQUIRES Particles/ParticlesMain/passive
>> REQUESTS Particles/ParticlesInitialization/WithDensity
>> REQUESTS Particles/ParticlesMapping/Quadratic
>> END IF
>




More information about the flash-users mailing list