Output Data produced is in a 2D array instead of 1D array.

2 ビュー (過去 30 日間)
Shubham
Shubham 2013 年 11 月 12 日
編集済み: The Matlab Spot 2013 年 11 月 12 日
Hello,
I have been encountering a problem in my simulink model, hence I made a very simple model.
Input -> gain -> output
Here my input is 109*1 matrix, and I want that every time simulink picks up single value out of this 109 values (one after other) and produces a output value, thus it must produce 109values, but instead it produces 51*109 matrix. In the output; 51 rows have same value but 109 columns actually shows the multiplication.
Also a tout variable with 51 rows is being generated. I know that my output is influenced by the tout, but I really dont know how to mitigate this problem

回答 (1 件)

The Matlab Spot
The Matlab Spot 2013 年 11 月 12 日
編集済み: The Matlab Spot 2013 年 11 月 12 日
My understanding of the problem statement:
- Vector input of 109*1
- For every time step one value out of this vector should be used for simulation
Ans:
1. Use the Index vector block from the simulink library to iterate through the rows of this vector input
2. Simulate the model for 109 steps atleast to generate output for every value

カテゴリ

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

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by