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

Tutorial 4 - Lattice-Boltzmann #3893

Merged
merged 19 commits into from
Oct 8, 2020

Conversation

jngrad
Copy link
Member

@jngrad jngrad commented Sep 11, 2020

Description of changes:

  • Update part 1 (fixes Tutorial 04: lb part1 #3828)
  • Write solutions for parts 2 and 3 and check them in CI
  • Calculate the diffusion coefficient of a polymer with the MSD and Green-Kubo methods
  • Replace LB hydrodynamics by LD hydrodynamics for polymer diffusion

Store the lag time and MSD series separately. Remove the superfluous
LOOPS variable. Indicate which section in Frenkel 2002 discusses the
diffusion formula.
Add solutions and literature references. Test the solutions in CI.
@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

Review Jupyter notebook visual diffs & provide feedback on notebooks.


Powered by ReviewNB

Rewrite the solution to run faster with shorter polymers. Calculate
several polymer statistics (R_F, R_g, R_h) and explain they depend
on the number of monomers.
Integrate the autocorrelation function to remove the variance bias
in time series.
@jngrad
Copy link
Member Author

jngrad commented Oct 4, 2020

@KaiSzuttor Part 3 is now ready for review. The idea would be to hide the solution of the plots for Rf, Rg, Rh. Once the participants have a working solution for Rf, they can copy-paste it for Rg and Rh. Regarding the diffusion coefficient, they should re-use the solution they wrote in Part 2 and write a fitting function based on the Kirkwood-Zimm model.

I'm still working on the electrophoresis part, but if I can't get it to work out in time, plan B is to only do the monomer+polymer diffusion in the advanced group, and the monomer + Poiseuille flow in the beginner group.

I tried Part 3 with Langevin Dynamics instead of LB, and I got similar results at a fraction of the computational time. Maybe in the future we could create a polymer tutorial with Langevin.

@jngrad jngrad changed the title WIP: Tutorial 4 - Lattice-Boltzmann Tutorial 4 - Lattice-Boltzmann Oct 6, 2020
@jngrad jngrad force-pushed the tutorial_04_summer_school_2020 branch from 8841251 to 02e102f Compare October 6, 2020 16:01
@jngrad
Copy link
Member Author

jngrad commented Oct 6, 2020

@schlaicha @christophlohrmann @reinaual the latest changes are in, I'll hide solutions later

@RudolfWeeber
Copy link
Contributor

I only had a quick look so far.
Here are my first impressions, which might not be accurate.

One thing I find very important is to make it very clear in the text, what part of the observations actually depend on hydrodynamics and which don't.

Stuff like r_g shouldn't really be calculated with active LB, since the results can only get worse due to longer simulation times.
Also for the single particle diffusion, what difference does the LB make?

Long term, it might even be reasonable to split this tutorial. The equilibrium polymer properties could be handled in a separate "Polymers"tutorial which wouldn't use LB.

@jngrad
Copy link
Member Author

jngrad commented Oct 6, 2020

@RudolfWeeber I get the same results with Langevin Dynamics in place of LB for all observables in the polymer part. The same is probably true for the monomer part, although I didn't try it.

@@ -9,11 +9,12 @@
"#### Before you start:\n",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess the equation should read

\begin{align}
 \rho &= \sum_i f_i \
 \vec{j} = \rho \\
 \vec{u} &= \sum_i f_i \vec{c_i} \\
 \Pi^{\alpha \beta} &= \sum_i f_i \vec{c_i}^{\alpha}\vec{c_i}^{\beta}
 \label{eq:fields}
\end{align}

for better readability?


Reply via ReviewNB

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ReviewNB's support for LaTeX seems incomplete, the original equation looks good in Jupyter, with one equation per line

@schlaicha
Copy link
Contributor

The numbering is a bit weird as part 1 is from 1-3, part 2 starts with 5 and part 3 with 5.2; splitting into several files seems like a good idea but should be introduced in the notebook of part 1.

@schlaicha
Copy link
Contributor

Long term, it might even be reasonable to split this tutorial. The equilibrium polymer properties could be handled in a separate "Polymers"tutorial which wouldn't use LB.

Very good point!

@christophlohrmann
Copy link
Contributor

In Part 4 I think we should switch the exercise, such that the students have to set up the LB stuff and we give them the comparison to theory

The participants should focus on setting up an LB fluid instead of
writing the matplotlib code.
Also give more details on tasks, add links to the user guide and
renumber sections.
@jngrad
Copy link
Member Author

jngrad commented Oct 7, 2020

@schlaicha the numbering now restarts from 1 in every part
@christophlohrmann good idea, done

@jngrad jngrad added this to the Espresso 4.2 milestone Oct 7, 2020
The choice of solvent implementation only affects the Rouse vs. Zimm
regime. Chain properties such as the hydrodynamics radius, end-to-end
distance and radius of gyration do not change.
@jngrad jngrad force-pushed the tutorial_04_summer_school_2020 branch from 14cf61d to c7d42c8 Compare October 7, 2020 15:50
@RudolfWeeber
Copy link
Contributor

I suppose, we merge this PR this morning, to avoid confusion?

@jngrad
Copy link
Member Author

jngrad commented Oct 8, 2020

Yes, that would be more convenient for tutors.

@RudolfWeeber RudolfWeeber added the automerge Merge with kodiak label Oct 8, 2020
@kodiakhq kodiakhq bot merged commit b75be6f into espressomd:python Oct 8, 2020
@jngrad jngrad deleted the tutorial_04_summer_school_2020 branch January 18, 2022 12:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge Merge with kodiak
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Tutorial 04: lb part1
5 participants