Lees Edwards boundary conditions
This notebook shows how to implement use Lees-Edwards boundary conditions to set up a sheared fluid in lbmpy.
Depends on pystencils!198 (merged)
Fixes #7 (closed)
Merge request reports
Activity
assigned to @holzer
mentioned in merge request pystencils!198 (merged)
The tutorial overall looks nice. There are just a few things I noticed which should be corrected before it gets merged.
- Could you please check if the code is pep8 conform. There were a few lines I noticed. I think the easiest way to do so is generating the notebook as Python script and then just run the flake8 command and put the corrected lines back into the notebook. Maybe you could also try flake8-nb. I have no experience with that, tho.
- When you show the initial state of your simulation I get a
RuntimeWarning
from the quiver function of matplotlib. I think this is due to initialisation with zero. It would be good to think of a way around that or maybe not plotting the initial state at all and just write a small text that everything is initialised with zero. I rather would not want aRuntimeWarning
in a tutorial.
added 2 commits
added 5 commits
-
78ab6911...678873dd - 4 commits from branch
pycodegen:master
- c42b6883 - Merge branch 'master' of i10git.cs.fau.de:pycodegen/lbmpy into lees-edwards
-
78ab6911...678873dd - 4 commits from branch
I have made some spelling corrections and changed some formatting allowing longer lines of python code. However, I can not push to your branch. Can you please work this in?09_tutorial_lees-edwards.ipynb
Thanks for the comments!
I tried to follow the pep8 guidelines as close as possible. Although Cell 10 is much nicer to read in the version that @holzer attached in the last message.
@holzer I copied your script in my folder. After one further check, I also changed 'u' to 'w' in the markdown cell concerning the Couette flow. U_x was changed to
U_x
by me.Edited by Sebastian BindgenOk there is one last task which is important. You only added the notebook but it also hast to be added to the list of tutorials so sphinx can build it. You can find this here: https://i10git.cs.fau.de/pycodegen/lbmpy/-/blob/master/doc/sphinx/tutorials.rst If you open the file in an editor you will see all entries.