-2

我有一个方程组,

constant + C.x + D.y = P 

其中CD是 25*4 矩阵。xy是 4*1 矩阵并且P是 25*1 矩阵。如何在MATLAB中求解这个方程组?

4

1 回答 1

1

You can write the equations as

 [C D] * [x ;y ] = P - constant

where [C D] is a horizontal concatenation of C and D ( 25 * 8 matrix ).
[x;y] is a vertical concatenation of x and y ( 8*1 vector )

You can solve this in Matlab using backslash operator:

 xy = [C D] \ ( P - constant ); 

 x = xy(1:4);
 y = xy(5:end);
于 2013-05-06T12:09:50.170 回答