How to create a vector?

I have as an output in my simulink model a matrix a time vector.
Matrix
1 7 13 19 25 31
2 8 14 20 26 32
3 9 15 21 27 33
4 10 16 22 28 34
5 11 17 23 29 35
6 12 18 24 30 36
time vector = 0.02 0.04 0.06 0.08 0.10 0.12 0.14 0.16 0.18 0.20 0.22 0.24 0.26 0.28 0.30 0.32 0.34 0.36 0.38 0.40 0.42 0.44 0.460 0.48 0.50 0.52 0.54 0.56 0.58 0.60 0.62 0.64 0.66 0.68 0.70 0.72 0.740 0.76 0.78 0.80 0.82 0.84
I want to creat a scope vector so that I can later creatte a signal out of it.
How can I do this?

Respuestas (1)

Hank
Hank el 11 de Feb. de 2020

0 votos

In MATLAB, create an array by wrapping the data in brackets
time_vector = [1 2 3]
creates a row vector.

3 comentarios

Mariana
Mariana el 12 de Feb. de 2020
Both of them are already output arrays. I just have trouble plotting them into a graph. To set a coordinate that at time 0.02 the value of signal1 was of 1 for signal2 was 7 signal3 was 13 and so on.....
Hank
Hank el 12 de Feb. de 2020
Are you saying your signals are the columns of the matrix?
Mariana
Mariana el 12 de Feb. de 2020
Editada: Mariana el 12 de Feb. de 2020
This is my matlab/simulink model

Iniciar sesión para comentar.

Categorías

Más información sobre Simulink en Centro de ayuda y File Exchange.

Productos

Etiquetas

Preguntada:

el 11 de Feb. de 2020

Editada:

el 12 de Feb. de 2020

Community Treasure Hunt

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

Start Hunting!

Translated by