Main Content

System-generated identifiers

Specify whether to use shorter names for the $N token in system-generated identifiers

Model Configuration Pane: Code Generation / Identifiers

Description

Specify whether the code generator uses shorter, more consistent names for the $N token in system-generated identifiers.

Dependencies

This parameter:

  • Appears only for ERT-based targets.

  • Requires Embedded Coder® when generating code.

Settings

Shortened (default) | Classic
Classic

Generate longer identifier names for the $N token. For example, for a model named sym, if:

  • Global variables is $N$R$M, the block state identifier is DWork_sym.

  • Global types is $R$N$M, the block state type is a structure named sym_D_Work.

Shortened

Shorten identifier names for the $N token to allow more space for user names. This option provides a more predictable and consistent naming system that uses camel case, no underscores or plurals, and consistent abbreviations for both a type and a variable. For example, for a model named sym, if:

System-generated identifiers per model

ClassicShortenedData RepresentationDescription
BlockIO, BBType, Global Variable

Block signals of the system

ExternalInputsExtUType

Block input data for root system

ExternalInputSizesExtUSizeType

Size of block input data for the root system (used when inputs are variable dimensions)

ExternalOutputsExtYType

Block output data for the root system

ExternalOutputSizesExtYSizeType

Size of block output data for the root system

UUGlobal Variable

Input data

USizeUSizeGlobal Variable

Size of input data

YYGlobal Variable

Output data

YSizeYSizeGlobal Variable

Size of output data

ParametersPType, Global Variable

Parameters for the system

ConstBlockIOConstBConst Type, Global Variable

Block inputs and outputs that are constants

MachineLocalData, Machine

MachLocalConst Type, Global Variable

Used by ERT S-function targets

ConstParam, ConstPConstPConst Type, Global Variable

Constant parameters in the system

ConstParamWithInit, ConstWithInitPConstInitPConst Type, Global Variable

Initialization data for constant parameters in the system

D_Work, DWorkDWType, Global Variable

Block states in the system

MassMatrixGlobalMassMatrixType, Global Variable

Used for physical modeling blocks

PrevZCSigStates, PrevZCSigStatePrevZCXType, Global Variable

Previous zero-crossing signal state

ContinuousStates, XXType, Global Variable

Continuous states

StateDisabled, XdisXDisType, Global Variable

Status of an enabled subsystem

StateDerivatives, XdotXDotType, Global Variable

Derivatives of continuous states at each time step

ZCSignalValues, ZCSignalValueZCVType, Global Variable

Zero-crossing signals

DefaultParametersDefaultPGlobal Variable

Default parameters in the system

GlobalTIDGlobalTIDGlobal Variable

Used for sample time for states in referenced models

InvariantSignalsInvariantGlobal Variable

Invariant signals

NSTAGESNSTAGESGlobal Variable

Solver macro

ObjectObjGlobal Variable

Used by ERT C++ code generation to refer to referenced model objects

TimingBridgeTimingBrdgGlobal Variable

Timing information stored in different data structures

SharedDSMSharedDSMType, Global VariableShared local data stores, which are Data Store Memory blocks with Share across model instances selected
InstPInstPType, Global VariableParameter arguments for the system

System-generated identifier names per referenced model or reusable subsystem

ClassicShortenedData RepresentationDescription
rtB, BBType, Global Variable

Block signals of the system

rtC, CConstBType, Global Variable

Block inputs and outputs that are constants

rtDW, DWDWType, Global Variable

Block states in the system

rtMdlrefDWork, MdlrefDWorkMdlRefDWType, Global Variable

Block states in referenced model

rtP, PPType, Global Variable

Parameters for the system

rtRTM, RTMRTMType, Global Variable

RT_Model structure

rtX, XXType, Global Variable

Continuous states in model reference

rtXdis, XdisXDisType, Global Variable

Status of an enabled subsystem

rtXdot, XdotXDotType, Global Variable

Derivatives of the S-function's continuous states at each time step

rtZCE, ZCEZCEType, Global Variable

Zero-crossing enabled

rtZCSV, ZCSVZCVType, Global Variable

Zero-crossing signal values

rtSharedDSM, SharedDSMSharedDSMType, Global VariableShared local data stores, which are Data Store Memory blocks with Share across model instances selected
rtInstP, InstPInstPType, Global VariableParameter arguments for the system

Note

When you set the System-generated identifiers parameter to Shortened, while generating an identifier for a global variable of a referenced model which is a run-time parameter, the code generator adds a prefix rtP_ to the variable name for the $N token.

Recommended Settings

ApplicationSetting
DebuggingNo impact
TraceabilityNo impact
EfficiencyNo impact
Safety precautionNo impact

Programmatic Use

Parameter: InternalIdentifier
Type: character vector
Value: Classic | Shortened
Default: Shortened

Version History

Introduced in R2013a