Effacer les filtres
Effacer les filtres

Index exceeds the number of array elements. Index must not exceed 4.

7 vues (au cours des 30 derniers jours)
Batuhan Durusoy
Batuhan Durusoy le 1 Mai 2024
Commenté : Awatif ESHAIMI le 8 Juin 2024
Index exceeds the number of array elements. Index must not exceed 4. I get it in Simulink. I'm getting this error and I couldn't find a solution. Can you help me.
  1 commentaire
Walter Roberson
Walter Roberson le 1 Mai 2024
That is not a helpful message :(
Testing, I see that the problem appears to be with the Multi-Winding Transformer -- but I cannot see any problems in the configuration of that block

Connectez-vous pour commenter.

Réponses (1)

Chaitanya
Chaitanya le 6 Mai 2024
Hello Batuhan,
I understand that you are receiving the error “Index exceeds the number of array elements. Index must not exceed 4” while running the model that contains “Multi-Winding Transformer” block.
As suggested by Walter, the issue seems to be with the Multi-Winding Transformer. Upon debugging the provided model, I noticed that there is an issue with the parameters set in the block parameters.
In the block parameters of the Multi-Winding Transformer, in the parameters section, I notice that few of the parameters are not defined according to number windings defined.
In the configuration tab, the number of windings on the left side is 2 and the number of windings on the right side is 4. So, the total windings are 6. However, the following parameters set in the parameters tab are set to be an array of 4 elements. The array should contain 6 elements as there are 6 windings totally.
  • Winding nominal voltages
  • Winding resistance
  • Winding leakage inductances
I further modified these parameters to have 6 elements instead of 4 elements and I was able to run the model without any errors.
I suggest you define the parameters accordingly to rectify the error that you are receiving.
For more information on the parameters please visit the following documentation that provides details that the array must contains ‘n’ number of elements where ‘n’ is number of windings.
I hope that the above information is helpful in resolving the error.
Thanks,
Chaitanya Krishna
  1 commentaire
Awatif ESHAIMI
Awatif ESHAIMI le 8 Juin 2024
I got the same error, and thank's to your comment I found the solution, thank you !

Connectez-vous pour commenter.

Catégories

En savoir plus sur Simulink Functions 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