Using Simulink | ![]() ![]() |
モデルパラメータ
つぎの表は、モデルを記述するパラメータの一覧と説明です。パラメータは、付録B で説明するモデルファイルで定義されている順番に表示されます。表には、コールバックルーチンの使用法 で記述されているモデルのコールバックパラメータも含まれています。説明 の欄には、Simulation Parameters ダイアログボックスのどこでその値を設定することができるかを示しています。シミュレーションパラメータであるモデルパラメータの詳細については、Simulation Parametersダイアログボックス に記述してあります。表の後に、パラメータの変更方法についての例を示します。
パラメータの値はコーテーションで囲んだ文字列として指定しなければなりません。文字列の内容はパラメータに依存し、数値(スカラ、ベクトル、行列)、変数名、ファイル名、または特定の値を与えることができます。値の欄には、必要な値のタイプ、(垂直バーで区切られた)設定可能な値、および中括弧で囲んだデフォルト値が示してあります。
パラメータ |
説明 |
値 |
AbsTol |
スカラ {1e-6} |
|
AlgebraicLoopMsg |
none | {warning} | error |
|
BooleanDataType |
on | {off} |
|
BufferReuse |
{on} | off |
|
CloseFcn |
コマンドまたは変数 |
|
ConfigurationManager |
文字列 |
|
ConsistencyChecking |
on | {off} |
|
Created |
文字列 |
|
Creator |
文字列 |
|
Decimation |
スカラ {1} |
|
Description |
文字列 |
|
ExternalInput |
スカラまたはベクトル [t, u] |
|
FinalStateName |
変数 {xFinal} |
|
FixedStep |
スカラ {auto} |
|
InitialState |
変数またはベクトル {xInitial} |
|
InitialStep |
スカラ {auto} |
|
InvariantConstants |
on | {off} |
|
LimitMaxRows |
on | {off} |
|
LoadExternalInput |
on | {off} |
|
LoadInitialState |
on | {off} |
|
MaxOrder |
1 | 2 | 3 | 4 | {5} |
|
MaxRows |
スカラ {1000} |
|
MaxStep |
スカラ {auto} |
|
MinStepSizeMsg |
{warning} | error |
|
ModelVersionFormat |
文字列 |
|
ModifiedBy |
文字列 |
|
ModifiedDateFormat |
文字列 |
|
Name |
文字列 |
|
ObjectParameters |
構造体 |
|
OutputOption |
AdditionalOutputTimes | |
|
OutputSaveName |
変数 {yout} |
|
OutputTimes |
ベクトル{[]} |
|
PaperOrientation |
portrait | {landscape} |
|
PaperPosition |
[left, bottom, width, height] |
|
PaperPositionMode |
auto | {manual} |
|
PaperSize |
[width height] (参照のみ) |
|
PaperType |
{usletter} | uslegal | a0 | a1 | a2 | a3 | a4 | a5 | b0 | b1 | b2 | b3 | b4 | b5 | arch-A | arch-B | arch-C | arch-D | arch-E | A | B | C | D | E | tabloid |
|
PaperUnits |
normalized | {inches} | centimeters | points |
|
PostLoadFcn |
コマンドまたは変数 |
|
PreLoadFcn |
コマンドまたは変数 |
|
Refine |
スカラ |
|
RelTol |
スカラ {1e-3} |
|
SampleTimeColors |
on | {off} |
|
SaveFcn |
コマンドまたは変数 |
|
SaveFinalState |
on | {off} |
|
SaveOutput |
{on} | off |
|
SaveState |
on | {off} |
|
SaveTime |
{on} | off |
|
ShowLineWidths |
on | {off} |
|
SimParamPage |
{Solver} | WorkspaceI/O | Diagnostics |
|
Solver |
{ode45} | ode23 | ode113 | ode15s | ode23s | ode5 | ode4 | ode3 | ode2 | ode1 | FixedStepDiscrete | VariableStepDiscrete |
|
StartFcn |
コマンドまたは変数 |
|
StartTime |
スカラ {0.0} |
|
StateSaveName |
variable {xout} |
|
StopFcn |
コマンドまたは変数 |
|
StopTime |
スカラ {10.0} |
|
TimeSaveName |
変数 {tout} |
|
UnconnectedInputMsg |
none | {warning} | error |
|
UnconnectedLineMsg |
none | {warning} | error |
|
UnconnectedOutputMsg |
none | {warning} | error |
|
Version |
(リリースバージョン) |
|
WideVectorLines |
on | {off} |
|
ZeroCross |
厳密なゼロクロッシング検出 (Zero Crossingsを参照) |
{on} | off |
以下の例では、mymodel
システムに対するモデルパラメータの設定方法を示します。
つぎのコマンドは、シミュレーションの開始時間と終了時間を設定します。
set_param('mymodel','StartTime','5','StopTime','100')
つぎのコマンドは、ソルバを ode15s
に設定し、最大次数を変更します。
set_param('mymodel','Solver','ode15s','MaxOrder','3')
つぎのコマンドは、SaveFcn
コールバックに関連付けます。
set_param('mymodel','SaveFcn','my_save_cb')
![]() | はじめに | 共通ブロックのパラメータ | ![]() |