Skip to content

Commit

Permalink
Merge pull request #68 from ralfHielscher/master
Browse files Browse the repository at this point in the history
mtex 4.0.22
  • Loading branch information
ralfHielscher committed May 20, 2015
2 parents 363ff57 + 2d6e73f commit 3f7d908
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 15 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ clean:


# rule for making release
RNAME = mtex-4.0.21
RNAME = mtex-4.0.22
RDIR = ../releases
release:
rm -rf $(RDIR)/$(RNAME)*
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
MTEX 4.0.21
MTEX 4.0.22
23 changes: 13 additions & 10 deletions geometry/@orientation/axis.m
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,17 @@
% See also
% orientation/angle

if nargin == 2

if nargin == 1

% project to Fundamental region to get the axis with the smallest angle
o1 = project2FundamentalRegion(o1);
a = axis@quaternion(o1);

% add symmetry to axis
if isa(o1.SS,'crystalSymmetry'), a = Miller(a,o1.SS); end

else

[l,d,r] = factor(o1.CS,o2.CS);
l = l * d;
Expand Down Expand Up @@ -61,15 +71,8 @@
q = reshape(inv(r(irMax)),size(q21)) .* q21 .* reshape(l(ilMax),size(q21));

% now the misorientation axis is given by in specimen coordinates is
% given by l(il) * q.axis or equivalently by
a = r(irMax) .* q.axis;
% given by o2 * l(il) * q.axis or equivalently by
a = q2 .* r(irMax) .* axis@quaternion(q);

return
end

% project to Fundamental region to get the axis with the smallest angle
o1 = project2FundamentalRegion(o1);
a = axis@quaternion(o1);

% add symmetry to axis
if isa(o1.SS,'crystalSymmetry') > 1, a = Miller(a,o1.SS); end
5 changes: 3 additions & 2 deletions geometry/@sphericalRegion/char.m
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
function s = char(sR)
% convert spherical region to char

switch length(length(sR.N))
switch length(sR.N)
case 0
s = 'full sphere';
case 1
Expand All @@ -10,7 +10,8 @@
else
s = 'lower hemisphere';
end
case 2
otherwise
s = 'sector';
end

end
1 change: 1 addition & 0 deletions tools/orientationMappings/HSVOrientationMapping.m
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,7 @@ function updateColorPostRotation(oM)

function rgb = h2color(oM,h,varargin)

h.antipodal = false;
h = h.project2FundamentalRegion(oM.CS1);
whiteCenter = oM.whiteCenter.project2FundamentalRegion(oM.CS1); %#ok<*PROP>
switchWB = false;
Expand Down
2 changes: 1 addition & 1 deletion tools/orientationMappings/ipdfOrientationMapping.m
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ function plot(oM,varargin)
else
defaultPlotCMD = 'pcolor';
end
plot(h,d,defaultPlotCMD,'parent',mtexFig.gca,varargin{:});
plot(h,d,defaultPlotCMD,varargin{:});
if ~check_option(varargin,'noTitle')
tt = mtexTitle(mtexFig.gca,char(oM(1).inversePoleFigureDirection));
set(tt,'string',['IPF ' get(tt,'string')]);
Expand Down

0 comments on commit 3f7d908

Please sign in to comment.