Creating Subdomain

Submitted by kashif saeed on Tue, 09/05/2017 - 08:14

Hi everyone,
I have posted this question some days ago but could not get any answer. Now I am trying to explain it more.

I am using open source software LIGGGHTS, which uses DEM (discrete element method), My simulation contains a cylinder and 4 bladed impeller which rotates inside the cylinder. I have inserted 3 types of particles in the cylinder and rotate the impeller which causes mixing of particles that process is done using LIGGGHTS software.

Now for post processing, i am using ParaView. In Paraview, I can see the particles mixed each other. but I want to find out the mixing status for that purpose I want to use Subdomain based mixing index (SMI).

For SMI calculation, it requires dividing the domain into subdomains like 3D mesh and to find the total number of particles and number of particles of each type in each cell of mesh/subdomain.

Please let me know how can I create these subdomains in ParaView?
Or these sub domains be created in LIGGGHTS input script if it should be created in input file then let me know how can I create this in the input file.

thanks

paul | Tue, 09/12/2017 - 13:45

Hi,

You might do it like this.

variable zmin_A equal ...
variable zmax_A equal ...
region chamber_A block INF INF &
INF INF &
${zmin_A} ${zmax_A}
variable zmin_B equal ...
variable zmax_B equal ...
region chamber_B block INF INF &
INF INF &
${zmin_B} ${zmax_B}

Add the following after particle insertion:

variable mass_A equal mass(all,chamber_A)
variable mass_B equal mass(all,chamber_B)
fix origin all property/atom origin scalar yes no no 0. # if you feed particles, they will get f_origin 0
# uncomment the following only for the first run
#run 0
#set region chamber_A property/atom origin 1. #those originating in chamber A get origin 1
#set region chamber_B property/atom origin 2. #vice versa for B
variable Aatom atom f_origin==1.
variable Batom atom f_origin==2.
group A variable Aatom
group B variable Batom
variable AinB equal mass(A,chamber_B)
variable BinA equal mass(B,chamber_A)
variable AinA equal mass(A,chamber_A)
variable BinB equal mass(B,chamber_B)
compute c1 all reduce sum v_Aatom
compute c2 all reduce sum v_Batom
variable time equal time
# 5000 is the interval b/w prints into the log file holdup.csv
fix holdup all print 5000 "${time} ${mass_A} ${mass_B} ${AinA} ${BinA} ${AinB} ${BinB}" &
append holdup.csv &
screen no

later add some of these to thermo

thermo_style custom step atoms v_vel_rv v_mass_rv c_c1 c_c2 v_mass_A v_mass_B v_AinA v_BinA v_AinB v_BinB

Otherwise you could also just load your particle trajectories into something like MATLAB and calculate it there.

- Paul