# Chapman Enskog for D2Q4 [stuck]

https://www.dropbox.com/s/11pjkvy1wj9ekam/question.pdf
(please save the file then view it because drop bax viewer will not view it properly.)
(I did not write the question directly in the forum because it contains complex equation.)

I am following dhumieres_1992 “Generalized Lattice Boltzmann Equation”
and Rui Du_2006 “Multi-relaxation-time lattice Boltzmann model for incompressible flow”
regards

I don’t think it is possible to have an error-free advection-diffusion LBE (if there is no advection though you can set the velocity, and thus the first order moment, to be zero). For advection diffusion you have some anisotropic numerical diffusion, and although a good choice of moments and relaxation times can increase the order of accuracy, the off diagonal components of the numerical diffusion tensor prevail. There’s some nice work by people like Ginzburg, dhumieres and Kuzmin about just this (for D2Q5 TRT models)

thank you very much thats help.
So in general ant terms that can not be mached with the macroscopic equation considered as error.
I looked at Irena paper it is intersting.

An other question:

In D2Q9 when I do the gram schmidt orthogonalization to the folowing basis which is based on SO(2) group
[ 1, u, v, (u^2+v^2), uv, (u^2-v^2), u (u^2+v^2), v* (u^2+v^2), (u^2+v^2)^2]

I got the same matrix as in the orginal paper of (dHumeries 1992)

how can I get the nice simple integer matrix which is usually used in the literature?
I tried to multiply each row by its norm. I got a similar matrrix for the conserved moment, but not for the non conserved moments. i.e.

``````
rho [1,1,1,1,1,1,1,1,1],
u     [0,1,0,-1,0,1,-1,-1,1],
v     [0,0,1,0,-1,1,1,-1,-1],
e     [-4/3,-1/3,-1/3,-1/3,-1/3,2/3,2/3,2/3,2/3],
pxy [0,0,0,0,0,1,-1,1,-1],
pxx [0,1,-1,1,-1,0,0,0,0],
qx   [0,-2/3,0,2/3,0,1/3,-1/3,-1/3,1/3],
qy   [0,0,-2/3,0,2/3,1/3,1/3,-1/3,-1/3],
eps [8/9,-4/9,-4/9,-4/9,-4/9,2/9,2/9,2/9,2/9]

``````

I think it is ok to multiply the non conserved moments by a constant to get a nice matrix. i.e.
e=e3
qx=qx
3
qy=qy* 3
eps=eps* 9/2

correct me if i made a mistake.

regards

If you don’t normalise the vectors in affection the Gram-Schmidt procedure you should get nice integer values (see Lallemand and Luo, 2000, for example)

thank you for replaying
actually I doublicate that paper all of it except this part( the matrix part) and the dispersion part.
I could not figureout how to do it.
when I do not normalise the results of gram schmidt I got the matrix mentioned in my previous replay.
but when I normalise it I got the matrix in (dHumeries 1992)

could you tell me which algorithm of Gram shmidt is used always.

I am using this one

``````
U[1]:X[1],
Q[1]:U[1]/ sqrt(U[1].U[1]),
U[2]:X[2]- proj(X[2],Q[1]),
Q[2]:U[2]/ sqrt(U[2].U[2]),
U[3]:X[3]- proj(X[3],Q[1])- proj(X[3],Q[2]),
Q[3]:U[3]/ sqrt(U[3].U[3]),
U[4]:X[4]- proj(X[4],Q[1])- proj(X[4],Q[2])- proj(X[4],Q[3]),
Q[4]:U[4]/ sqrt(U[4].U[4]),
U[5]:X[5]- proj(X[5],Q[1])- proj(X[5],Q[2])- proj(X[5],Q[3])- proj(X[5],Q[4]),
Q[5]:U[5]/ sqrt(U[5].U[5]),
U[6]:X[6]- proj(X[6],Q[1])- proj(X[6],Q[2])- proj(X[6],Q[3])- proj(X[6],Q[4])- proj(X[6],Q[5]),
Q[6]:U[6]/ sqrt(U[6].U[6]),
U[7]:X[7]- proj(X[7],Q[1])- proj(X[7],Q[2])- proj(X[7],Q[3])- proj(X[7],Q[4])- proj(X[7],Q[5])- proj(X[7],Q[6]),
Q[7]:U[7]/ sqrt(U[7].U[7]),
U[8]:X[8]- proj(X[8],Q[1])- proj(X[8],Q[2])- proj(X[8],Q[3])- proj(X[8],Q[4])- proj(X[8],Q[5])- proj(X[8],Q[6])- proj(X[8],Q[7]),
Q[8]:U[8]/ sqrt(U[8].U[8]),
U[9]:X[9]- proj(X[9],Q[1])- proj(X[9],Q[2])- proj(X[9],Q[3])- proj(X[9],Q[4])- proj(X[9],Q[5])- proj(X[9],Q[6])- proj(X[9],Q[7])- proj(X[9],Q[8]),
Q[9]:U[9]/ sqrt(U[9].U[9]),

``````

the projection is defined as

``````
proj(v,u):= (u.v)/(u.u)*u;

``````

where X is the matrix M
U is the non normalise orthogonal basis .(like in my prevoius replay)
Q is the normalized (orthonormal) basis. .(like in dHumeriies 1992)

Note: Icompare the results of the prevoius algorithm to linear algebra packages and it was the same. So, I think that algorithm is correct.

an other issue did you orthogonalize using the standard inner production. If I remember correctly, I read in one of “Dellar”,s papers some time ther othogonalize around a special inner prodect. such as
<u,v>=sum(u[i]*v[i]*w[i])

where w is weight function

regards

The basis is not unique. All that is required is that the lattice vectors are linearly independent. . Delllar’s for example (in his 2003 paper) is based on Hermite polynomials, rather than doing the Gram-Schmidt orthogonalisation… Although, they may be equivalent when you normalise…?

thank you for the nice discusstion
regards