discrepancy between rotational densities and/or weighted orientation sets
Description
B(C,r) = {R : angle(C,R) <= r}. D_ball is sup (mu-eta)(B(C,r)). D_2^2 integrates this squared difference against normalized center Haar measure dR/(8*pi^2) and radius sin(r) dr on [0,pi]. Stolarsky's identity turns it into the chordal energy
D_2^2(nu) = nu(SO(3))^2/2
- 1/(2*sqrt(2)*pi) int int |R-S|_F dnu(R) dnu(S) ,with R-S_F = sqrt(8) sin(omega/2), which is why atomic terms are exact at every bandwidth. L2^2 sums squared Haar-orthonormal Wigner moments through bandwidth L. All three measure a difference in total mass as well, so nothing has to be normalized - an ODF of mean one and integral 8*pi^2 and the probability density of integral one describing the same texture differ by that factor and the discrepancy says so. Functions keep their own integral through the projection; increase the bandwidth to check convergence. A sample compared with f is scaled to integral(f), and keeps mass one if that integral vanishes; two samples each have mass one. An orientation represents the uniform measure on its orbit of symmetrically equivalent rotations, a bare rotation a single atom - a symmetric density does not symmetrize a bare rotation sample.
D_ball uses a finite search: it is a lower-bound approximation for the represented measures, not a certified global maximum. info.isExact is false, and info.closed=false denotes the open-ball limiting value at the reported radius. Orientation space is three dimensional, so a center grid resolves it far more coarsely than a grid of the same size resolves the sphere and the estimate rises well past the default - refine numCenters and numRadii until it settles. Against a peaked density the atoms themselves are the decisive centers and the estimate is stable much earlier.
'kernel' preserves the historical squared, truncated optimalSample objective and uses that iteration's transform, so it reproduces it exactly. Its degree zero coefficient is negative, so it drops the mass term and takes two functions of equal integral only. It equals 2*sqrt(2)*pi times the squared D_2 of the harmonically projected difference, and it imposes the symmetry of the density on the sample. It is NOT maximum ball discrepancy. 'squared' is redundant for this legacy metric.
Syntax
d = discrepancy(f,g,'metric','D_2')
d = discrepancy(f,ori,'metric','D_ball','numCenters',4097)
d = discrepancy(f,ori,'metric','L2','bandwidth',16)
d2 = discrepancy(f,ori,'metric','L2','bandwidth',16,'squared')
[d,info] = discrepancy(f,ori,'metric','D_ball')Input
| f,g | scalar real SO3Fun |
| ori | rotation or orientation, representing a weighted probability measure |
Output
| res | discrepancy (square root for D_2 and L2 unless 'squared') |
| info | method and approximation information; for D_ball also a witness ball |
Options
| metric | 'D_2' (default), 'D_ball', 'L2' (alias 'E_L'), or 'kernel' |
| weights | nonnegative point weights, normalized to sum to one |
| bandwidth | harmonic projection degree for functions and L2 moments; default max function bandwidth (64 for nonharmonic functions or orientation/orientation pairs). D_2 and D_ball retain all atomic mass, including modes above this bandwidth. |
| degreeWeights | L2 energy weights for degrees 0:L, numeric or function handle of degree; default one. Degree zero weights the difference in total mass. |
| numCenters | D_ball search centers, default 2049, plus the identity and the atoms; use 'centers',rotation to supply them |
| numRadii | D_ball uniform radius grid size, default 257; all atomic jumps and their one-sided limits are also checked |
Flags
| squared | return the square of the standard discrepancy |
See also
Citing this page.
This page is part of the documentation of
MTEX, a free and open
source MATLAB toolbox for analyzing and modeling crystallographic textures.
It was written by The MTEX Developers and is published at
https://mtex-toolbox.github.io/SO3Fun.discrepancy.html.
If you use MTEX, or reuse text or figures from this page, in your research,
please cite
F. Bachmann, R. Hielscher, H. Schaeben: Texture Analysis with MTEX - Free and Open Source Software Toolbox, Solid State Phenomena 160 (2010), 63-68. 10.4028/www.scientific.net/SSP.160.63
BibTeX
@article{bachmann2010mtex,
author = {F. Bachmann and R. Hielscher and H. Schaeben},
title = {Texture Analysis with MTEX - Free and Open Source Software Toolbox},
journal = {Solid State Phenomena},
volume = {160},
pages = {63-68},
year = {2010},
doi = {10.4028/www.scientific.net/SSP.160.63},
url = {https://doi.org/10.4028/www.scientific.net/SSP.160.63}
}
Other papers describing specific MTEX methods are listed under Publications — please cite the one that best fits your application. The MTEX source code is licensed under the GNU General Public License v2.0; the text and figures of this documentation are licensed under CC BY 4.0, which permits reuse — including by automated systems — provided The MTEX Developers and this page are credited.