📄 ptest3sim2.mdl
字号:
Position [530, 358, 555, 382]
ShowPortLabels on
TreatAsAtomicUnit off
RTWSystemCode "Auto"
RTWFcnNameOpts "Auto"
RTWFileNameOpts "Auto"
MaskDisplay "plot([-1 1],[0 0],[-1 1],[-1 1])"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
System {
Name "purelin"
Location [142, 216, 402, 298]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
Block {
BlockType Inport
Name "n"
Position [25, 33, 55, 47]
Port "1"
LatchInput off
Interpolate on
}
Block {
BlockType Outport
Name "a"
Position [205, 33, 235, 47]
Port "1"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Line {
SrcBlock "n"
SrcPort 1
DstBlock "a"
DstPort 1
}
}
}
Block {
BlockType SubSystem
Name "tansig"
Ports [1, 1]
Position [370, 348, 395, 372]
ShowPortLabels on
TreatAsAtomicUnit off
RTWSystemCode "Auto"
RTWFcnNameOpts "Auto"
RTWFileNameOpts "Auto"
MaskDisplay "plot([-1 1],[0 0],[-1 -.9 -.8 -.7 -.6 -.5 -"
".4 -.3 -.2 -.1 0 .1 .2 .3 .4 .5 .6 .7 .8 .9 1],2./(1+exp(-8*[-1 -.9 -.8 -.7 -"
".6 -.5 -.4 -.3 -.2 -.1 0 .1 .2 .3 .4 .5 .6 .7 .8 .9 1]))-1)"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
System {
Name "tansig"
Location [315, 155, 955, 597]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
Block {
BlockType Inport
Name "n"
Position [25, 33, 55, 47]
Port "1"
LatchInput off
Interpolate on
}
Block {
BlockType Math
Name "Exp"
Ports [1, 1]
Position [155, 25, 185, 55]
Operator "exp"
OutputSignalType "auto"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
}
Block {
BlockType Gain
Name "Gain"
Position [90, 25, 120, 55]
Gain "-2"
Multiplication "Element-wise(K.*u)"
SaturateOnIntegerOverflow on
}
Block {
BlockType Gain
Name "Gain1"
Position [370, 30, 400, 60]
Gain "2"
Multiplication "Element-wise(K.*u)"
SaturateOnIntegerOverflow on
}
Block {
BlockType Math
Name "Reciprocal"
Ports [1, 1]
Position [295, 30, 325, 60]
Operator "reciprocal"
OutputSignalType "auto"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
}
Block {
BlockType Sum
Name "Sum"
Ports [2, 1]
Position [225, 27, 255, 58]
IconShape "rectangular"
Inputs "++"
SaturateOnIntegerOverflow on
}
Block {
BlockType Sum
Name "Sum1"
Ports [2, 1]
Position [445, 27, 475, 58]
IconShape "rectangular"
Inputs "+-"
SaturateOnIntegerOverflow on
}
Block {
BlockType Constant
Name "one"
Position [160, 85, 180, 105]
Value "1"
VectorParams1D on
}
Block {
BlockType Constant
Name "one1"
Position [375, 85, 395, 105]
Value "1"
VectorParams1D on
}
Block {
BlockType Outport
Name "a"
Position [515, 38, 545, 52]
Port "1"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Line {
SrcBlock "n"
SrcPort 1
DstBlock "Gain"
DstPort 1
}
Line {
SrcBlock "Gain"
SrcPort 1
DstBlock "Exp"
DstPort 1
}
Line {
SrcBlock "Exp"
SrcPort 1
Points [20, 0]
DstBlock "Sum"
DstPort 1
}
Line {
SrcBlock "one"
SrcPort 1
Points [25, 0]
DstBlock "Sum"
DstPort 2
}
Line {
SrcBlock "Sum"
SrcPort 1
DstBlock "Reciprocal"
DstPort 1
}
Line {
SrcBlock "Reciprocal"
SrcPort 1
DstBlock "Gain1"
DstPort 1
}
Line {
SrcBlock "Gain1"
SrcPort 1
Points [25, 0]
DstBlock "Sum1"
DstPort 1
}
Line {
SrcBlock "one1"
SrcPort 1
Points [30, 0]
DstBlock "Sum1"
DstPort 2
}
Line {
SrcBlock "Sum1"
SrcPort 1
DstBlock "a"
DstPort 1
}
}
}
Block {
BlockType Outport
Name "Out1"
Position [730, 363, 760, 377]
Port "1"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Block {
BlockType Outport
Name "Out2"
Position [425, 308, 455, 322]
Port "2"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Block {
BlockType Outport
Name "Out3"
Position [800, 428, 830, 442]
Port "3"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Block {
BlockType Outport
Name "Out4"
Position [760, 33, 790, 47]
Port "4"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Block {
BlockType Outport
Name "Out5"
Position [750, 208, 780, 222]
Port "5"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Block {
BlockType Outport
Name "Out2a"
Position [945, 118, 975, 132]
Port "6"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Line {
SrcBlock "LW2,1"
SrcPort 1
DstBlock "Product1"
DstPort 1
}
Line {
SrcBlock "Product1"
SrcPort 1
Points [15, 0]
Branch {
Points [0, 140]
DstBlock "Matrix\nGain4"
DstPort 1
}
Branch {
Points [0, -35]
DstBlock "Matrix\nGain3"
DstPort 1
}
}
Line {
SrcBlock "Constant2"
SrcPort 1
DstBlock "LW2,1"
DstPort 1
}
Line {
SrcBlock "Product"
SrcPort 1
DstBlock "Sum1"
DstPort 1
}
Line {
SrcBlock "Constant3"
SrcPort 1
Points [10, 0; 0, -40]
DstBlock "Sum1"
DstPort 2
}
Line {
SrcBlock "Sum1"
SrcPort 1
Points [10, 0; 0, -65]
DstBlock "Product1"
DstPort 2
}
Line {
SrcBlock "netsum1"
SrcPort 1
DstBlock "purelin"
DstPort 1
}
Line {
SrcBlock "Constant1"
SrcPort 1
Points [10, 0; 0, -55]
DstBlock "netsum1"
DstPort 2
}
Line {
SrcBlock "Matrix\nGain2"
SrcPort 1
DstBlock "netsum1"
DstPort 1
}
Line {
SrcBlock "Constant"
SrcPort 1
Points [15, 0]
DstBlock "netsum"
DstPort 3
}
Line {
SrcBlock "Matrix\nGain1"
SrcPort 1
Points [10, 0]
DstBlock "netsum"
DstPort 1
}
Line {
SrcBlock "Discrete State-Space2"
SrcPort 1
DstBlock "Matrix\nGain1"
DstPort 1
}
Line {
SrcBlock "Matrix\nGain"
SrcPort 1
DstBlock "netsum"
DstPort 2
}
Line {
SrcBlock "tansig"
SrcPort 1
Points [5, 0]
Branch {
Points [0, -45]
Branch {
Points [0, -175]
Branch {
Points [0, -15]
DstBlock "Product"
DstPort 1
}
Branch {
DstBlock "Product"
DstPort 2
}
}
Branch {
DstBlock "Out2"
DstPort 1
}
}
Branch {
DstBlock "Matrix\nGain2"
DstPort 1
}
}
Line {
SrcBlock "purelin"
SrcPort 1
DstBlock "Unit Delay2"
DstPort 1
}
Line {
SrcBlock "Unit Delay2"
SrcPort 1
Points [5, 0]
Branch {
Points [0, -125; -520, 0; 0, 40]
DstBlock "Discrete State-Space2"
DstPort 1
}
Branch {
Points [90, 0]
Branch {
Points [0, 55]
DstBlock "Sum"
DstPort 1
}
Branch {
DstBlock "Out1"
DstPort 1
}
}
}
Line {
SrcBlock "Discrete State-Space"
SrcPort 1
DstBlock "Matrix\nGain"
DstPort 1
}
Line {
SrcBlock "Matrix\nGain4"
SrcPort 1
Points [35, 0]
Branch {
Points [0, -80]
DstBlock "Mux6"
DstPort 2
}
Branch {
DstBlock "Out5"
DstPort 1
}
}
Line {
SrcBlock "Mux6"
SrcPort 1
DstBlock "S-Function"
DstPort 1
}
Line {
SrcBlock "Unit Delay3"
SrcPort 1
Points [10, 0]
DstBlock "Discrete State-Space"
DstPort 1
}
Line {
SrcBlock "Matrix\nGain3"
SrcPort 1
Points [30, 0]
Branch {
Points [0, 70]
DstBlock "Mux6"
DstPort 1
}
Branch {
DstBlock "Out4"
DstPort 1
}
}
Line {
SrcBlock "S-Function"
SrcPort 1
DstBlock "Out2a"
DstPort 1
}
Line {
SrcBlock "In1"
SrcPort 1
DstBlock "Unit Delay3"
DstPort 1
}
Line {
SrcBlock "Sum"
SrcPort 1
DstBlock "Out3"
DstPort 1
}
Line {
SrcBlock "In2"
SrcPort 1
DstBlock "Sum"
DstPort 2
}
Line {
SrcBlock "netsum"
SrcPort 1
DstBlock "tansig"
DstPort 1
}
}
}
Block {
BlockType Outport
Name "Outport1"
Position [550, 45, 570, 65]
BackgroundColor "lightBlue"
Port "1"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Block {
BlockType Outport
Name "Outport2"
Position [550, 100, 570, 120]
BackgroundColor "lightBlue"
Port "2"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Block {
BlockType Outport
Name "Outport3"
Position [550, 150, 570, 170]
BackgroundColor "lightBlue"
Port "3"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Block {
BlockType Outport
Name "Outport4 (gU)"
Position [555, 205, 575, 225]
BackgroundColor "lightBlue"
Port "4"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Block {
BlockType Outport
Name "Outport5 (gUd)"
Position [555, 260, 575, 280]
BackgroundColor "lightBlue"
Port "5"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Block {
BlockType Outport
Name "Outport6"
Position [555, 335, 575, 355]
BackgroundColor "lightBlue"
Port "6"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Line {
SrcBlock "Subsystem"
SrcPort 2
Points [20, 0; 0, -55]
DstBlock "Outport2"
DstPort 1
}
Line {
SrcBlock "Subsystem"
SrcPort 1
Points [5, 0; 0, -95]
DstBlock "Outport1"
DstPort 1
}
Line {
SrcBlock "Subsystem"
SrcPort 3
Points [45, 0; 0, -20]
DstBlock "Outport3"
DstPort 1
}
Line {
SrcBlock "Inport1"
SrcPort 1
DstBlock "Subsystem"
DstPort 2
}
Line {
SrcBlock "Subsystem"
SrcPort 5
Points [20, 0; 0, 60]
DstBlock "Outport5 (gUd)"
DstPort 1
}
Line {
SrcBlock "Inport"
SrcPort 1
DstBlock "Subsystem"
DstPort 1
}
Line {
SrcBlock "Subsystem"
SrcPort 4
Points [45, 0; 0, 20]
DstBlock "Outport4 (gU)"
DstPort 1
}
Line {
SrcBlock "Subsystem"
SrcPort 6
Points [0, 120]
DstBlock "Outport6"
DstPort 1
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -