Generating for loop for toeplitz for Q order analysis.

b = toeplitz(x,[x(1) zeros(1,Q)])\y;
I have a toeplitz matrix that I want to write a loop for Q=(1:150).
any ideas?

1 件のコメント

Andrei Bobrov
Andrei Bobrov 2013 年 2 月 20 日
編集済み: Andrei Bobrov 2013 年 2 月 20 日
That such x, y.

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

回答 (1 件)

Andrei Bobrov
Andrei Bobrov 2013 年 2 月 20 日
編集済み: Andrei Bobrov 2013 年 2 月 20 日

0 投票

b{150} = toeplitz(x,[x(1) zeros(1,150)])\y; % THAT SUCH x, y
for jj = 1:150
b{jj} = b{end}(:,1:jj);
end

1 件のコメント

moejobe
moejobe 2013 年 2 月 20 日
First of all, Thank you for your response Andrei. I'm getting an error msg, 'Cell contents assignment to a non-cell array object.' When I put your code in. I'm not sure exactly what you did.
Maybe it will be more helpful if I clear up my question a bit more. Basically, I have two discrete signals, x %input and y %output, and I'm trying to filter the signal using moving average method y=xb. And in order to solve the convolution, I need to find a value of Q order that will give the least error.

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

カテゴリ

ヘルプ センター および File ExchangeLoops and Conditional Statements についてさらに検索

質問済み:

2013 年 2 月 20 日

Community Treasure Hunt

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

Start Hunting!

Translated by