How to create a matrix[15*1], in which i need to change the value of particular element during simulation.

2 Ansichten (letzte 30 Tage)
How to create a matrix[15*1], in which i need to change the value of particular element during simulation.And the rest of the values should remain same.simulink approach is highly appreciable.
  1 Kommentar
Rik
Rik am 29 Jan. 2018
I have never really worked with simulink, but in Matlab itself, creating a matrix is almost trivial: A=zeros(15,1); Accessing is also something a crash course (like e.g. this one) in Matlab will teach you in the first lesson: A(i)

Melden Sie sich an, um zu kommentieren.

Akzeptierte Antwort

Birdman
Birdman am 29 Jan. 2018
The attached model should do it for you. I created a 15-element column vector and in simulation, you can change one of its element to a value that you specify. Adapt it into your problem. Hope this helps.
  4 Kommentare

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (1)

Morteza Hajitabar Firuzjaei
Morteza Hajitabar Firuzjaei am 29 Jan. 2018
see these files
Morteza Hajitabar Firuzjaei

Kategorien

Mehr zu Programming finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by