📄 narmamaglev.mdl
字号:
PortNumber 1
Name "Current"
TestPoint off
LinearAnalysisOutput off
LinearAnalysisInput off
RTWStorageClass "Auto"
DataLogging off
DataLoggingNameMode "SignalName"
DataLoggingDecimateData off
DataLoggingDecimation "2"
DataLoggingLimitDataPoints off
DataLoggingMaxPoints "5000"
}
System {
Name "NARMA-L2 Controller"
Location [13, 149, 1258, 670]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
Block {
BlockType Inport
Name "Reference"
Position [505, 45, 535, 65]
}
Block {
BlockType Inport
Name "Plant Output"
Position [30, 62, 60, 78]
Port "2"
}
Block {
BlockType Constant
Name "Constant"
Position [500, 265, 520, 285]
Value "B1"
}
Block {
BlockType Constant
Name "Constant1"
Position [665, 275, 685, 295]
Value "B2"
}
Block {
BlockType Constant
Name "Constant2"
Position [105, 255, 125, 275]
Value "Normalize"
}
Block {
BlockType Constant
Name "Constant3"
Position [125, 130, 145, 150]
Value "Normalize"
}
Block {
BlockType Constant
Name "Constant4"
Position [1080, 215, 1100, 235]
Value "Normalize"
}
Block {
BlockType Constant
Name "Constant5"
Position [500, 385, 520, 405]
Value "B3"
}
Block {
BlockType Constant
Name "Constant6"
Position [665, 415, 685, 435]
Value "B4"
}
Block {
BlockType Constant
Name "Constant7"
Position [635, 115, 655, 135]
Value "Normalize"
}
Block {
BlockType DiscreteStateSpace
Name "Discrete State-Space4"
Position [350, 201, 460, 239]
A "blkdiag([zeros(1,Nj-1);eye(Nj-2,Nj-2) zeros"
"(Nj-2,1)],[zeros(1,Ni-1);eye(Ni-2,Ni-2) zeros(Ni-2,1)])"
B "blkdiag(eye(Nj-1,1),eye(Ni-1,1))"
C "blkdiag([zeros(1,Nj-1);eye(Nj-1,Nj-1)],[zer"
"os(eye(double(Ni>1)),Ni-1);eye(Ni-2,Ni-1)])"
D "blkdiag([1;zeros(Nj-1,1)],[eye(double(Ni>1)"
");zeros(Ni-2,1)])"
SampleTime "Ts"
}
Block {
BlockType Fcn
Name "Fcn"
Position [105, 205, 140, 235]
Expr "(u(1)-minp)*2/(maxp-minp) - 1"
}
Block {
BlockType Fcn
Name "Fcn1"
Position [115, 55, 150, 85]
Expr "(u(1)-mint)*2/(maxt-mint) - 1"
}
Block {
BlockType Fcn
Name "Fcn2"
Position [1075, 145, 1110, 175]
Expr "(u(1)+1)*(maxp-minp)/2 + minp"
}
Block {
BlockType Fcn
Name "Fcn3"
Position [625, 40, 660, 70]
Expr "(u(1)-mint)*2/(maxt-mint) - 1"
}
Block {
BlockType Gain
Name "Matrix\nGain"
Position [490, 190, 520, 220]
Gain "IW1_1"
Multiplication "Matrix(K*u)"
}
Block {
BlockType Gain
Name "Matrix\nGain1"
Position [495, 325, 525, 355]
Gain "IW3_2"
Multiplication "Matrix(K*u)"
}
Block {
BlockType Gain
Name "Matrix\nGain2"
Position [660, 200, 690, 230]
Gain "LW2_1"
Multiplication "Matrix(K*u)"
}
Block {
BlockType Gain
Name "Matrix\nGain3"
Position [660, 340, 690, 370]
Gain "LW4_3"
Multiplication "Matrix(K*u)"
}
Block {
BlockType Gain
Name "Matrix\nGain5"
Position [815, 210, 845, 240]
Gain "LW6_2"
Multiplication "Matrix(K*u)"
}
Block {
BlockType Gain
Name "Matrix\nGain8"
Position [840, 350, 870, 380]
Gain "LW6_5*LW5_4*IW5_3"
Multiplication "Matrix(K*u)"
}
Block {
BlockType Mux
Name "Mux"
Ports [2, 1]
Position [285, 193, 330, 242]
ShowName off
Inputs "2"
DisplayOption "signals"
}
Block {
BlockType Product
Name "Product"
Ports [2, 1]
Position [940, 207, 970, 238]
Inputs "*/"
}
Block {
BlockType Saturate
Name "Saturation1"
Position [1235, 210, 1265, 240]
UpperLimit "max_i"
LowerLimit "min_i"
ZeroCross off
}
Block {
BlockType Sum
Name "Sum"
Ports [2, 1]
Position [875, 112, 905, 143]
Inputs "+-"
}
Block {
BlockType Switch
Name "Switch"
Position [170, 255, 200, 285]
Threshold "0.5"
ZeroCross off
}
Block {
BlockType Switch
Name "Switch1"
Position [180, 130, 210, 160]
Threshold "0.5"
ZeroCross off
}
Block {
BlockType Switch
Name "Switch2"
Position [1140, 210, 1170, 240]
Threshold "0.5"
ZeroCross off
}
Block {
BlockType Switch
Name "Switch3"
Position [705, 100, 735, 130]
Threshold "0.5"
ZeroCross off
}
Block {
BlockType UnitDelay
Name "Unit Delay4"
Position [230, 225, 260, 255]
SampleTime "Ts"
}
Block {
BlockType ZeroOrderHold
Name "Zero-Order\nHold"
Position [1300, 206, 1335, 244]
SampleTime "Ts"
}
Block {
BlockType SubSystem
Name "netsum"
Ports [2, 1]
Position [550, 194, 575, 236]
TreatAsAtomicUnit off
MaskDisplay "disp('+')"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
System {
Name "netsum"
Location [322, 87, 822, 388]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
Block {
BlockType Inport
Name "In1"
Position [20, 50, 40, 70]
}
Block {
BlockType Inport
Name "In2"
Position [20, 90, 40, 110]
Port "2"
}
Block {
BlockType Sum
Name "netsum"
Ports [2, 1]
Position [90, 59, 115, 101]
Inputs "2"
}
Block {
BlockType Outport
Name "Out1"
Position [145, 80, 165, 100]
}
Line {
SrcBlock "In1"
SrcPort 1
DstBlock "netsum"
DstPort 1
}
Line {
SrcBlock "In2"
SrcPort 1
DstBlock "netsum"
DstPort 2
}
Line {
SrcBlock "netsum"
SrcPort 1
DstBlock "Out1"
DstPort 1
}
}
}
Block {
BlockType SubSystem
Name "netsum1"
Ports [2, 1]
Position [720, 205, 745, 240]
TreatAsAtomicUnit off
MaskDisplay "disp('+')"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
System {
Name "netsum1"
Location [320, 85, 820, 386]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
Block {
BlockType Inport
Name "In1"
Position [20, 65, 40, 85]
}
Block {
BlockType Inport
Name "In2"
Position [20, 105, 40, 125]
Port "2"
}
Block {
BlockType Sum
Name "netsum1"
Ports [2, 1]
Position [90, 60, 115, 95]
Inputs "2"
}
Block {
BlockType Outport
Name "Out1"
Position [145, 80, 165, 100]
}
Line {
SrcBlock "In1"
SrcPort 1
DstBlock "netsum1"
DstPort 1
}
Line {
SrcBlock "In2"
SrcPort 1
DstBlock "netsum1"
DstPort 2
}
Line {
SrcBlock "netsum1"
SrcPort 1
DstBlock "Out1"
DstPort 1
}
}
}
Block {
BlockType SubSystem
Name "netsum2"
Ports [2, 1]
Position [550, 334, 575, 376]
TreatAsAtomicUnit off
MaskDisplay "disp('+')"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
System {
Name "netsum2"
Location [322, 87, 822, 388]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
Block {
BlockType Inport
Name "In1"
Position [20, 50, 40, 70]
}
Block {
BlockType Inport
Name "In2"
Position [20, 90, 40, 110]
Port "2"
}
Block {
BlockType Sum
Name "netsum"
Ports [2, 1]
Position [90, 59, 115, 101]
Inputs "2"
}
Block {
BlockType Outport
Name "Out1"
Position [145, 80, 165, 100]
}
Line {
SrcBlock "In1"
SrcPort 1
DstBlock "netsum"
DstPort 1
}
Line {
SrcBlock "In2"
SrcPort 1
DstBlock "netsum"
DstPort 2
}
Line {
SrcBlock "netsum"
SrcPort 1
DstBlock "Out1"
DstPort 1
}
}
}
Block {
BlockType SubSystem
Name "netsum3"
Ports [2, 1]
Position [720, 345, 745, 380]
TreatAsAtomicUnit off
MaskDisplay "disp('+')"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
System {
Name "netsum3"
Location [320, 85, 820, 386]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
Block {
BlockType Inport
Name "In1"
Position [20, 65, 40, 85]
}
Block {
BlockType Inport
Name "In2"
Position [20, 105, 40, 125]
Port "2"
}
Block {
BlockType Sum
Name "netsum1"
Ports [2, 1]
Position [90, 60, 115, 95]
Inputs "2"
}
Block {
BlockType Outport
Name "Out1"
Position [145, 80, 165, 100]
}
Line {
SrcBlock "In1"
SrcPort 1
DstBlock "netsum1"
DstPort 1
}
Line {
SrcBlock "In2"
SrcPort 1
DstBlock "netsum1"
DstPort 2
}
Line {
SrcBlock "netsum1"
SrcPort 1
DstBlock "Out1"
DstPort 1
}
}
}
Block {
BlockType SubSystem
Name "purelin"
Ports [1, 1]
Position [770, 213, 795, 237]
TreatAsAtomicUnit off
MaskDisplay "plot([-1 1],[0 0],[-1 1],[-1 1])"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
System {
Name "purelin"
Location [146, 220, 406, 302]
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]
}
Block {
BlockType Outport
Name "a"
Position [205, 33, 235, 47]
}
Line {
SrcBlock "n"
SrcPort 1
DstBlock "a"
DstPort 1
}
}
}
Block {
BlockType SubSystem
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -