a list of line segments separating neighbouring grains in a two-dimensional map

Syntax

gB = grains.boundary
interphase = gB['Forsterite', 'Enstatite']
lengths = gB.segLength
mori = interphase.misorientation

Description

Grain reconstruction creates these segments together with the adjacent grain ids, EBSD pixel ids, phases and rotations. Segments are stored head to tail along chains, with the first adjacent grain on the left of the walk. A chain ends at a junction or closes on itself. Selecting segments keeps the shared vertex table; segment indices and vertex indices are different. All Python indices are zero-based.

Select by a mask, integer indices, one phase name, or a pair of phase names. Before asking for misorientation, select a single phase pair so its crystal frames are unambiguous. The exterior has grain id 0, pixel id -1 and phase id -1.

Input

V array of shape (n, 2), vertex coordinates in the map plane
F integer array of shape (m, 2), endpoint indices into V
grainId array of shape (m, 2), adjacent grain ids
ebsdId array of shape (m, 2), adjacent EBSD pixel ids
phaseId array of shape (m, 2), adjacent phase-list indices
misrotation rotation across each segment
CSList list of phase frames
plane map-plane coordinate system converting V to specimen positions
frame specimenFrame of the geometry
scanUnit unit of vertex coordinates; default ‘um’

Output

gB grainBoundary, usually obtained as grains.boundary

Properties

allV all stored vertices as vector3d specimen positions
F segment endpoint indices into V
grainId grain ids on the two sides; ids need not equal array positions
segLength length of each segment in scanUnit
direction segment vectors as antipodal vector3d, with segment length
midPoint midpoint of each segment as vector3d
misorientation symmetry-aware orientation relationship for one phase pair
chainId chain membership of each segment
arcLength distance along the chain to the end of each segment
triplePoints junctions at which three grains meet

See also

calcGrains, grain2d, grainBoundary.curvature, grainBoundary.calcMeanDirection

Signature

grainBoundary(V, F, grainId, ebsdId, phaseId, misrotation, CSList, plane, frame, scanUnit='um')

MATLAB’s grainBoundary.grainBoundary

source

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/grainBoundary.grainBoundary_py.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.