You seem to want some SO(3) group parametrization in Mathematica I think. You will only have 3 independent symbols (variables), since you have 6 constraints from mutual orthogonality of vectors and the norms equal to 1. One way is to construct independent rotations around the 3 axes, and multiply those matrices. Here is the (perhaps too complex) code to do that:
{{ b^2 + (a^2 + c^2) Cos[t] , b c (1 - Cos[t]) + a t Sin[t], a b (1 - Cos[t]) - c t Sin[t]},
{b c (1 - Cos[t]) - a t Sin[t], c^2 + (a^2 + b^2) Cos[t] , a c (1 - Cos[t]) + b t Sin[t]},
{a b (1 - Cos[t]) + c t Sin[t], a c (1 - Cos[t]) - b t Sin[t], a^2 + (b^2 + c^2) Cos[t]}} / t^2
Marcellus, you have to use some parametrization of SO(3), since your general matrix has to reflect the RP3 topology of the group. No single parametrization will cover the whole group without either multivaluedness or singular points. Wikipedia has a nice page about the various charts on SO(3).
Maybe one of the conceptually simplest is the exponential map from the Lie algebra so(3). Define an antisymmetric, real A (which spans so(3))
A = {{0, a, -c},
{-a, 0, b},
{c, -b, 0}};
Then MatrixExp[A] is an element of SO(3). We can check that this is so, using
If we write t^2 = a^2 + b^2 + c^2, we can simplify the matrix exponential down to
{{ b^2 + (a^2 + c^2) Cos[t] , b c (1 - Cos[t]) + a t Sin[t], a b (1 - Cos[t]) - c t Sin[t]},
{b c (1 - Cos[t]) - a t Sin[t], c^2 + (a^2 + b^2) Cos[t] , a c (1 - Cos[t]) + b t Sin[t]},
{a b (1 - Cos[t]) + c t Sin[t], a c (1 - Cos[t]) - b t Sin[t], a^2 + (b^2 + c^2) Cos[t]}} / t^2
Note that this is basically the same parametrization as RotationMatrix gives. Compare with the output from
Although I really like the idea of Marcellus' answer to his own question, it's not completely correct. Unfortunately, the conditions he arrives at also result in
Simplify[Transpose[mat] - mat]
evaluating to a zero matrix! This is clearly not right. Here's an approach that's both correct and more direct:
发布评论
评论(5)
并不是我推荐这个,但是......
所以 q2 是一个符号正交矩阵(假设我们处理实数)。
Not that I recommend this, but...
So q2 is a symbolic orthogonal matrix (assuming we work over reals).
我认为您似乎想要在 Mathematica 中进行一些
SO(3)
组参数化。您将只有 3 个独立的符号(变量),因为矢量相互正交有 6 个约束,并且范数等于 1。一种方法是围绕 3 个轴构建独立旋转,并将这些矩阵相乘。下面是执行此操作的代码(可能太复杂):这是其工作原理:
您可以通过对各个列(或行)点积使用
Simplify
来检查矩阵是否正交。You seem to want some
SO(3)
group parametrization in Mathematica I think. You will only have 3 independent symbols (variables), since you have 6 constraints from mutual orthogonality of vectors and the norms equal to 1. One way is to construct independent rotations around the 3 axes, and multiply those matrices. Here is the (perhaps too complex) code to do that:Here is how this works:
You can check that the matrix is orthonormal, by using
Simplify
over the various column (or row) dot products.我找到了一种“直接”的方式来强加特殊的正交性。
见下文。
然后
给出 1;...并
给出单位矩阵;
...最终
给出一个零矩阵。
=================================================== ======================
这就是我问问题时正在寻找的!
不过,请让我知道您对此方法的想法。
马塞勒斯
I have found a "direct" way to impose special orthogonality.
See below.
Then
gives 1;...and
gives the identity matrix;
...finally
gives a Zero matrix.
========================================================================
This is what I was looking for when I asked my question!
However, let me know your thought on this method.
Marcellus
Marcellus,您必须使用 SO(3) 的一些参数化,因为您的通用矩阵必须反映 < strong>RP3组拓扑。如果没有多值性或奇异点,任何单一参数化都无法覆盖整个组。维基百科有一个关于 SO(3) 上的各种图表的精彩页面。
也许概念上最简单的之一是李代数的指数映射 so(3)。
定义一个反对称的实
A
(跨越 so(3)),则
MatrixExp[A]
是SO(3)
的一个元素。我们可以检查是否如此,使用
如果我们写
t^2 = a^2 + b^2 + c^2
,我们可以将矩阵指数简化为注意,这基本上是相同的参数化为 RotationMatrix 给出。
与输出进行比较
Marcellus, you have to use some parametrization of SO(3), since your general matrix has to reflect the RP3 topology of the group. No single parametrization will cover the whole group without either multivaluedness or singular points. Wikipedia has a nice page about the various charts on SO(3).
Maybe one of the conceptually simplest is the exponential map from the Lie algebra so(3).
Define an antisymmetric, real
A
(which spans so(3))Then
MatrixExp[A]
is an element ofSO(3)
.We can check that this is so, using
If we write
t^2 = a^2 + b^2 + c^2
, we can simplify the matrix exponential down toNote that this is basically the same parametrization as RotationMatrix gives.
Compare with the output from
虽然我真的很喜欢马塞勒斯对自己问题的回答,但这并不完全正确。不幸的是,他所达到的条件也导致
评估为零矩阵!这显然是不对的。这里有一个既正确又更直接的方法:
即将旋转矩阵乘以其转置结果得到单位矩阵,并且旋转矩阵的行列式是1。
Although I really like the idea of Marcellus' answer to his own question, it's not completely correct. Unfortunately, the conditions he arrives at also result in
evaluating to a zero matrix! This is clearly not right. Here's an approach that's both correct and more direct:
i.e. multiplying a rotation matrix by its transpose results in the identity matrix, and the determinant of a rotation matrix is 1.