simulink to workspace using simout as a scalar value
6 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
vishnuvardhan naidu tanga
el 3 de Mzo. de 2020
Respondida: Harshal Ritwik
el 19 de Jun. de 2023
hello everyone,
I need to get the data from simulink to workspace, to do that i have used simout block. BUt i am getting a timeseries . I have even used the array output but still i am getting a multiple output. Is there any way to calculate a single scalar value instead of time series and multple values.
thanks in advance
0 comentarios
Respuestas (1)
Harshal Ritwik
el 19 de Jun. de 2023
Hi,
As per my understanding you want to know how to get a scaler output by using the “To Workspace” block. If the signal output from your Simulink model is a scalar, then the "To Workspace" block will save the output as a scalar in the workspace variable. If the signal output is a vector or matrix, then the output saved to the workspace variable will be in the form of a vector or matrix accordingly.
So, there is no specific mode to get a scaler output only and to get a scaler output if the signal output is scaler you need to set the parameter “VariableName” of the “To Workspace” block to “array”.
Please refer to the following documentation for more information.
I hope it helps!
Thanks.
0 comentarios
Ver también
Categorías
Más información sobre Simulink Functions en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!