如下拷贝的百度百科
西尔维斯特方程(Sylvester equation)是控制理论中的矩阵方程,形式如下:
A
X
+
X
B
=
C
AX+XB=C
AX+XB=C
其中A、B及C是已知的矩阵,问题是要找出符合条件的X。其中所有矩阵的系数都是复数。
为了要使上述方程成立,矩阵的行和列需要满足一定条件,A和B都要是方阵,大小分别是n和m,而X和C要是n行m列的矩阵,n和m也可以相等,四个矩阵都是大小相同的方阵。
西尔维斯特方程有唯一解X的充分必要条件是A和-B没有共同的特征值。
A
X
+
X
B
=
[
a
1
a
2
a
3
a
4
]
[
x
1
x
2
x
3
x
4
]
+
[
x
1
x
2
x
3
x
4
]
[
b
1
b
2
b
3
b
4
]
=
[
(
a
1
+
b
1
)
x
1
+
b
3
x
2
+
a
2
x
3
+
0
x
4
b
2
x
1
+
(
a
1
+
b
4
)
x
2
+
0
x
3
+
a
2
x
4
a
3
x
1
+
0
x
2
+
(
a
4
+
b
1
)
x
3
+
b
3
x
4
0
x
1
+
a
3
x
2
+
b
2
x
3
+
(
a
4
+
b
4
)
x
4
]
=
[
c
1
c
2
c
3
c
4
]
AX+XB=\begin{bmatrix} a_1 & a_2\\ a_3 & a_4 \end{bmatrix}\begin{bmatrix} x_1 & x_2\\ x_3 & x_4 \end{bmatrix}+\begin{bmatrix} x_1 & x_2\\ x_3 & x_4 \end{bmatrix}\begin{bmatrix} b_1 & b_2\\ b_3 & b_4 \end{bmatrix}\\ =\begin{bmatrix} (a_1+b_1)x_1+b_3x_2+a_2x_3+0x_4 & b_2x_1+(a_1+b_4)x_2+0x_3+a_2x_4\\ a_3x_1+0x_2+(a_4+b_1)x_3+b_3x_4 & 0x_1+a_3x_2+b_2x_3+(a_4+b_4)x_4 \end{bmatrix} =\begin{bmatrix} c_1 & c_2\\ c_3 & c_4 \end{bmatrix}
AX+XB=[a1?a3??a2?a4??][x1?x3??x2?x4??]+[x1?x3??x2?x4??][b1?b3??b2?b4??]=[(a1?+b1?)x1?+b3?x2?+a2?x3?+0x4?a3?x1?+0x2?+(a4?+b1?)x3?+b3?x4??b2?x1?+(a1?+b4?)x2?+0x3?+a2?x4?0x1?+a3?x2?+b2?x3?+(a4?+b4?)x4??]=[c1?c3??c2?c4??]
将以上算式推导中的C矩阵如下展开:
[
c
1
c
2
c
3
c
4
]
?
[
c
1
c
2
c
3
c
4
]
\begin{bmatrix} c_1 & c_2\\ c_3 & c_4 \end{bmatrix}\Rightarrow\begin{bmatrix} c_1\\ c_2\\ c_3\\ c_4 \end{bmatrix}
[c1?c3??c2?c4??]?
?c1?c2?c3?c4??
?
则以上算式推导,可演变为如下形式:
[
a
1
+
b
1
b
3
a
2
0
b
2
a
1
+
b
4
0
a
2
a
3
0
a
4
+
b
1
b
3
0
a
3
b
2
a
4
+
b
4
]
[
x
1
x
2
x
3
x
4
]
=
[
c
1
c
2
c
3
c
4
]
\begin{bmatrix} a_1+b_1 & b_3 & a_2 & 0\\ b_2 & a_1+b_4 & 0 & a_2\\ a_3 & 0 & a_4+b_1& b_3\\ 0 & a_3 & b_2 & a_4+b_4 \end{bmatrix}\begin{bmatrix} x_1\\ x_2\\ x_3\\ x_4 \end{bmatrix}=\begin{bmatrix} c_1\\ c_2\\ c_3\\ c_4 \end{bmatrix}
?a1?+b1?b2?a3?0?b3?a1?+b4?0a3??a2?0a4?+b1?b2??0a2?b3?a4?+b4??
?
?x1?x2?x3?x4??
?=
?c1?c2?c3?c4??
?
( I ? A + B T ? I ) v e c ( X ) = v e c ( C ) (I\bigotimes A + B^T\bigotimes I)vec(X) = vec(C) (I?A+BT?I)vec(X)=vec(C)
( I ? A + B T ? I ) v e c ( X ) = ( [ 1 0 0 1 ] ? [ a 1 a 2 a 3 a 4 ] + [ b 1 b 3 b 2 b 4 ] ? [ 1 0 0 1 ] ) v e c ( X ) = ( [ a 1 a 2 0 0 a 3 a 4 0 0 0 0 a 1 a 2 0 0 a 3 a 4 ] + [ b 1 0 b 3 0 0 b 1 0 b 3 b 2 0 b 4 0 0 b 2 0 b 4 ] ) [ x 1 x 2 x 3 x 4 ] = [ a 1 + b 1 a 2 b 3 0 a 3 a 4 + b 1 0 b 3 b 2 0 a 1 + b 4 a 2 0 b 2 a 3 a 4 + b 4 ] [ x 1 x 2 x 3 x 4 ] (I \bigotimes A + B^T \bigotimes I )vec(X)= (\begin{bmatrix} 1 & 0\\ 0 & 1 \end{bmatrix} \bigotimes \begin{bmatrix} a_1 & a_2\\ a_3 & a_4 \end{bmatrix}+ \begin{bmatrix} b_1 & b_3\\ b_2 & b_4 \end{bmatrix} \bigotimes \begin{bmatrix} 1 & 0\\ 0 & 1 \end{bmatrix})vec(X) \\ =(\begin{bmatrix} a_1 & a_2 & 0 & 0\\ a_3 & a_4 & 0 & 0\\ 0 & 0 & a_1& a_2\\ 0 & 0 & a_3 & a_4 \end{bmatrix} + \begin{bmatrix} b_1 & 0 & b_3 & 0\\ 0 & b_1 & 0 & b_3\\ b_2 & 0 & b_4& 0\\ 0 & b_2 & 0 & b_4 \end{bmatrix}) \begin{bmatrix} x_1\\ x_2\\ x_3\\ x_4 \end{bmatrix} \\ =\begin{bmatrix} a_1+b_1 & a_2 & b_3 & 0\\ a_3 & a_4+b_1 & 0 & b_3\\ b_2 & 0 & a_1+b_4& a_2\\ 0 & b_2 & a_3 & a_4+b_4 \end{bmatrix}\begin{bmatrix} x_1\\ x_2\\ x_3\\ x_4 \end{bmatrix} (I?A+BT?I)vec(X)=([10?01?]?[a1?a3??a2?a4??]+[b1?b2??b3?b4??]?[10?01?])vec(X)=( ?a1?a3?00?a2?a4?00?00a1?a3??00a2?a4?? ?+ ?b1?0b2?0?0b1?0b2??b3?0b4?0?0b3?0b4?? ?) ?x1?x2?x3?x4?? ?= ?a1?+b1?a3?b2?0?a2?a4?+b1?0b2??b3?0a1?+b4?a3??0b3?a2?a4?+b4?? ? ?x1?x2?x3?x4?? ?
最后矩阵计算形式变为
[
a
1
+
b
1
a
2
b
3
0
a
3
a
4
+
b
1
0
b
3
b
2
0
a
1
+
b
4
a
2
0
b
2
a
3
a
4
+
b
4
]
[
x
1
x
2
x
3
x
4
]
=
[
c
1
c
2
c
3
c
4
]
\begin{bmatrix} a_1+b_1 & a_2 & b_3 & 0\\ a_3 & a_4+b_1 & 0 & b_3\\ b_2 & 0 & a_1+b_4& a_2\\ 0 & b_2 & a_3 & a_4+b_4 \end{bmatrix}\begin{bmatrix} x_1\\ x_2\\ x_3\\ x_4 \end{bmatrix}=\begin{bmatrix} c_1\\ c_2\\ c_3\\ c_4 \end{bmatrix}
?a1?+b1?a3?b2?0?a2?a4?+b1?0b2??b3?0a1?+b4?a3??0b3?a2?a4?+b4??
?
?x1?x2?x3?x4??
?=
?c1?c2?c3?c4??
?
和1.1章节正常矩阵展开,相比较,可以看出:
官方求解形式是错误的!!!
Nicolas Andreff作者在文章《On-line Hand-Eye Calibration》中提到Sylvester方程,修改为线性系统方程,也是错误的。具体形式如下:
( A ? I + I ? B T ) v e c ( X ) = v e c ( C ) (A\bigotimes I + I\bigotimes B^T)vec(X) = vec(C) (A?I+I?BT)vec(X)=vec(C)
(
A
?
I
+
I
?
B
T
)
v
e
c
(
X
)
=
(
[
a
1
a
2
a
3
a
4
]
?
[
1
0
0
1
]
+
[
1
0
0
1
]
?
[
b
1
b
3
b
2
b
4
]
)
v
e
c
(
X
)
=
(
[
a
1
0
a
2
0
0
a
1
0
a
2
a
3
0
a
4
0
0
a
3
0
a
4
]
+
[
b
1
b
3
0
0
b
2
b
4
0
0
0
0
b
1
b
3
0
0
b
2
b
4
]
)
[
x
1
x
2
x
3
x
4
]
=
[
a
1
+
b
1
b
3
a
2
0
b
2
a
1
+
b
4
0
a
2
a
3
0
a
4
+
b
1
b
3
0
a
3
b
2
a
4
+
b
4
]
[
x
1
x
2
x
3
x
4
]
=
[
c
1
c
2
c
3
c
4
]
(A\bigotimes I + I\bigotimes B^T)vec(X)= (\begin{bmatrix} a_1 & a_2\\ a_3 & a_4 \end{bmatrix} \bigotimes \begin{bmatrix} 1 & 0\\ 0 & 1 \end{bmatrix}+ \begin{bmatrix} 1 & 0\\ 0 & 1 \end{bmatrix} \bigotimes \begin{bmatrix} b_1 & b_3\\ b_2 & b_4 \end{bmatrix})vec(X) \\ =(\begin{bmatrix} a_1 & 0 & a_2 & 0\\ 0 & a_1 & 0 & a_2\\ a_3 & 0 & a_4& 0\\ 0 & a_3 & 0 & a_4 \end{bmatrix} + \begin{bmatrix} b_1 & b_3 & 0 & 0\\ b_2 & b_4 & 0 & 0\\ 0 & 0 & b_1& b_3\\ 0 & 0 & b_2 & b_4 \end{bmatrix}) \begin{bmatrix} x_1\\ x_2\\ x_3\\ x_4 \end{bmatrix} \\ =\begin{bmatrix} a_1+b_1 & b_3 & a_2 & 0\\ b_2 & a_1+b_4 & 0 & a_2\\ a_3 & 0 & a_4+b_1& b_3\\ 0 & a_3 & b_2 & a_4+b_4 \end{bmatrix}\begin{bmatrix} x_1\\ x_2\\ x_3\\ x_4 \end{bmatrix}=\begin{bmatrix} c_1\\ c_2\\ c_3\\ c_4 \end{bmatrix}
(A?I+I?BT)vec(X)=([a1?a3??a2?a4??]?[10?01?]+[10?01?]?[b1?b2??b3?b4??])vec(X)=(
?a1?0a3?0?0a1?0a3??a2?0a4?0?0a2?0a4??
?+
?b1?b2?00?b3?b4?00?00b1?b2??00b3?b4??
?)
?x1?x2?x3?x4??
?=
?a1?+b1?b2?a3?0?b3?a1?+b4?0a3??a2?0a4?+b1?b2??0a2?b3?a4?+b4??
?
?x1?x2?x3?x4??
?=
?c1?c2?c3?c4??
?
和1.1章节的最后结果是一致的。