フィルターのクリア

How to solve this equation

1 回表示 (過去 30 日間)
bin
bin 2012 年 3 月 26 日
Hi,everyone,there is a equation as followed:
f(x)=h0*f(x)+h1*f(x-1)+h2*f(x-2)+h3*f(x-3);
The values of the h0~h3 are given,then how to solve this equation?
thank you!
  1 件のコメント
Geoff
Geoff 2012 年 3 月 26 日
This equation looks intractably recursive. Are those f(x) terms on the right-hand side in fact supposed to be some other function/dataset, such as g(x)?

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

採用された回答

Walter Roberson
Walter Roberson 2012 年 3 月 26 日
You need three values of f(x) in order to completely solve the equation.
Or it can be expressed in terms of the known constants together with the unknown f(0), f(1), f(2)
sum(-((h0 - 1 + R .* h1 + h2 * R.^2) .* f(0) + R .* ((h0 - 1 + R .* h1) .* f(1) + R .* f(2) .* (h0 - 1))) .* (1./R)^x ./ (3 * h3 .* R.^3 + 2 * h2 .* R.^2 + R * h1)
where
R = roots([h3, h2, h1, h0-1]);
Note: all three roots of R must be included, even if imaginary!

その他の回答 (1 件)

Stefan Wehmeier
Stefan Wehmeier 2012 年 3 月 26 日
This is a recurrence equation and thus has to declared as such using rec(...).
eq = evalin(symengine, 'rec(f(x)=h0*f(x)+h1*f(x-1)+h2*f(x-2)+h3*f(x-3), f(x))');
solve(eq)

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by