Skip to content
Snippets Groups Projects
gtCrystGetSigmas.m 3.22 KiB
Newer Older
function sigmas = gtCrystGetSigmas(crystal_system, latticepar, convention)
% GTCRYSTGETSIGMAS  Calculates CSL sigmas values for cubic and hexagonal crystal
%     sigmas = gtCrystGetSigmas(crystal_system, latticepar, [convention])
%     -------------------------------------------------------------------
%     INPUT:
%       crystal_system = 
%       latticepar     = 
%       convention     = <string>   hcp axes convention {'X'}|'Y'

if ~exist('latticepar','var') || isempty(latticepar)
    parameters = [];
    load('parameters.mat');
    latticepar = parameters.cryst.latticepar;
    clear parameters
end
if ~exist('convention','var') || isempty(convention)
    convention = 'X';
end

if strcmpi(crystal_system, 'cubic')

    %sigma s: type, angle, axis cart, brandon criteria {, rodrigues}
    sigmas = [ 3 60    1 1 1 0 0.333 0.333 0.333; ...
               5 36.86 1 0 0 0 0.333 0     0; ...
               7 38.21 1 1 1 0 0.199 0.199 0.199; ...
               9 38.94 1 1 0 0 0.25  0.25  0; ...
              11 50.47 1 1 0 0 0.333 0.333 0; ...
              13 22.62 1 0 0 0 0.2   0     0; ...
              13 27.79 1 1 1 0 0.143 0.143 0.143];
    %add brandon criteria
    sigmas(:, 6) = 15 * sigmas(:, 1) .^ (-0.5);
    sigmaNorms = sqrt(sum(sigmas(:, 3:5) .* sigmas(:, 3:5), 2));
    %normalise axis
    sigmas(:, 3:5) = sigmas(:, 3:5) ./ sigmaNorms(:, [1 1 1]);

elseif strcmpi(crystal_system, 'hexagonal')
    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    % added on 2013-10-09 by LNervo
    % R. Bonnet, E. Cousineau, D.H. Warrington (1981) "Determination of
    %     near-coincident cells for hexagonal crystals. Related  DSC
    %     lattices" Acta Crystallographica, A37, 184-189
    % Bozzolo et al. (2010) "Misorientations induced by deformation
    %     tiwnning in titanium" J. Appl. Cryst. 43, 596-602
    % CSL values for HCP; cartesian axis in Y-convention originally

    % sigma for hcp s: type, angle, axis hex, brandon criteria, axis cart
    sigmas = [  7 21.8   0  0  0  1   0  0 0 1; ... %7a
                7 64.6   1  0 -1  0   0  1 0 0; ... %7b
               11 35.1   1  0 -1  0   0  1 0 0; ... %11a
               11 84.8   2 -1 -1  0   0  0 1 0; ... %11b
               13 27.8   0  0  0  1   0  0 0 1; ... %13a
               13 57.4   2 -1 -1  0   0  0 1 0; ... %13b
               13 76.7   1  0 -1  0   0  1 0 0; ... %13c
               17 40.1   2 -1 -1  0   0  0 1 0; ... %17a NO Ti
               17 79.8   3 -1 -2  0   0  0 0 0; ... %17b NONE
               19 13.2   0  0  0  1   0  0 0 1; ... %19a
               19 65.1  10 -5 -5  3   0  0 0 0; ... %19b
               19 87.0   1  0 -1  0   0  1 0 0; ... %19c
               23 55.6   1  0 -1  0   0  1 0 0; ... %23a NONE
               23 72.3   2 -1 -1  0   0  0 1 0; ... %23b NO Ti
               23 86.3  10  0 -10 3   0  0 0 0; ... %23c NONE
               ];


    if strcmpi(convention, 'X')
        sigmas(:, 8:10) = gtHex2Cart(sigmas(:, 3:6), latticepar, convention);
    end

    %add brandon criteria: is it also for hcp? (laura)
    sigmas(:, 7) = 15 * sigmas(:, 1) .^ (-0.5);
    sigmaNorms = sqrt(sum(sigmas(:, 8:10) .* sigmas(:, 8:10), 2));
    %normalise axis
    sigmas(:, 8:10) = sigmas(:, 8:10) ./ sigmaNorms(:, [1 1 1]);
end

end % end of function