Structural#

The structural module contains functions for working with both site and occupancies and atomic displacements required for setting up a general structural refinement.

intensity(U_k, A_k, Q_k, coeffs, cond, p, i_dft, factors, subtract=True)[source]#

Structural scattering intensity.

Parameters:
U_k1d array

Fourier transform of Taylor expansion displacement products.

A_k1d array

Fourier transform of relative site occupancies.

Q_k1d array

Fourier transform of Taylor expansion wavevector products.

coeffs1d array

Taylor expansion coefficients.

cond1d array

Array indices corresponding to nuclear Bragg peaks.

pint

Order of Taylor expansion.

i_dft1d array, int

Array indices of Fourier transform corresponding to reciprocal space.

factors1d array

Prefactors of form factors, phase factors, and composition factors.

Returns:
I1d array

Intensity. Array has a flattened shape of size i_dft.shape[0].

structure(U_k, A_k, Q_k, coeffs, cond, p, i_dft, factors)[source]#

Partial displacive structure factor.

Parameters:
U_k1d array

Fourier transform of Taylor expansion displacement products.

A_k1d array

Fourier transform of relative site occupancies times Taylor expansion displacement products.

Q_k1d array

Fourier transform of Taylor expansion wavevector products.

coeffs1d array

Taylor expansion coefficients.

cond1d array

Array indices corresponding to nuclear Bragg peaks.

pint

Order of Taylor expansion.

i_dft1d array, int

Array indices of Fourier transform corresponding to reciprocal space.

factors1d array

Prefactors of scattering lengths, phase factors, and occupancies.

Returns:
F1d array

Structure factor. Array has a flattened shape of size coeffs.shape[0]*i_dft.shape[0].

F_nuc1d array

Bragg structure factor. Array has a flattened shape of size cond.sum()*i_dft.shape[0].

prod1d array

Partial structure factor. Array has a flattened shape of size coeffs.shape[0]*i_dft.shape[0]*n_atm.

prod_nuc1d array

Partial Bragg structure factor.Array has a flattened shape of size coeffs.sum()*i_dft.shape[0]*n_atm.

V_k1d array

Structural parameter. Array has a flattened shape of size coeffs.shape[0]*i_dft.shape[0]*n_atm.

V_k_nuc1d array

Bragg Structural parameter. Array has a flattened shape of size coeffs.sum()*i_dft.shape[0]*n_atm.

even1d array, int

Array indices of the even Taylor expandion coefficients.

bragg1d array, int

Indices of integer reciprocal coordinates. Array has a flattened shape of size coeffs.sum().

transform(U_r, A_r, H, K, L, nu, nv, nw, n_atm)[source]#

Discrete Fourier transform of Taylor expansion displacement products and relative occupancy parameter.

Parameters:
U_r1d array

Displacement parameter \(U\) (in Cartesian coordinates).

A_r1d array

Relative occupancy parameter \(A\).

H, K, L1d array, int

Supercell index along the \(a^*\), \(b^*\), and \(c^*\)-axis in reciprocal space.

nu, nv, nwint

Number of grid points \(N_1\), \(N_2\), \(N_3\) along the \(a\), \(b\), and \(c\)-axis of the supercell.

n_atmint

Number of atoms in the unit cell.

Returns:
U_k1d array

Fourier transform of displacement paramter. Array has a flattened shape of size nu*nw*nv*n_atm.

A_k1d array

Fourier transform of relative occupancy parameter. Array has a flattened shape of size nu*nw*nv*n_atm.

i_dft1d array, int

Fourier transform indices. Array has a flattened shape of size nu*nw*nv*n_atm.