Diffuse Scattering Guide

Utilities documentation for the RMC6f diffuse-scattering tool.

What This Tool Does

The diffuse-scattering tool computes reciprocal-space diffuse intensity I(h,k,l) directly in the browser from an .rmc6f atomistic configuration or a unified structure .h5 file. It is intended for interactive exploration of diffuse features rather than for inverse reconstruction.

Use this tool to compute, slice, visualize, and export diffuse-scattering volumes from RMC6f or unified-HDF5 structures without leaving the browser.

Quick Start

  1. Open the tool.
  2. Load an .rmc6f or unified structure .h5 file.
  3. Choose a backend: WebGPU first, CPU FFT if WebGPU is unavailable.
  4. Set the reciprocal-space grid and press Compute Diffuse.
  5. Inspect the 3D Slice Plane, 2D Slice Map, and 3D Isosurface.
Input:  .rmc6f or unified structure .h5
Output: diffuse volume + slices + exports (.h5/.dat/.json/.vtk/.cube/.csv/.svg/.html)
Diffuse scattering calculator interface after loading LiFeO2 and computing diffuse intensity
Example live interface after computing diffuse scattering for LiFeO2.rmc6f. The main workflow areas are the input/setup panel on the left, the 3D Slice Plane at top center, the 2D Slice Map below it, and the 3D render/export controls on the right.

Precision Notice

Important: the WebGPU FFT/NUFFT stack and the CPU FFT path used by this calculator currently operate in single precision (fp32) and do not provide fp64 arithmetic. Small numerical differences, rounding-sensitive behavior, or precision-related artifacts can appear, especially for large grids, high dynamic range, or cancellation-sensitive features. For important scientific checks, compare against type3NufftCpuDirect and test whether the interpretation is stable with respect to backend and grid settings.

Major Views

ViewPurpose
3D Slice PlaneShows a planar cut through the diffuse volume in reciprocal space.
2D Slice MapShows the current slice in a 2D coordinate frame for easier inspection of diffuse features.
3D IsosurfaceShows a constant-intensity contour view of the diffuse volume.

How To Read The Views

For sample-specific examples of these patterns, see the examples guide.

Slice Modes

ModeMeaning
AxisFix one reciprocal-lattice coordinate and inspect a conventional crystallographic section.
Normal planeDefine a custom plane by its normal and slide it through reciprocal space.
Volume averageAverage the diffuse intensity over a slab around the current plane.

Volume Average Mode

Volume average mode is designed for broad or noisy diffuse features. Instead of sampling one infinitely thin plane, the calculator evaluates multiple parallel planes and averages them into a slab view.

Use this mode when a single normal plane looks too sparse, noisy, or overly sensitive to exact plane placement.

Advanced Calculation Controls

ControlPurpose
Subtract avgSubtract the coherent average-structure contribution so the result emphasizes diffuse scattering rather than the total intensity including Bragg-like contributions.
Aavg NChoose whether the average subtraction uses all atoms or only the atoms currently included by the element filter.
Normalize NqNormalize by the reciprocal-space grid size so runs at different resolutions are easier to compare.
Viewer scaleChoose log10 or linear display scaling for the diffuse intensity.
Base nameControls the base filename used by the export actions.

See Theory for the equations behind these controls.

Element Filter

The Element Filter is an experimental feature that lets you include or exclude specific elements from the scattering calculation. This is useful for partial diffuse-scattering views, but it changes the meaning of normalization and average subtraction, especially when Aavg N is set to N included.

Smoothing Controls

The advanced Smoothing controls operate on the computed 3D intensity volume before visualization.

Lanczos is a good general-purpose smoothing filter. Chebyshev is more tunable and can produce stronger suppression of ringing depending on the chosen dB value.

Backends And Scattering Choices

The UI also supports neutron, X-ray, and electron scattering options with model/table selection.

Practical default grid-limit presets are backend-dependent: the WebGPU preset uses 8,000,000 voxels, while the CPU FFT and direct CPU presets use 120,000 voxels. These are practical defaults, not hard physical limits, but they are the right starting point for sizing runs.

Supplementary Material

Backend provenance, scattering-table families, and citation-oriented notes are collected in Diffuse Scattering Supplementary.

3D Render Controls

Exports

Base name controls the export filename prefix. Open Slice Window opens the current 2D slice in a separate browser window for side-by-side comparison. VTK and Cube export expect uniform axes; if the reciprocal axes are not uniform, those exports are intentionally rejected by the tool.

For sample-specific workflows, use the examples guide.