-
Notifications
You must be signed in to change notification settings - Fork 7
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
Do you know of a way to integrate density within a particular Miller (HKL) plane? #96
Comments
Hi, @sgbaird I think will have to define a grid and a set of inequalities to create a mask for that grid then apply the mask and get the integrated charge. |
I'm actually interested in this or similar functionality too. I'm wondering what a convenience method might look like:
I'm looking at this StackOverflow answer, does this seem reasonable? |
Does |
Correct. |
I think it will be easier to get the reorientation information and boundaries in the transformed cell (without any consideration for the numpy volumetric data) then just use the internal machinery we already have for the interpolation. |
I should probably mention that I implemented something similar in Mathematica using some nice analytical and numerical integration functions for 3D objects. See https://github.com/sgbaird/LatticePlane and https://doi.org/10.1107/S1600576722001492. I had explored doing this in Python with some geometry packages (scikit-geom or something like that), but had some trouble. |
Cool, so this looks like you had an analytic form for your density so calculating it for a set of points directly is going to be much more accurate. |
@jmmshn thanks! For the LatticePlane study, I approximated atoms as hard spheres, points, or isotropic Gaussian distributions based on CIF input data. While I mentioned applicability to DFT data, I never used DFT data directly. If I were to use LatticePlane, I'd consider doing a 3D (e.g. spline) interpolation of the points prior to numerical integration across the plane. Interpolation probably isn't necessary if densities are probeable at arbitrary locations without expensive, additional calculations. On a separate note, @mkhorton what got you interested in density integration within a bounded plane? |
For an arbitrary crystal structure and an arbitrary Miller plane (e.g. 110), integrate the density across the polygon that's bounded within the unit cell.
The text was updated successfully, but these errors were encountered: