This example sheet describes how to estimate dislocation densities following the reference paper
Lets start by importing orientation data from 2 percent uniaxial deformed steel DC06 and reconstructing the grain structure while removing all grains with less than 6 pixels
% import the EBSD data
plottingConvention.default('y←↑x');
ebsd = EBSD.load([mtexDataPath filesep 'EBSD' filesep 'DC06_2uniax.ang'],'setting',2);
% reconstruct grains
[grains,ebsd] = calcGrains(ebsd,'angle',2.5*degree,'minPixel',6);
% smooth grain boundaries
grains = smoothBoundary(grains,5);
% define the color key
ipfKey = ipfHSVKey(ebsd);
ipfKey.ipfDirection = yvector;
% plot the orientation data
plot(ebsd,ipfKey.orientation2color(ebsd.orientations),'refFrame','on','figSize','medium')
% and on top of it the grain boundaries
hold on
plot(grains.boundary,'linewidth',2)
hold off
Data cleaning
The computation of geometrically necessary dislocations from EBSD maps depends on local orientation changes in the map. In order to make those visible we switch to a different color key that colorizes the misorientation of an pixel with respect to the grain meanorientation.
% a key the colorizes according to misorientation angle and axis
ipfKey = axisAngleColorKey(ebsd);
% set the grain mean orientations as reference orientations
ipfKey.oriRef = grains(ebsd('indexed').grainId).meanOrientation;
% plot the data
plot(ebsd('indexed'),ipfKey.orientation2color(ebsd('indexed').orientations),'micronBar','off','figSize','medium')
hold on
plot(grains.boundary,'linewidth',2)
hold off
We observe that the data are quite noisy. As noisy orientation data lead to overestimating the GND density we first have to denoise the orientation data.
% define the denoising filter
F = halfQuadraticFilter;
ebsd = smooth(ebsd,F,'fill',grains);
% plot the denoised data
ipfKey.oriRef = grains(ebsd('indexed').grainId).meanOrientation;
plot(ebsd('indexed'),ipfKey.orientation2color(ebsd('indexed').orientations),'micronBar','off','figSize','medium')
hold on
plot(grains.boundary,'linewidth',2)
hold off
The GND density in one command
Everything below is done for you by calcGND, which takes the EBSD data and a set of dislocation systems and returns the total dislocation energy per pixel together with the density of each individual system.
% the dislocation systems of a body centered cubic material, with the
% energies of edge and screw dislocations set as discussed further below
dS = dislocationSystem.bcc(ebsd.CS);
dS(dS.isEdge).u = 1;
dS(dS.isScrew).u = 1 - 0.3;
[gnd,rho] = calcGND(ebsd,dS);
close all
plot(ebsd,gnd,'micronbar','off')
mtexColorMap('hot')
mtexColorbar
set(gca,'ColorScale','log');
set(gca,'CLim',[1e11 5e14]);
hold on
plot(grains.boundary,'linewidth',2)
hold off
The remainder of this page walks through what calcGND does internally.
The incomplete curvature tensor
Starting point of any GND computation is the curvature tensor, which is a rank two tensor that is defined for every pixel in the EBSD map by the directional derivatives in x, y and z direction.
% the curvature tensor for each pixel in the map
kappa = ebsd.curvature
% the curvature tensor in pixel (3,2)
kappa(3,2)kappa = curvatureTensor (y←↑x)
size: 101 x 51
unit: 1/um
rank: 2 (3 x 3)
ans = curvatureTensor (y←↑x)
unit: 1/um
rank: 2 (3 x 3)
*10^-5
4.28 -27.46 NaN
7.96 -61.91 NaN
57.48 -30.84 NaNAs expected the curvature tensor is NaN in the third column as this column corresponds to the directional derivative in z-direction which is usually unknown for 2d-EBSD maps.
We can access the different components of the curvature tensor with
kappa12 = kappa{1,2};
size(kappa12)ans =
101 51which results in a variable of the same size as our EBSD data. This allows us to visualize the different components of the curvature tensor
newMtexFigure('nrows',3,'ncols',3);
% cycle through all components of the tensor
for i = 1:3
for j = 1:3
nextAxis(i,j)
plot(ebsd,kappa{i,j},'micronBar','off')
hold on; plot(grains.boundary,'linewidth',2); hold off
end
end
% unify the color rage - you may also use setColoRange equal
setColorRange([-0.005,0.005])
drawNow(gcm,'figSize','large')
The incomplete dislocation density tensor
The curvature tensor \(\kappa\) is directly related to the dislocation density tensor \(\alpha\) by
\[ \alpha = \kappa^T - \mathrm{tr}(\kappa) \, I \]
This is the relation Nye, Some geometrical relations in dislocated crystals, Acta Metallurgica, 1953 derived for a crystal lattice, which is why \(\alpha\) is also called the Nye tensor. The continuum theory it belongs to is Kröner, Kontinuumstheorie der Versetzungen und Eigenspannungen, Springer, 1958, hence the relation is usually attributed to both.
alpha = kappa.dislocationDensityalpha = dislocationDensityTensor (y←↑x)
size: 101 x 51
unit: 1/um
rank: 2 (3 x 3)which has the same unit as the curvature tensor and is incomplete as well as we can see when looking at a particular one.
% the incomplete dislocation density tensor for map position (3,2)
alpha(3,2)ans = dislocationDensityTensor (y←↑x)
unit: 1/um
rank: 2 (3 x 3)
*10^-5
NaN 7.96 57.48
-27.46 NaN -30.84
NaN NaN 57.63Crystallographic Dislocations
The central idea of Pantleon (2008) is that the dislocation density tensor is build up by single dislocations with different densities such that the total energy is minimum. Depending on the atomic lattice different dislocation systems have to be considered. In present case of a body centered cubic (bcc) material 48 edge dislocations and 4 screw dislocations have to be considered. Those principle dislocations are defined in MTEX either by their Burgers and line vectors or by
dS = dislocationSystem.bcc(ebsd.CS)dS = dislocationSystem
mineral: Iron (Alpha) (m-3m)
edge dislocations : 48 x 1
Burgers vector line vector energy length
[1 -1 1] [-2 -1 1] 2 2.49
[1 1 -1] [2 -1 1] 2 2.49
[1 1 -1] [1 -2 -1] 2 2.49
[-1 1 1] [1 2 -1] 2 2.49
[1 -1 1] [-1 1 2] 2 2.49
[-1 1 1] [-1 1 -2] 2 2.49
[1 -1 1] [1 2 1] 2 2.49
[1 1 1] [-1 2 -1] 2 2.49
[1 1 -1] [1 1 2] 2 2.49
[1 1 1] [-1 -1 2] 2 2.49
[-1 1 1] [2 1 1] 2 2.49
[1 1 1] [2 -1 -1] 2 2.49
[-1 1 1] [0 1 -1] 2 2.49
[1 -1 1] [-1 0 1] 2 2.49
[1 1 -1] [1 -1 0] 2 2.49
[-1 1 1] [-1 0 -1] 2 2.49
[1 -1 1] [-1 -1 0] 2 2.49
[1 1 -1] [0 -1 -1] 2 2.49
[1 1 -1] [1 0 1] 2 2.49
[-1 1 1] [1 1 0] 2 2.49
[1 -1 1] [0 1 1] 2 2.49
[-1 -1 -1] [0 -1 1] 2 2.49
[-1 -1 -1] [1 0 -1] 2 2.49
[-1 -1 -1] [-1 1 0] 2 2.49
[-1 1 1] [-1 4 -5] 2 2.49
[1 -1 1] [-5 -1 4] 2 2.49
[1 1 -1] [4 -5 -1] 2 2.49
[-1 1 1] [-4 1 -5] 2 2.49
[1 -1 1] [-5 -4 1] 2 2.49
[1 1 -1] [1 -5 -4] 2 2.49
[1 1 -1] [4 1 5] 2 2.49
[-1 1 1] [5 4 1] 2 2.49
[1 -1 1] [1 5 4] 2 2.49
[-1 -1 -1] [-1 -4 5] 2 2.49
[-1 -1 -1] [5 -1 -4] 2 2.49
[-1 -1 -1] [-4 5 -1] 2 2.49
[1 -1 1] [1 -4 -5] 2 2.49
[1 1 -1] [-5 1 -4] 2 2.49
[-1 1 1] [-4 -5 1] 2 2.49
[1 -1 1] [4 -1 -5] 2 2.49
[1 1 -1] [-5 4 -1] 2 2.49
[-1 1 1] [-1 -5 4] 2 2.49
[-1 -1 -1] [-4 -1 5] 2 2.49
[-1 -1 -1] [5 -4 -1] 2 2.49
[-1 -1 -1] [-1 5 -4] 2 2.49
[1 1 -1] [1 4 5] 2 2.49
[-1 1 1] [5 1 4] 2 2.49
[1 -1 1] [4 5 1] 2 2.49
screw dislocations: 4 x 1
Burgers vector energy length
[1 -1 1] 1 2.49
[-1 -1 -1] 1 2.49
[-1 1 1] 1 2.49
[1 1 -1] 1 2.49Here the norm of the Burgers vectors is important
% size of the unit cell
a = norm(ebsd.CS.aAxis);
% in bcc and fcc the norm of the burgers vector is sqrt(3)/2 * a
[norm(dS(1).b), norm(dS(end).b), sqrt(3)/2 * a]ans =
2.4855 2.4855 2.4855The Energy of Dislocations
The energy of each dislocation system can be stored in the property u. By default this value it set to 1 but should be changed according to the specific model and the specific material.
According to Hull & Bacon, Introduction to Dislocations, 5th edition, Butterworth-Heinemann, 2011 the energy U of edge and screw dislocations is given by the formulae
\[ U_{\mathrm{screw}} = \frac{Gb^2}{4\pi} \ln \frac{R}{r_0} \]
\[ U_{\mathrm{edge}} = \frac{1}{(1-\nu)} U_{\mathrm{screw}} \]
where
-
Gis the shear modulus -
bis the length of the Burgers vector -
nuis the Poisson ratio -
Ris the outer cut off radius -
r_0is the radius of the dislocation core
In this example we assume \[ U_{\mathrm{edge}} = 1 \] \[ U_{\mathrm{screw}} = 1-\nu \]
nu = 0.3;
% energy of the edge dislocations
dS(dS.isEdge).u = 1;
% energy of the screw dislocations
dS(dS.isScrew).u = 1 - nu;There is no single accepted way of setting these energies. Formulae in use include U = 1 - nu as above, and U = c * G * |b^2| with G the shear modulus, i.e. an energy per unit length squared. Which one is appropriate depends on the model you are comparing against, so u is left for you to set rather than being fixed by MTEX.
A single dislocation causes a deformation that can be represented by the rank one tensor
dS(1).tensorans = dislocationDensityTensor (Iron (Alpha))
unit: au
rank: 2 (3 x 3)
-1.1717 -0.5858 0.5858
1.1717 0.5858 -0.5858
-1.1717 -0.5858 0.5858Note that the unit of this tensors is the same as the unit used for describing the length of the unit cell, which is in most cases Angstrom (au). Furthermore, we observe that the tensor is given with respect to the crystal reference frame while the dislocation density tensors are given with respect to the specimen reference frame. Hence, to make them compatible we have to rotate the dislocation tensors into the specimen reference frame as well. This is done by
dSRot = ebsd.orientations * dSdSRot = dislocationSystem
edge dislocations : 5144 x 48
screw dislocations: 5144 x 4Fitting Dislocations to the incomplete dislocation density tensor
Now we are ready for fitting the dislocation tensors to the dislocation density tensor in each pixel of the map. This is done by the command fitDislocationSystems.
[rho,factor] = fitDislocationSystems(kappa,dSRot);As result we obtain a matrix of densities rho such that the product with the dislocation systems yields the incomplete dislocation density tensors derived from the curvature, i.e.,
% the restored dislocation density tensors
alpha = reshape(sum(dSRot.tensor .* rho,2),size(ebsd));
% we have to set the unit manually since it is not stored in rho
alpha.opt.unit = '1/um';
% the restored dislocation density tensor for map position (3,2)
alpha(3,2)
% the dislocation density derived from the curvature for map position (3,2)
kappa(3,2).dislocationDensityans = dislocationDensityTensor (y←↑x)
unit: 1/um
rank: 2 (3 x 3)
*10^-5
59.13 7.96 57.48
-27.46 -7.06 -30.84
12.66 -9.03 57.63
ans = dislocationDensityTensor (y←↑x)
unit: 1/um
rank: 2 (3 x 3)
*10^-5
NaN 7.96 57.48
-27.46 NaN -30.84
NaN NaN 57.63we may also restore the complete curvature tensor with
kappa = alpha.curvature
kappa(3,2)kappa = curvatureTensor (y←↑x)
size: 101 x 51
unit: 1/um
rank: 2 (3 x 3)
ans = curvatureTensor (y←↑x)
unit: 1/um
rank: 2 (3 x 3)
*10^-5
4.28 -27.46 12.66
7.96 -61.91 -9.03
57.48 -30.84 2.78and plot it as we did before
newMtexFigure('nrows',3,'ncols',3);
% cycle through all components of the tensor
for i = 1:3
for j = 1:3
nextAxis(i,j)
plot(ebsd,kappa{i,j},'micronBar','off')
hold on; plot(grains.boundary,'linewidth',2); hold off
end
end
setColorRange([-0.005,0.005])
drawNow(gcm,'figSize','large');
The total dislocation energy
The unit of the densities h in our example is 1/um * 1/au where 1/um comes from the unit of the curvature tensor an 1/au from the unit of the Burgers vector. In order to transform h to SI units, i.e., 1/m^2 we have to multiply it with 10^16. This is exactly the values returned as the second output factor by the function fitDislocationSystems.
factorfactor =
1.0000e+16Multiplying the densities rho with this factor and the individual energies of the the dislocation systems we end up with the total dislocation energy, which is what calcGND returned at the top of this page. Lets plot it at a logarithmic scale
close all
plot(ebsd,factor*sum(abs(rho .* dSRot.u),2),'micronbar','off')
mtexColorMap('hot')
mtexColorbar
set(gca,'ColorScale','log'); % this works only starting with Matlab 2018a
set(gca,'CLim',[1e11 5e14]);
hold on
plot(grains.boundary,'linewidth',2)
hold off
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/GND.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.