Effacer les filtres
Effacer les filtres

Index exceeds the number of array elements (5).

1 vue (au cours des 30 derniers jours)
Michel Lopes Villaluz
Michel Lopes Villaluz le 25 Mai 2020
Commenté : darova le 26 Mai 2020
The ecuation that i use to calculate my relative error tells me that exceeds the number of array elements.

Réponses (1)

Katalin
Katalin le 26 Mai 2020
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.

Catégories

En savoir plus sur Matrix Indexing dans Help Center et File Exchange

Produits

Community Treasure Hunt

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

Start Hunting!

Translated by