Composite Components

Construct custom components by connecting multiple components

Simscape Language Syntax

Examples and How To

Composite Component — DC Motor

This example shows how to implement a DC motor model by means of a composite component.

Composite Component Using import Statements

This example shows how you can use import statements to implement a DC motor model by means of a composite component.

Component Variants — Series RLC Branch

This example shows how to implement variants within a component file by using conditional sections.


About Composite Components

A composite component is constructed out of other components.

Declaring Member Components

A components declaration block begins with a components keyword and is terminated by an end keyword.

Parameterizing Composite Components

Composite component parameters let you adjust the desired parameters of the underlying member components from the top-level block dialog box when building and simulating a model.

Specifying Initial Target Values for Member Variables

Member components have to be declared as hidden, and therefore their variables do not appear in the Variables tab of the top-level block dialog box.

Specifying Component Connections

The structure section of a Simscape™ file is executed once during compilation.

Importing Domain and Component Classes

An import mechanism provides a convenient means to accessing classes defined in different scopes, or namespaces.

Defining Component Variants

Use conditional sections to define variants within component file.

Was this topic helpful?