Subsystem
SubsystemsThe Subsystem block provides hierarchical encapsulation on the simulation canvas, grouping complex sub-diagrams into compact, modular blocks. It allows engineers to simplify large diagrams, build clean multi-level architectures, and reuse functional units across projects.
Double-clicking a Subsystem block opens an isolated child canvas where nested blocks are wired together. Boundaries between parent and child canvases are mediated by InPort and OutPort blocks, which dynamically expose connection ports on the exterior of the Subsystem block.
Mathematical Model
Where:
- represents external input signals routed into the subsystem through internal
InPortblocks. - represents internal signals routed out through
OutPortblocks to the parent diagram. - Internal continuous and discrete states evolve according to the interconnected equations of the child blocks.
Parameters
| Parameters | Label | Type | Default | Description |
|---|---|---|---|---|
subsystemName |
Subsystem Name | text | MySubsystem |
|
description |
Description | text | Hierarchical block container |
Usage Examples
Example 1: Encapsulating a Closed-Loop Motor Controller
A Subsystem named "MotorDrive" contains an error subtraction node, PID controller, anti-windup limiter, and PWM generator. Exterior ports speed_ref and speed_meas feed internal InPorts, while OutPort pwm_duty drives the physical motor model.
Example 2: Multi-Rate Cascaded Filter Chain
A Subsystem named "TelemetryFilter" packages a low-pass analog filter, discrete notch filter, and moving average smoother to clean raw sensor readings before passing them to the main guidance computer.
Remarks & Best Practices
- Interface definition: Port connections on the Subsystem block are defined by
InPortandOutPortblocks placed on its internal canvas. - Hierarchical navigation: Double-click the block to enter its child canvas; use the breadcrumb navigation bar at the top of the workspace to return to the parent level.
- Arbitrary nesting: Subsystems can be nested inside other subsystems, supporting modular multi-tier systems engineering.
- State isolation: Dynamic states (integrators, delays, transfer functions) within each subsystem maintain distinct independent memory.