How to put plane and direction pole figures together?

149 views
Skip to first unread message

Yilun Shao

unread,
Mar 29, 2017, 3:15:09 AM3/29/17
to MTEX
Hello,

Now I'm using MTEX to deal with xenolith data, when dealing with diopside, I want to show plane (100), (010) and direction [001]'s PDF in one figure, so I type the scripts like this:

%% Pole figure Diopside
% pole figure
o_an_all = ebsd('Diopside').orientations; % All Diopside orientations
o_an_1pg = grains(grains.grainSize >= 16,'Diopside').meanOrientation; % meanOrientation = one point per grain

% Define orientations to be plotted
orientations = [Miller(1,0,0,ebsd('Diopside').CS,'plane'), ...
                Miller(0,1,0,ebsd('Diopside').CS,'plane'), ...
                Miller(0,0,1,ebsd('Diopside').CS,'direction')];


figure
plotPDF(o_an_1pg,orientations, ...
   'hemisphere','lower','projection','earea','antipodal', ...
   'npoints',1000,'markersize',2)

the command window says:
Warning: Miller indices are converted to hkl
> In Miller.cat at 21
  In vector3d.horzcat at 4
and the figure is shown as figure 1, the third pole figure shows as (---).

If I change the scripts as following:
% Define orientations to be plotted
orientations = [Miller(1,0,0,ebsd('Diopside').CS,'plane'), ...
                Miller(0,1,0,ebsd('Diopside').CS,'plane')];

orientations2 = [Miller(0,0,1,ebsd('Diopside').CS,'direction')];


figure
plotPDF(o_an_1pg,orientations,orientations2, ...
   'hemisphere','lower','projection','earea','antipodal', ...
   'npoints',1000,'markersize',2)
The figure shows (100) and (010) pole figures only (figure 2), without [001] pole figure. No abnormal information in command window.


If I change the scripts as following:
% Define orientations to be plotted
orientations = [Miller(1,0,0,ebsd('Diopside').CS,'plane'), ...
                Miller(0,1,0,ebsd('Diopside').CS,'plane')];
          
figure
plotPDF(o_an_1pg,orientations, ...
   'hemisphere','lower','projection','earea','antipodal', ...
   'npoints',1000,'markersize',2)

% Define orientations to be plotted
orientations = [Miller(0,0,1,ebsd('Diopside').CS,'direction')];
figure
plotPDF(o_an_1pg,orientations, ...
   'hemisphere','lower','projection','earea','antipodal', ...
   'npoints',1000,'markersize',2)
The plane pole figures (figure 2) and direction pole figure (figure 3) were shown separately. No abnormal information in command window.
So I want to combine the information of figure2 and 3 together, please give me a hand.
Thanks

Yilun Shao



figure 1.png
figure 2.png
figure 3.png

Rüdiger Kilian

unread,
Mar 29, 2017, 4:48:58 AM3/29/17
to mtex...@googlegroups.com
Hello Shao
in your first intent, the (---) is shown since mtex will convert the uvw to hkl and since your phase is monoclinic, the hkl to the direction 001 will not be a low index Miller. It will actually show you the indices when you execute the line with your crystal directions which mix planes and directions (those that you call orientations). Since a vector for crystal direction can only hold either a definition by plane or direction one will need to be converted, which I think is a pretty nice feature.
Easy solution, use any program that handles your saved files and glue them together. More elaborate option, have a look how plotPDF works and you can  use plot in combination with metxFigure nextAxis etc and combine the plot manually but you have to take care of all the labeling, title etc yourself e.g.
cs=crystalSymmetry('2',[1.2, 2.3 ,1.5],[79, 78, 72]*degree)
o=orientation.rand(3,cs)
m1 = Miller(1,1,0,cs,'hkl')
m2 = Miller(1,1,0,cs,'uvw')
f=newMtexFigure
plot(o.*m1,'parent',f.gca,'upper','TR','upper')
mtexTitle([char(m1)])
f.nextAxis
plot(o.*m1,'parent',f.gca,'lower','TR','lower')
mtexTitle([char(m1)])
f.nextAxis
plot(o.*m2,'parent',f.gca,'upper','TR','upper')
mtexTitle([char(m2)])
f.nextAxis
plot(o.*m2,'parent',f.gca,'lower','TR','lower')
mtexTitle([char(m2)])
f.drawNow

I hope this helps.
Cheers,
Rüdiger
 



