Typical Simscape Language Tasks
Simscape™ block libraries contain a comprehensive selection of blocks that represent engineering components such as valves, resistors, springs, and so on. These prebuilt blocks, however, may not be sufficient to address your particular engineering needs. When you need to extend the existing block libraries, use the Simscape language to define customized components, or even new physical domains, as textual files. Then convert your textual components into libraries of additional Simscape blocks that you can use in your model diagrams.
This table lists typical tasks along with links to background information and examples.
Task | Background Information | Examples |
---|---|---|
Create a custom component model based on equations | Model Linear Resistor in Simscape Language Electrical Component — Ideal Capacitor | |
Create a custom component model constructed of other components | ||
Generate a custom block from a Simscape component file | ||
Add a custom block library to Simscape libraries | Building Custom Block Libraries Using Source Protection for Simscape Files | |
Define a new domain, with associated Through and Across variables, and then use it in custom components | ||
Create a component that supplies domain-wide parameters (such as fluid temperature) to the rest of the model | ||
Create a component characterized by a discrete set of distinct operating modes, such as a car clutch |