calcVariantId edit page

compute variantIds and packetId from parent / child orientation pairs

Syntax

variantId = calcVariantId(parentOri,childOri,p2c)
% compute packetIds
[variantId,packetId] = calcVariantId(parentOri,childOri,p2c,...
  {hklParent,hklChild})
% packet determination
hklParent = Miller({1,1,1},{1,-1,1},{-1,1,1},{1,1,-1},p2c.CS);
hklChild  = Miller(1,0,1,p2c.SS);
[variantId,packetId] = calcVariantId(parentOri,childOri,p2c,...
  {hklParent,hklChild})

Input

parentOri parent orientation
childOri child orientation
p2c parent to child misorientation
hklParent, hklChild correspondent planes between parent and child

Output

variantId variant id
packetId packet id