Error using matlab.internal.math.interp1 The sample points must be finite.
古いコメントを表示
when I ran a script,
for i=1:sz(2)
tOut(:,i) = interp1(x(:,i),v(:,i),xq(:,i));
end
I got those errors
Error using matlab.internal.math.interp1
The sample points must be finite.
Error in interp1 (line 188)
VqLite = matlab.internal.math.interp1(X,V,method,method,Xqcol);
Error in coolprop_tab.MoistAir.calcMoistHeatCool (line 782)
tOut(:,i) = interp1(x(:,i),v(:,i),xq(:,i));
4 件のコメント
KSSV
2022 年 4 月 22 日
Attach your data x, v and xq. It seems there is a problem with the data.
huiting wang
2022 年 4 月 22 日
編集済み: Walter Roberson
2022 年 4 月 22 日
huiting wang
2022 年 4 月 22 日
huiting wang
2022 年 4 月 26 日
採用された回答
その他の回答 (1 件)
huiting wang
2022 年 4 月 27 日
0 投票
2 件のコメント
凡奇
2022 年 11 月 12 日
I‘m also getting the same error, but I don't know how to solve it.......
Bob photonics
2025 年 2 月 14 日
Use this code to look for NaN/Inf values in your matrix/array/table
~isfinite(YourMatrix) %if it shows a logical 1 then you've a NaN/Inf value
[row, col] = find(~isfinite(YourMatrix)) % will show you all the locations where you have NaN values
カテゴリ
ヘルプ センター および File Exchange で Interpolation についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!