From: mtex...@googlegroups.com [mtex...@googlegroups.com] on behalf of Yilun Shao [ylsha...@gmail.com]
Sent: Wednesday, March 29, 2017 9:11 AM
To: MTEX
Subject: {MTEX} How to put plane and direction pole figures together?

--
If you want to reduce the number of emails you get through this forum login to https://groups.google.com/forum/?fromgroups=#!forum/mtexmail, click "My membership" and select "Don't send me email updates". You can still get emails on selected topics by staring them.
---
You received this message because you are subscribed to the Google Groups "MTEX" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mtexmail+u...@googlegroups.com.
Visit this group at https://groups.google.com/group/mtexmail.
For more options, visit https://groups.google.com/d/optout.

Rüdiger Kilian

unread,
Mar 29, 2017, 5:10:13 AM3/29/17
to mtex...@googlegroups.com
Ah, and I also fogot, in case you want to plot each pf individually, you will have to take care of the symmetry of crystal directions as well.
e.g.   
m1 = symmetrise(Miller(1,2,0,cs,'hkl'))
plot(o.*m1)

Cheers,
Rüdiger
Sent: Wednesday, March 29, 2017 9:11 AM
To: MTEX
Subject: {MTEX} How to put plane and direction pole figures together?

Ralf Hielscher

unread,
Mar 29, 2017, 11:40:49 PM3/29/17
to MTEX
Hi Yilun Shao,

in addition to Rüdigers answer. It is actually possible to combine (hkl) planes and (uvw) directions in one pole figure plot. Just combine them with curled brackets {}, i.e.,

plotPDF(o_an_1pg, {Miller(1,0,0,ebsd('Diopside').CS,'plane'), ...

               
Miller(0,1,0,ebsd('Diopside').CS,'plane'), ...

               
Miller(0,0,1,ebsd('Diopside').CS,'direction')}, 'hemisphere','lower','projection','earea','antipodal', ...
               
'npoints',1000,'markersize',2)

Ralf.

Yilun Shao

unread,
Mar 30, 2017, 1:43:50 AM3/30/17
to MTEX, ruedige...@unibas.ch
Thanks, it works.


Yilun Shao

unread,
Mar 30, 2017, 1:55:42 AM3/30/17
to MTEX
Thanks, it works too.

Here is the new scripts:

%% Pole figure Diopside
% pole figure

o_an_all = ebsd('Diopside').orientations; % All Diopside orientations
o_an_1pg = grains(grains.grainSize >= 16,'Diopside').meanOrientation; % meanOrientation = one point per grain

% Define orientations to be plotted
orientations = [Miller(1,0,0,ebsd('Diopside').CS,'plane'), ...                       (line 113)                   
                Miller(0,1,0,ebsd('Diopside').CS,'plane'), ...                              
                Miller(0,0,1,ebsd('Diopside').CS,'direction')];
               
           

figure
plotPDF(o_an_1pg, {Miller(1,0,0,ebsd('Diopside').CS,'plane'), ...                  (line120)

                                                                                                           
                Miller(0,1,0,ebsd('Diopside').CS,'plane'), ...

                Miller(0,0,1,ebsd('Diopside').CS,'direction')}, 'hemisphere','lower','projection','earea','antipodal', ...
               'npoints',1000,'markersize',2)




%% Contoured pole figures Diopside

odf_an_all = calcODF(o_an_all,'halfwidth',15*degree);
odf_an_1pg = calcODF(o_an_1pg,'halfwidth',15*degree);


figure
plotPDF(odf_an_1pg,{Miller(1,0,0,ebsd('Diopside').CS,'plane'), ...                     (line 134)

                                                                                                        
                Miller(0,1,0,ebsd('Diopside').CS,'plane'), ...

                Miller(0,0,1,ebsd('Diopside').CS,'direction')},'hemisphere','lower','projection','earea','antipodal', ...
    'colorrange',[0 3],'contourf')
colorbar

By the way, when ploting both pole figure and contoured pole figure, the command window shows the following information:
>> trl12samplepf

Warning: Miller indices are converted to hkl
> In Miller.cat at 21
  In vector3d.horzcat at 4
  In trl12samplepf at 113
Warning: Miller indices are converted to hkl
> In Miller.cat at 21
  In vector3d.horzcat at 4
  In orientation.plotPDF at 52
  In trl12samplepf at 120
Warning: Miller indices are converted to hkl
> In Miller.cat at 21
  In vector3d.horzcat at 4
  In ODF.plotPDF at 35
  In trl12samplepf at 134

I'm not sure whether it would influence the accuracy of data. Thanks.
Reply all
Reply to author
Forward
0 new messages