Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

issue in calculation of velocity u and v #5

Open
dododoooo opened this issue Jun 13, 2019 · 4 comments
Open

issue in calculation of velocity u and v #5

dododoooo opened this issue Jun 13, 2019 · 4 comments

Comments

@dododoooo
Copy link

Hi, in all codes from chapter 5 and 6 the velocity components u and v are calculated with c_i * f_i (x,t) (summation implied) while according to formula 3.1 the result should be divided by rho (x,t). Trying to add it the code doesn't give the correct result anymore.

@GoncaloNunoSilva
Copy link

GoncaloNunoSilva commented Jun 13, 2019

Hi, it happens that the codes included in both these chapters (as well as the worked out examples provided in the book for these chapters) adopt the incompressible LBM model. The reason is that complexity is decreased this way, as we can get rid of compressibility errors, which is possible since we are tackling steady-state problems.

Now, if you want to re-write the codes in order to account for the standard (compressible) model then only including rho(x,y) in the momentum velocity moments is not sufficient. Besides this step, you also need to re-write the equilibrium f^(eq) accordingly (and on top of that, possibly it is also necessary to re-write the BCs and/or the force term, depending on the case you are considering).

Please, take a more attentive look at the book and the codes where these elements are explained.

Good luck.

@dododoooo
Copy link
Author

dododoooo commented Jun 13, 2019 via email

@GoncaloNunoSilva
Copy link

GoncaloNunoSilva commented Jun 14, 2019

Ah OK, I understand your question now.
Yes, the omission of rho_0 from the models in the codes is equivalent to considering it implicitly set to 1.
Note that rho_0 is an arbitrary constant, so setting it to 1 avoids the code to do extra multiplications, which are unnecessary for incompressible/linear models.
Good luck

@dododoooo
Copy link
Author

Mr Silva, i wrote you a message on ResearchGate. Please give it a look when you'll have some time to spare.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants