Info

La pregunta está cerrada. Vuélvala a abrir para editarla o responderla.

Simulink - Apply different Delay to different columns of input data

1 visualización (últimos 30 días)
Bhavin Shiyani
Bhavin Shiyani el 3 de Dic. de 2019
Cerrada: MATLAB Answer Bot el 20 de Ag. de 2021
Hi,
In Simulink, My input data 'X' is a matrix and I want to apply different delay values to each column of Matrix 'X'.
Eg. X = [ 1 2 3; 4 5 6 ; 7 8 9] and delay_vector = [100 200 300]
So, Delay of 100 samples should be applied to 1st column of X, 200 samples of delay to 2nd column and 300 samples of delay to 3rd column.
I tried using Simulink Delay block but it supports delay length as scalar only and not vector.
Does anyone have idea how to acheive the same?
Thanks,

Respuestas (1)

Walter Roberson
Walter Roberson el 3 de Dic. de 2019
If you are using From File or From Workspace, then the first column of the array must be the timestamp, and the timestamp applies to all columns of the same row.
You can split your array into different arrays so that you can use different timestamps.
Alternately, you could potentially use blocks to split your signal (which would be a vector at any one time) and run the second through a delay block of (200-100) and the third through a delay block of (300-100)
  1 comentario
Bhavin Shiyani
Bhavin Shiyani el 3 de Dic. de 2019
Thansk Roberson, for your answer.
But the issue is I want to implement it using single Delay block and it is important when I generate code from the Simulink model.
Suppose if I use 3 different delay blocks then generated code will create 3 buffer and will need more memory.
So I want to use single delay block.
Thanks

La pregunta está cerrada.

Etiquetas

Productos


Versión

R2018b

Community Treasure Hunt

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

Start Hunting!

Translated by