qc_set_model_uri qc_get_target_type navigation bar

Table of Contents

qc_get_step_size

Returns the step size of the model.

Syntax

step_size = qc_get_step_size(model) % Returns the step size of the specified model
step_size = qc_get_step_size        % Returns the step size of the current model
    

Description

Returns the step size of the given model. The step size becomes the fundamental sample time of the model. It corresponds to the value of the Fixed step-size (fundamental sample time) field of the Solver pane in the Configuration parameters dialog.

If this function is invoked from a library, which has no sample time, then it returns 0.001 so that blocks in the library which use this function do not issue error messages about invalid sample times.

Parameters

model

A string indicating the name of the model used to find the step size. eg. 'q_a_lpbk' or

bdroot

MATLAB Command Line

Click to copy the following command line to the clipboard. Then paste it in the MATLAB Command Window:

doc('bdroot')
.

config_set

A Simulink.ConfigSet configuration set containing the step size (see

getConfigSet

MATLAB Command Line

Click to copy the following command line to the clipboard. Then paste it in the MATLAB Command Window:

doc('getConfigSet')
).

Outputs

step_size

The step size of the model. If the model has no step size then an error is issued.

Examples

step_size = qc_get_step_size(bdroot); % Returns the step size of the current model e.g. 0.001
    

See Also

 

navigation bar