What is the formula of left devision?

1 回表示 (過去 30 日間)
Jing Lin Ng
Jing Lin Ng 2014 年 3 月 15 日
編集済み: dpb 2014 年 3 月 15 日
When I key in
a=[1 2 4];b=[2 4 7]; >> z=a'\b'
then i get this value z =
1.8095
may i know what is the formula to get this value? Thanks.

採用された回答

dpb
dpb 2014 年 3 月 15 日
doc mldivide % and follow links therein
  2 件のコメント
Jing Lin Ng
Jing Lin Ng 2014 年 3 月 15 日
hi I do go through doc mldivide. but I do not know how to get the answer manually. I do not understand the formula behind this equation. do you know about this formula?
dpb
dpb 2014 年 3 月 15 日
編集済み: dpb 2014 年 3 月 15 日
It's solution to a*z=b which is a least-squares problem formulation w/o an intercept. Matlab has a number of different ways to actually solve the system depending on the analyzed characteristics of a. These are discussed in the previous links. Seems like there's some more discussion in Cleve's Corner from the past. Possibly a search at mathworks.com could uncover a little more in depth but the actual algorithms are proprietary.
Try
a*z
from command line and see what you get.
Or,
regress(b',a')
ans =
1.8095
if you have the Statistics Toolbox for another way to fit the model. Or, you should be able to write the least squares equations and solve analytically for this small a system.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeLinear Algebra についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by