Convert matrix to constant
9 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hi everybody, Am having sampled matrix data of size(194*1) in workspace. I have to import to simulink blocks of same samples (194 value). Give me suggestion pls.
Thank you in advance!!!!
0 commentaires
Réponses (1)
Fangjun Jiang
le 10 Oct 2011
Use the "From Workspce" block. Have your time vector and data vector arranged in two column format as below:
[t1,d1;
t2,d2;
t3,d3;
...
...]
2 commentaires
Fangjun Jiang
le 17 Oct 2011
Try a simple example first. In MATLAB Command Window, run this first.
t=(1:194)';
d=rand(194,1);
Then set the data for the "From Workspace" block as [t,d]. Remember, you need to set the data as two column with the same size. First column is time stamp, second column is your data.
Voir également
Catégories
En savoir plus sur Programmatic Model Editing dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!