replace initial matrix with a new one on Simulink

1 Ansicht (letzte 30 Tage)
And Cav
And Cav am 13 Nov. 2022
Kommentiert: And Cav am 16 Nov. 2022
hi, I have this problem: I am making a simulink program for attitude determination, in the first step I use an initial matrix to calculate the rotation of my vector, after this I use the vector to calculate a new matrix, now I would like to repeat the same procedure but use the new matrix found to replace the initial one and so on for the following steps. how can I do?
  1 Kommentar
And Cav
And Cav am 13 Nov. 2022
What I have is that: I start with a vector v and a matrix A0 and I compute s=A0*v, then I use s to find another matrix A1. Now I wanto ti find the new vector s using A1 instead of A0: s=A1*v. Then find A2 and use it: s=A2*v and so on. How can I do with Simulink?

Melden Sie sich an, um zu kommentieren.

Antworten (1)

Fangjun Jiang
Fangjun Jiang am 14 Nov. 2022
All you need is a "Product" block and a "Unit Delay" block. Use the "Unit Delay" block to get the value of s from previous step.
  7 Kommentare
And Cav
And Cav am 15 Nov. 2022
Thank you. I’ll look at it.
And Cav
And Cav am 16 Nov. 2022
I’m trying to use the goto block, I’ve created a Matlab function (with the matlab function block) which sets A=A0 for t=0 and uses the goto matrix for t>0. However it doesn’t work. Do you know why?

Melden Sie sich an, um zu kommentieren.

Kategorien

Mehr zu General Applications finden Sie in Help Center und File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by