Documentation Center

  • Trial Software
  • Product Updates

ssc_new

Create new Simscape model populated by required and commonly used blocks

Syntax

ssc_new
ssc_new('modelname')
ssc_new('modelname','domain')
ssc_new('modelname','domain','solver')

Description

ssc_new creates a new Simscape™ model, with required and commonly used blocks already on the model canvas, and opens the Simscape library. By default, it uses the Simulink® default new model name untitled and the recommended solver ode23t.

ssc_new('modelname')creates a new Simscape model with the specified name.

ssc_new('modelname','domain')creates a new Simscape model with the specified name, and with domain-specific reference block added to the model canvas. Valid domains types are 'electrical', 'hydraulic', 'magnetic', 'pneumatic', 'rotational', 'translational', 'thermal', and 'thermal_liquid'. You can use a cell array of domain types to add more than one type of reference block.

ssc_new('modelname','domain','solver') creates a new Simscape model with the specified name and domain type, and with the specified solver type. Recommended solver types for Simscape models are 'ode15s', 'ode23t', and 'ode14x'. You can use other Simulink solvers, but, depending on the particular model, they may be less suitable. For more information, see Setting Up Solvers for Physical Models.

Examples

To create a generic Simscape model, type:

ssc_new

The software opens the main Simscape library and creates a new untitled model, which contains a Solver Configuration block with the default solver set to ode23t, a Simulink-PS Converter block, and a PS-Simulink Converter block connected to a Scope block.

To create a hydraulic model, called hydraulic_actuator and using the ode15s solver, type:

ssc_new('hydraulic_actuator','hydraulic','ode15s')

The software opens the main Simscape library and creates the following model.

After using ssc_new, continue developing your model by copying the blocks, as needed, and adding other blocks from the Simscape libraries.

Was this topic helpful?