How come signal is logged with dimension 1x1x50 instead of 1x50?
Afficher commentaires plus anciens
How can I log a signal with dimension 1x50 instead of 1x1x50? I have several constants with sample times of 0.01 that are converted to int32 and then passed through a switch. I have a test point placed at the signal after the switch. The simulink model runs with the correct output; however, the logged signal has dimension 1x1x50 instead of 1x50.
Réponses (1)
Fangjun Jiang
le 30 Avr 2015
Modifié(e) : Fangjun Jiang
le 30 Avr 2015
0 votes
You must have that output signal resolved to a signal object, like Simulink.Signal or mpt.Signal. a=Simulink.Signal If you specify a.Dimensions=[1 1], Simulink logs the simulation data as 1x1x50. 50 is the number of samples logged. If you specify a.Dimensions=1, Simulink will log the simulation data as 50x1. That is probably what you need.
Catégories
En savoir plus sur Simulink dans Centre d'aide et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!