How to solve this matrix equation

조회 수: 1 (최근 30일)
Weiqing
Weiqing 2023년 2월 17일
편집: Les Beckham 2023년 2월 17일

답변 (2개)

Daniel Vieira
Daniel Vieira 2023년 2월 17일
x=A\b
where A is the matrix and b is the left-hand vector. notice that, since this is not a square matrix, the solution is not exact, but a least-squares approximation.

Les Beckham
Les Beckham 2023년 2월 17일
편집: Les Beckham 2023년 2월 17일
Since there are more equations than unknowns, there is no unique solution. A least-squares solution can be found using the \ operator, documented here: https://www.mathworks.com/help/matlab/ref/mldivide.html
A = [ 0.23 1.77 -2.57
0.83 1.17 -3.94
1.5 0.5 -3.46
1.94 0.06 -1.37
1.17 0.83 3.94
0.06 1.94 1.37 ];
b = [48.8; 41.1; 39.8; 31.2; 46.8; 53.3];
sigma = A\b
sigma = 3×1
17.3243 26.6121 0.8502
A*sigma
ans = 6×1
48.9031 42.1657 36.3510 34.0412 45.7072 53.8317

카테고리

Help CenterFile Exchange에서 Creating and Concatenating Matrices에 대해 자세히 알아보기

태그

제품


릴리스

R2022b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by