Registro de datos
Puede registrar datos de simulación en el área de trabajo, un disco o un archivo temporal para realizar tareas de depuración y verificación. Registrar datos permite analizar de qué forma cambian las variables de bloque internas a medida que transcurre la simulación. Por ejemplo, tal vez desea comprobar que la presión en un cilindro hidráulico está por encima de un valor mínimo determinado o compararlo con la presión de la bomba. Si registra datos de simulación, más tarde puede consultarlos, representarlos o analizarlos sin tener que volver a ejecutar la simulación.
La herramienta interactiva Results Explorer de Simscape™ permite navegar y representar los resultados del registro de datos de la simulación. Puede utilizar el registro de datos y Results Explorer de Simscape para ver los resultados de la simulación en lugar de añadir sensores y scopes a su modelo.
Herramientas
Results Explorer de Simscape | Navigate and plot simulation data logging results |
Funciones
simscape.logging.export | Save logged simulation data in MLDATX file |
simscape.logging.import | Create simulation log variable to access data in MLDATX file |
simscape.logging.plot | Plot logged simulation data for Node or Series |
simscape.logging.plotxy | Plot logged simulation data for one node or series against another |
simscape.logging.findNode | Find Node object corresponding to block or subsystem (desde R2020a) |
simscape.logging.sli.findNode | (To be removed) Find Node object corresponding to block or
subsystem |
simscape.logging.findPath | Find path to node in logged simulation data tree (desde R2020a) |
simscape.logging.sli.findPath | (To be removed) Find path to node in logged simulation data tree |
simscape.logging.timestamp | Determine whether simulation log is current or stale (desde R2021a) |
sscexplore | Open Simscape Results Explorer to interact with logged simulation data |
sscprintzcs | Print zero crossing information for logged simulation data |
Objetos
simscape.logging.Node | Hierarchy tree for simulation data |
simscape.logging.Series | Time-value series for simulation data |
Temas
- About Simscape Data Logging
You can log Simscape simulation data to the workspace, or to a temporary file on disk, for debugging and verification.
- Activar el registro de datos para el modelo entero
Usar el registro de datos para el modelo entero es una práctica recomendada.
- Log Data for Selected Blocks Only
Instead of logging Simscape simulation data for the whole model, you can log data just for the selected blocks.
- Data Logging Options
Additional options for logging and displaying the simulation data.
- Stream Logging Data to Disk
When you log simulation data, you can stream the data to a temporary file on disk and have the workspace variable point to that temporary file.
- Saving and Retrieving Logged Simulation Data
Methods of storing logged simulation data for future use and retrieving it at a later time.
- Log, Navigate, and Plot Simulation Data
This example shows the basic workflow for logging simulation data for the whole model and then navigating and plotting the logged data using Simscape Results Explorer.
- Log and Plot Simulation Data
This example shows how you can log and plot simulation data instead of adding sensors to your model.
- Log Simulation Statistics
This example shows how you can access and analyze information on zero crossings during simulation.
- Log and View Simulation Data for Selected Blocks
This example shows how you can set your model to log simulation data for selected blocks only and how to view simulation data using Simscape Results Explorer.
- Plot Simulation Data in Different Units
When you display logged simulation data in Simscape Results Explorer, you can change the
y
-axis units directly on the plot. - Use Custom Units to Plot Simulation Data
This example shows how you can change to a custom unit display of logged simulation data.
- Indexing into Component Arrays
You can use command-line interface to index into an array of components, for example, to get or set operating point targets for a particular array member, or to plot simulation data.