I want to interpolate within a matrix but can't do it.

1 回表示 (過去 30 日間)
Ede gerlderlands
Ede gerlderlands 2012 年 10 月 20 日
I have a matrix of SS(20x40x26) which contains values of (velocity) which are position based on depth(20 normal depths) width(40 normalized widths) and 26(time steps) I want to find the velocity for some single depth c(1,40,26) with different normalized values.
here is the code which I work upon and failed so fsr
for jj = length(time)
SSnew = interp1( (:,:,jj), SS , C(1,:,jj));
end
Thanks in advance
  1 件のコメント
Matt J
Matt J 2012 年 10 月 20 日
Note, the interp1 syntax you're using might be removed in future releases

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

採用された回答

Matt J
Matt J 2012 年 10 月 20 日
編集済み: Matt J 2012 年 10 月 20 日
The first input argument you have to interp1 is an index expression with no variable.
interp1((:,:,jj),...);
Should it not be something like
interp1(cvalues(:,:,jj),...);
  1 件のコメント
Ede gerlderlands
Ede gerlderlands 2012 年 10 月 20 日
yes, it has to be thanks. I think I can do something with it,

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

その他の回答 (0 件)

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by