How to make a runable to change tag of particles

Asked by Shu-xiao Tsai

Hi everyone,
    When I practice the tutorial example shearcell.py, I added two side walls. While the upper and bottom walls are moving together in Y-direction,the side ones move away in X-direction. And I make the particles near the walls to be tagged.(For example, the particle near the upper wall is tagged 1)
    When the upper walls move, the INITIAL tagged 1 particles move ONLY in y-direction. As the two sides wall move away,there are NEW area near the upper wall.
    Unfortunately,the INITIAL NOT tagged 1 particles filled into the NEW position near the upper wall. Since they are NOT TAGGED AT FIRST, they cann't be pushed by the upper wall.
   So,I wonder how can I make a runable to change the tag of particles in each timestep.
   Best regards,
   Shuxiao Tsai

Question information

Language:
English Edit question
Status:
Solved
For:
ESyS-Particle Edit question
Assignee:
No assignee Edit question
Solved by:
Dion Weatherley
Solved:
Last query:
Last reply:
Revision history for this message
Best Dion Weatherley (d-weatherley) said :
#1

Hi Shuxiao Tsai,

It is not possible to change the tag of particles during a simulation. This can only be done before sim.createParticles() or sim.readGeometry() is called.

If you are using NRotBondedWallPrms for the top and bottom wall (as in the shearcell.py tutorial) unbonded particles that touch those walls will be repelled, regardless of their tag.

NRotBondedWallPrms implements two interactions:
1) unbreakable elastic bonds with particles having the prescribed tag, and
2) elastic repulsion of all other particles that touch the wall - in the same manner as NRotElasticWallPrms.

If however, one uses NRotSoftBondedWallPrms, only particles with the prescribed tag will interact with the wall.

One more thing that comes to mind reading your description of your simulation: One should probably remove the periodic boundary conditions to avoid strange effects such as particles on both sides of the model interacting with both side walls.

Cheers,

Dion

Revision history for this message
Shu-xiao Tsai (tsaitsai) said :
#2

The answer is clear.I will notice the boundary conditions.
Thank U very much for such a complete answer!

Cheers,

Tsai