-
Notifications
You must be signed in to change notification settings - Fork 49
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
NEW feature: intermediate scattering function #1042
base: main
Are you sure you want to change the base?
Conversation
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
… store the results of each accumulate at the python-end; so we need to create a data structure to save multiple getBinCounts of self and distinct function and convert it to (n_frames, nbins) array
for more information, see https://pre-commit.ci
Hi @Roy-Kid, thanks for getting such a quick start! This is great and I can tell this took significant effort on your part to write. Before I get into more detailed comments, I want to talk about some conceptual things related to the intermediate scattering function. The first thing is that the intermediate scattering function is not a static structure factor, it is dynamic in that it needs data from multiple different times in order to compute. At the same time, it shares the same method of sampling vectors in k-space with the The second thing is about whether or not we should be able to accumulate the intermediate scattering function. In the MSD code, the calculation can be accumulated over more points because each point's MSD can be computed independent of the other points. In the code for the other structure factors, the calculation can be accumulated over many frames because each frame can be computed independent of the other frames, and the histogram freud computes internally can have more counts added to it. The intermediate scattering function, by contrast to the previous two calculations, needs all positions at all times to compute, which means accumulation conceptually does not make sense. Going forward, I will jump in and alter the inheritance hierarchy of the structure factor classes, remove the ability to accumulate from the class, and make some other small changes to the API. Then, if you wish, you can jump back in and make some of the more detailed changes like updating the documentation, adding more tests, validating the calculation on your use case, etc. Once again, thanks for taking the initiative with this feature, I'm sure other people will find use for it as well! |
Yes I will. Thanks guys! |
One more conceptual thing that I forgot to mention before: There should be no need for use of a neighbor list in this calculation. Since the sums are over all particles, we already know that all particles are neighbors of each other. It will likely, in fact, slow down the |
Thanks for all your correction! I have some misunderstandings about the intermediate scattering function. Now it seems that it is not a simple combination of MSD and static scattering function (even if some methods can be reused). I'll leave the code to you next. Thank you for your adjustment in the code architecture. |
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
Hi, @Roy-Kid at this point I have finished restructuring the code so that the calculation will fit correctly into freud's structure.. Everything will compile, but the implementation is wrong. Are you willing to give the implementation another try? It should only involve changing the |
I'm so sorry for replying late. I'm busy with my mid-term assessment and PhD application, so I don't have time to develop the code these days. If you have time, could you please continue to finish the work, or wait for me until the next year February? Sorry again for the delay... |
…ted to access index 750 in an array of size 100
for more information, see https://pre-commit.ci
Hi, @tommy-waltmann. I try to implement the code of |
@Roy-Kid the issue was in access out-of-bounds memory in two spots, I've made some changes and there are no more crashes. The code should be in a place where you can continue with the implementation. |
Description
Please assist me in improving the code @tommy-waltmann
To calculate time-dependent intermediate scattering function. Here are the refs:
Motivation and Context
Here we add a class derived from
StaticStructureFactorDirect
to calculate the time-dependent intermediate scattering function.Resolves: #1040
How Has This Been Tested?
This code has not been tested before complete
Types of changes
Checklist: