Smoothed metallicity
Smoothed Metallicity is implemented for Gear. I still need to ensure that the code compile with none and EAGLE, but will do it once you accept the modifications.
You have a new example in SmoothedMetallicity that uses a glass with two different metallicities with some gaussian noise.
At the discontinuity (+- the smoothing length), the transition is smoothed and gives the following graph
In this case, I am plotting in red the particles and in blue the theoretical solution (+- 1 sigma of the noise). The three plots corresponds to 3 different elements (I do not want to follow them all as it requires 9 graphs)
@aborissov, the code should be compatible with EAGLE, therefore you will just need to copy/paste
Merge request reports
Activity
changed milestone to %Chemistry Implementation
Looks good to me in general. Great stuff!
Will have a more detailed look over the weekend. One thing is that it needs to compile at least with chemistry==none (no need for eagle fixes at this stage) otherwise the automated tests will scream.
One more thing you could do to check your implementation is to add the call to the chemistry_iact functions to
tests/testSymmetry.c
. This unit test explicitely checks that the non-symmetric and symmetric versions are compatible.added 2 commits
added 1 commit
- d62733f6 - Update doc string for gear and add missing functions to chemistry/none
I have:
- updated and tested the chemistry==none
- add chemistry in the symmetric test (but I am not initializing the chemistry data). Currently we do not need the chemistry data, therefore I did not try to initialize it, but I can do it if you wish.
- updated SmoothedMetallicity with
-n 1
- updated the wiki hydro test page with the smoothed metallicity
I forgot to mention that I did not implemented the chemistry with Gadget sph and vectorization as I understood that James will remove it.
added 19 commits
-
2613add6...3cc0dba0 - 15 commits from branch
master
- b2d96158 - Merge branch 'master' into smooth_metal
- 270acf0c - Make the run scripts executable.
- a7239fd0 - No need to rescale the smoothing lengths from the glass file.
- 286a53ff - Better way of including the chemistry data in the runner.
Toggle commit list-
2613add6...3cc0dba0 - 15 commits from branch
added 1 commit
- 8e7f248f - Added empty interaction functions for the EAGLE chemistry model.
added 1 commit
- 4afbdf04 - Removed unnecessary includes. Documentation fixes.
I am fine with your modifications.
I have updated the graphs in order to plot what you required. The idea of my old plot was to show that the dispersion is smaller with smoothed metallicity than the input (in blue) and to show the linear transition between the two parts.
Here is an updated plot:
For the first one, the black line is the relation
x=y
and each color corresponds to a different element.For the interaction, I am not sure if we need it and I do not really see a case where it could be useful. I think if we wish to use them, it will be done in a new task. Maybe we can wait a little bit on the development of the chemistry before removing it?
Edited by Loic HausammannExcellent, thanks! I think that first plot shows exactly that it works. And for the original plot I was wondering what the difference was between the three panels. It's all clear now!
Let me think about the extra parameter to the interaction functions. Passing in extra things, especially with the pointer de-referenciation here can lead to lower levels of optimisation.