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

WIP: Fix diffraction scaling. #761

Closed
wants to merge 5 commits into from
Closed

Conversation

bdice
Copy link
Member

@bdice bdice commented Apr 28, 2021

Description

Work in progress with @tcmoore3.

To-do:

  • Identify how to correctly transform non-cubic boxes.
  • Identify scaling factor for k-values / k-vectors.
  • Write tests ensuring that the correct k-vector peaks are found for a system with a non-cubic box.
  • Indicate breaking changes in changelog.

Motivation and Context

Resolves #750, resolves #723.

How Has This Been Tested?

Need to add new tests!

Screenshots

Need to include a screenshot!

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds or improves functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation improvement (updates to user guides, docstrings, or developer docs)

Checklist:

  • I have read the CONTRIBUTING document.
  • My code follows the code style of this project.
  • I have updated the documentation (if relevant).
  • I have added tests that cover my changes (if relevant).
  • All new and existing tests passed.
  • I have updated the credits.
  • I have updated the Changelog.

@bdice bdice requested a review from a team as a code owner April 28, 2021 23:47
@bdice bdice requested a review from Tobias-Dwyer April 28, 2021 23:47
@bdice bdice changed the title Fix diffraction scaling. WIP: Fix diffraction scaling. Apr 28, 2021
@bdice bdice marked this pull request as draft April 28, 2021 23:47
@bdice bdice removed the request for review from Tobias-Dwyer April 28, 2021 23:47
@bdice bdice added bug Something isn't working diffraction labels Apr 28, 2021
@codecov
Copy link

codecov bot commented Apr 29, 2021

Codecov Report

Merging #761 (1d60d6f) into master (c68dbce) will increase coverage by 0.03%.
The diff coverage is 88.88%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #761      +/-   ##
==========================================
+ Coverage   55.47%   55.51%   +0.03%     
==========================================
  Files          16       16              
  Lines        2419     2421       +2     
  Branches       35       35              
==========================================
+ Hits         1342     1344       +2     
  Misses       1064     1064              
  Partials       13       13              
Impacted Files Coverage Δ
freud/diffraction.pyx 72.46% <88.88%> (+0.40%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c68dbce...1d60d6f. Read the comment docs.

@tcmoore3 tcmoore3 self-assigned this Apr 29, 2021
tcmoore3 and others added 4 commits April 30, 2021 02:07
This change gives me diffraction patterns that preserve the symmetries
of the crystal structure, even for different numbers of unit cells in
each direction, at least for a square lattice looking straigh down the
z-axis. I'm pretty sure the k-values are still wrong, and need to use
the same factor I used in the shear matrix somehow. I'm also not sure if
that factor I scale by is correct. It seems right that it doesn't depend
on the height of a cubic box when you're looking straight on though.
@tommy-waltmann tommy-waltmann mentioned this pull request Apr 12, 2022
11 tasks
@bdice
Copy link
Member Author

bdice commented Jun 28, 2023

Closing as stale.

@bdice bdice closed this Jun 28, 2023
@joaander joaander deleted the fix/diffraction-scaling branch July 30, 2024 16:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working diffraction
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Diffraction pattern depends on shape of simulation box Document/fix units for k vectors in diffraction
3 participants