🎉Community Raffle - Win $25

An exclusive raffle opportunity for active members like you! Complete your profile, answer questions and get your first accepted badge to enter the raffle.
Join and Win

How to get information of particles from the grid bin in edempy?

User: "Fatemeh Hosseini_22198"
Altair Community Member
Updated by Fatemeh Hosseini_22198

I use edempy for post processing. Until now, I used cylinder bin(Geometry bin) and get the position and Id of particle inside the bin.by this code:

Bin = CylinderBin([0,0.1, 0], [0, 0.2, 0], 0.01)
pIds = my_simulation_deck.timestep[t].particle[0].getIds()
pPos = my_simulation_deck.timestep[t].particle[0].getPositions()
ids_inside = Bin.getBinnedObjects(pIds,pPos)

But due to the huge number of particles, the process is too time-consuming. (I calculate the distance between all the particles) I think if I can define grid bins and do the calculation inside each grid  It will be more logical in CPU time.( I mean it is more logical to calculate the distance between particles and only their neighbors) 
I want to ask you, just like an above code, is there any way to get information in each grid?

Regards,
Fatemeh

Find more posts tagged with