oM.inversePoleFigureDirection = zvector; % for "normal" ND
oM.inversePoleFigureDirection = yvector; % for TD
oM.inversePoleFigureDirection = xvector; % for RD
Is this correct, or do i have to rotate the whole ebsd dataset around 90 degree?
Thanks and best whises,
Mike
While the default for colouring a map of the type plot(ebsd('Magnesium'),ebsd('Magnesium').orientations) is IPFZ, this can be changed to another direction
%create the ipf sector/shape and color it
oM = ipdfHSVOrientationMapping(ebsd('Magnesium'));
%define the direction of the ipf
oM.inversePoleFigureDirection = yvector;
%convert the ebsd map orientations to a color based on the IPF
color = oM.orientation2color(ebsd('Magnesium').orientations);
%plot the figure using the new colour map
figure; plot(ebsd('Magnesium'),color);
The first command is only required once per matlab session
oM.inversePoleFigureDirection = zvector;
color = oM.orientation2color(ebsd('Magnesium').orientations);
plot(ebsd('Magnesium'),color);
oM.inversePoleFigureDirection = xvector;
color = oM.orientation2color(ebsd('Magnesium').orientations);
plot(ebsd('Magnesium'),color);
any other vector3d can be used to color the map, some examples of different ways to define them are below.
%assign vector using specimen directions
V45 = vector3d(1,-1,0);
oM.inversePoleFigureDirection = V45;
color = oM.orientation2color(ebsd('Magnesium').orientations);
plot(ebsd('Magnesium'),color);
%or as a series of spherical coordinates
polar_angle = 60*degree;
azimuth_angle = 45*degree;
v = vector('polar',polar_angle,azimuth_angle);
%or as a combination of other vectors
v = xvector + 2*yvector;
%and then plot it to confirm the direction
plot([zvector,xvector+yvector+zvector],'labeled')