mtex icon indicating copy to clipboard operation
mtex copied to clipboard

contoured polefigures: odf vs orientation

Open kilir opened this issue 8 years ago • 4 comments

Hallo Ralf, I found a difference in the symmetry in pole figure plots depending whether they are plotted from an odf or the orientations. Despite there should be some minor differences because contouring either happens in the odf or on the sphere, I cannot explain the differences that can be seen for (11-20). All other poles seem to behave quite normal. I cannot reproduce this behavior when simulating data from an odf. These are the points corresponding to o:

o = orientation (show methods, plot)
  size: 163838 x 1
  crystal symmetry : Quartz (321, X||a*, Y||b, Z||c)
  specimen symmetry: 1

plotPDF(o,hs(1:4),'points',1500,3)

points

This is the polefigure which comes from an odf:

odf=calcODF(o,'halfwidth',5*degree)
plotPDF(odf,hs(1:4),'contourf')

contourf_odf

And these are the contoured points:

plotPDF(o,hs(1:4),'contourf','halfwidth',5*degree)

contourf_o

So what I see, is that (11-20) is quite different. Could that be correct?

All the best, Rüdiger

kilir avatar Apr 08 '16 15:04 kilir

Hi Rüdiger,

could you send those orientations?

Ralf.

ralfHielscher avatar Apr 20 '16 12:04 ralfHielscher

Hi Ralf, I sent those orientations to your mail, code to reproduce after loading:

load('o_mtex_issue.mat')
m = Miller(1,1,-2,0,cs)
odf = calcODF(o,'halfwidth',5*degree)
figure
plotPDF(odf,m,'contourf')

figure
plotPDF(o,m,'contourf','halfwidth',5*degree)

All the best, Rüdiger

kilir avatar Apr 20 '16 22:04 kilir

Hi Rüdiger,

thank you for reporting this deep and serious bug. It seems to be in SO3Grid/find which is called by calcODF and is related to trigonal symmetry.

A workaround may be

odf = calcODF(o,'exact')

should give the correct result. Note that in the incorrect case only the upper and lower hemisphere of the pole figure are swapped.

Ralf.

ralfHielscher avatar Apr 21 '16 04:04 ralfHielscher

Hello Ralf, yes, I can confirm, with 'exact' it does not occur. Do you have any idea since when this bug was introduced? Cheers, Rüdiger

kilir avatar Apr 21 '16 05:04 kilir