Planarity test across a cubic-to-tetragonal twin (source code)

= Planarity test across a cubic-to-tetragonal twin
{title2=$p=(p_1,p_2,0),\quad\Pi=p^\perp\text{ remains plane}\iff p\parallel N$}

Let $B=\operatorname{diag}(b,a,a)$, with $a,b>0$, $a\ne b$, and $A=R\operatorname{diag}(a,b,a)$ be a twin-related gradient with $\cos\theta=2ab/(a^2+b^2)$, $\sin\theta=\kappa(b^2-a^2)/(a^2+b^2)$, $\kappa=\pm1$. Their jump is $(b^2-a^2)(-b,\kappa a,0)\otimes(1,\kappa,0)/(a^2+b^2)$.

A plane through the origin with normal $p=(p_1,p_2,0)$ is spanned by $e_3$ and $t=(-p_2,p_1,0)$. Both gradients map $e_3$ to the same direction, so the two image half-planes are coplanar exactly when $At$ and $Bt$ are parallel in their transverse section. Direct calculation gives
$$
\det_2(Bt,At)=\frac{\kappa ab(b^2-a^2)}{a^2+b^2}(p_1-\kappa p_2)^2.
$$
Its nonzero prefactor makes planarity equivalent to $p\parallel(1,\kappa,0)$, the twin normal. On that plane the two affine maps agree, proving sufficiency as well. The restriction on the third normal component matters; this statement is not a classification of every possible material plane.