How to extract column data in Simulink?

4 ビュー (過去 30 日間)
Maria
Maria 2017 年 11 月 30 日
コメント済み: Birdman 2017 年 12 月 1 日
Hi, I have been working with Simulink just for few days. I have a Discrete State Space system. My input is defined in the "Model Configuration parameter" as [time',i1s',i2s'], where i1s and i2s are my source currents. Let's say that the size of i1s' is equal to N x 1. I get a voltage as an output. Now, the output should be a vector that has a number of rows equal to 2N x 1. I want to extract only the first N rows. Which block shall I use in Simulink? I am taking a look at Selector and Variable Selector but I cannot make them work.
  2 件のコメント
Birdman
Birdman 2017 年 11 月 30 日
You want to extract those rows to workspace?
Maria
Maria 2017 年 11 月 30 日
I would need to extract the rows because I need to do some operations in Simulink with the first Nx1 components, and other operations with the remaining components

サインインしてコメントする。

採用された回答

Birdman
Birdman 2017 年 11 月 30 日
Use a Demux with 2 outputs. It should divide the rows equally.
  2 件のコメント
Maria
Maria 2017 年 12 月 1 日
Hi, I tried and it seems to work! But, I do not really understand how to see the components of the vector in Simulink. I attach the model I have with the data to use in order to simulate it.
Birdman
Birdman 2017 年 12 月 1 日
Try to adapt this concept into your model.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeModeling についてさらに検索

製品

Community Treasure Hunt

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

Start Hunting!

Translated by