NoDynamics / BounceBack in AdvectionDiffusion Lattice

Hi, I’m working with an AdvectionDiffusion lattice, and currently just trying to implement a system in which there is an inlet heat source on the left, and outlet heat sink on the right, and an area in the middle with “dead cells” so that there is no diffusion through these dead cells. I then want to determine what volume fraction of particles with diffusive ability is necessary to place within the dead area to connect the inlet and outlet, or to achieve percolation. I was hoping to implement these dead cells with NoDynamics, but this doesn’t seem to be working in either OpenLB or xFlows for the AdvectionDiffusion lattice. I’ve also tried BounceBack nodes, but the same problem occurs with them as well. Does anybody know if there is an implementation of NoDynamics that I’m missing, or have a suggestion for an alternative implementation? Thanks.

Arpon

Hi,

I would say that you probably need to define more rigorously, mathematically or physically, what a “dead cell” is supposed to be. In LB fluid models, bounce-back nodes are known to produce a no-slip boundary condition, but I am not aware of any publication in which bounce-back nodes are reported to produce physically meaningful boundaries in an advection-diffusion LB model.

My recommendation is that you decide what type of boundary condition you want to implement on the interface between the advection-diffusion region and the dead cells (fixed temperature or zero-gradient), and that you implement it using the usual boundary condition objects in xFlows.

Thanks for the clarification, however I still have a couple questions, mainly with xFlows. I had been using OpenLB, but decided to see if xFlows had the NoDynamics functionality for the Advection-Diffusion lattice. Since I’ve already coded most of the program within xFlows I don’t really see a reason to go back to OpenLB from here, however I’m a bit confused on a few things:

  1. It seems as if when I’m changing the density of a node, with defineDensity, no visible change is apparent in the GIF or VTK output, however when I use defineDensity along with iniCellAtEquilibrium following this, then I do see the change. Is this supposed to happen, because in OpenLB only a defineRho was necessary?

  2. When I’m adding the boundaries within the lattice, I know that in the user guide it states: “if the boundary is not located on the outer bounds of the lattice, you must use an additional Box3D argument to say where the boundaries are located,” but I’m not quite sure what this Box3D parameter should contain, as well as the fact that the AdvectionDiffusion lattice doesn’t implement the setTemperatureConditionOnBlockBoundaries function with more than just the lattice parameter, as it uses in thte guide for velocity and pressure. I just wanted to know because simply adding a temperature boundary at each node doesn’t seem to be working, and I thought it may be because I was using the function addTemperatureBoundary0P?

  1. Your observation is right: the behavior of this function has been redefined in xFlows. In xFlows, the function defineDensity only affects the value imposed by Dirichlet boundary conditions. On all other lattice nodes, it has no effect. To actually modify the values of the populations, you need to use another function such as iniCellAtEquilibrium. We did this to separate conceptually different concepts (boundary conditions vs. initial conditions).

  2. xFlows offers a new convenience function setVelocityConditionOnBlockBoundaries with which you can easily define boundary conditions, without having to specify the boundary orientations manually. This functionality is hoewever not yet implemented for the advection-diffusion model (aka temperature). There’s no other choice than using the raw functions like addTemperatureBoundary0P. These ought to work, though; I’d guess the problem is somewhere else. Are you sure the orientation is right? The acronym 0P means you are working with the right wall, without corner nodes.

Oh I see, that makes sense. As far as the boundaries go, I was only questioning the use of them because these boundaries aren’t really for a convex shape containing the dead cells. The dead cells are dispersed completely randomly, and so what I’m doing now is adding a separate boundary at each cell. I was confused about which acronym to use since these aren’t really outer walls, and also questioning whether to use boundaries or corners in this case (in which case I also wouldn’t know what acronym to use). Thanks for all your help.

In a situation like the one you describe (randomly distributed cells), I would say that a boundary condition like Bounce-Back would be ideal, because it is independent of the wall orientation. I just don’t know if a model similar to Bounce-Back exists for advection-diffusion LB models. Does anybody know more about this?

Hi again. We’re still working on this problem (using Bounce-Back in Advection-Diffusion). The model we’re testing it in involves what was described in my opening post, in trying to achieve percolation by having conductive material (normal lattice dynamics) surrounded by insulating material (where we’d like Bounce Back). We’ve been trying to use constant temperature boundaries at these insulating nodes, but it hasn’t been successful. We’d like to look into implementing Bounce-Back for the AD-lattice ourselves, and I was just wondering where in the Palabos code we’d find the implementation for Bounce-Back (to base our code off of), and if you have suggestions on how to go implementing our own Bounce Back system.

Hi,

Bounce-Back is implemented through the class “BounceBack”, which is declared in src/core/dynamics.h and implemented in src/core/dynamics.hh . The easiest way to implement your own version of bounce-back is to copy this code (both the declaration and the implementation) into an end-user program, change the name from “BounceBack” to something else, and to modify the function “collide”.