Main Content

Variant Components in Architecture Models

Create, manage and analyze variant choices in System Composer™ architecture models

Variant components enable the creation and use of different design alternatives for a system with the purpose of meeting separate sets of requirements in an architecture model. Variant components represent a part of the model that can switch between different variant choices. Variant choices are design alternatives that you can add, analyze, and select as the active choice during simulation. Variant components help you rapidly prototype design choices and build modular subsystems for reuse and customization. For more information on the underlying concepts of variant components, see What Are Variants and When to Use Them.

Create and manage design alternatives by adding variant choices to the Variant Component block. Set the active choice for a Variant Component block, retrieve available choices, and set conditions to activate variant choices programmatically. Use the Variant Manager to view the model hierarchy and manage variant elements in your model. Design and build architecture models capable of deploying different variant choices, and run analysis functions to determine the most effective choice in terms of parameters such as production time.

Blocks

Variant ComponentAdd components with alternative designs

Classes

systemcomposer.arch.VariantComponentVariant component in System Composer model

Functions

addChoiceAdd variant choices to variant component
addVariantComponentAdd variant components to architecture
getActiveChoiceGet active choice on variant component
getChoicesGet available choices in variant component
getConditionReturn variant control on choice within variant component
makeVariantConvert component to variant choice
makeVariantAssemblyConvert variant component to variant assembly component (Since R2023b)
setActiveChoiceSet active choice on variant component
setConditionSet condition on variant choice
updatePortsFromChoicesUpdate ports in Variant Component block to match its variant choices (Since R2024a)

Topics

  • Variant Components

    Create multiple variant choices for a component and select a choice using variant controls.

  • Variant Assembly Components

    Add or remove variant choices to a Variant Assembly Component block from external sources without modifying the model.

Related Information

Featured Examples