Index exceeds the number of array elements (5).

2 次查看(过去 30 天)
The ecuation that i use to calculate my relative error tells me that exceeds the number of array elements.

回答(1 个)

Katalin
Katalin 2020-5-26
It is because:
ex = poly([-1 1 -2 2])
This is a vector of 5 elements and you are trying to access element 6-10 in your loop.

类别

Help CenterFile Exchange 中查找有关 Matrix Indexing 的更多信息

产品

Community Treasure Hunt

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

Start Hunting!

Translated by