"Index exceeds matrix dimensions"-error Simulink
Mostrar comentarios más antiguos
Hello,
I created a three phase grid as an Simulink model.
After adding 3-phase voltage source blocks and starting the simulation I get this error: "Index exceeds matrix dimensions"
I am using Matlab version 2017a and tried to get more detailed information about the error using: set_param(gcs,'SimulationCommand','update');
But I didnt get any new informations about the error
Can someone help me solving this problem?
Respuestas (3)
Davide De Cicco
el 6 de Ag. de 2017
0 votos
Hi Michael,
The error simply means that you are trying to execute an operation that wants to access a cell of an array (could be matrix, vector ...) which dimensions do not correspond to what you are trying to access. For instance, you get that error if you have a 3x3 matrix and ask for the element (4,3). It's a quite common error if you are using loops.
3 comentarios
Walter Roberson
el 6 de Ag. de 2017
However it is not common in Simulink unless you are using a MATLAB Function Block or have set initialisation conditions for a block to refer to a signal at a location that does not exist.
Michael Kelker
el 7 de Ag. de 2017
Jaleel Pasha
el 18 de Feb. de 2020
hey, have u rectified error.. am also geeting that error(i have not used a single line)
Michael Kelker
el 7 de Ag. de 2017
0 votos
2 comentarios
Magnus Ekløff
el 19 de Jun. de 2018
How did you locate the blocks which generated the error?
jonatan blom
el 15 de Feb. de 2019
0 votos
Hi,
I have also experienced this error when a model contains a s-function builder block that has not been built. Build the s-function and the error disappears, utterly strange error message...
/Jonatan
Categorías
Más información sobre General Applications en Centro de ayuda y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!