📄 chap2_2.mdl
字号:
LimitMaxRows on
MaxRows "500000"
Decimation "1"
SampleInput off
SampleTime "0"
}
Block {
BlockType Scope
Name "Scope2"
Ports [1, 0, 0, 0, 0]
Position [325, 109, 355, 141]
Floating off
Location [107, 290, 721, 529]
Open off
NumInputPorts "1"
TickLabels "OneTimeTick"
ZoomMode "xonly"
List {
ListType AxesTitles
axes1 "%<SignalLabel>"
}
Grid "on"
TimeRange "auto"
YMin "-5"
YMax "5"
SaveToWorkspace off
SaveName "ScopeData"
DataFormat "StructureWithTime"
LimitMaxRows on
MaxRows "50000"
Decimation "1"
SampleInput off
SampleTime "0"
}
Block {
BlockType SignalGenerator
Name "Signal\nGenerator1"
Position [70, 165, 100, 195]
WaveForm "sine"
Amplitude "0.5"
Frequency "3"
Units "Hertz"
}
Block {
BlockType SubSystem
Name "Subsystem"
Ports [1, 1, 0, 0, 0]
Position [400, 146, 445, 214]
ShowPortLabels on
System {
Name "Subsystem"
Location [-4, 78, 792, 559]
Open off
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "automatic"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
AutoZoom on
Block {
BlockType Inport
Name "In1"
Position [125, 188, 155, 202]
Port "1"
PortWidth "-1"
SampleTime "-1"
DataType "auto"
SignalType "auto"
Interpolate on
}
Block {
BlockType Integrator
Name " 1"
Ports [1, 1, 0, 0, 0]
Position [405, 174, 430, 216]
ExternalReset "none"
InitialConditionSource "internal"
InitialCondition "0"
LimitOutput off
UpperSaturationLimit "inf"
LowerSaturationLimit "-inf"
ShowSaturationPort off
ShowStatePort off
AbsoluteTolerance "auto"
}
Block {
BlockType Integrator
Name " 2"
Ports [1, 1, 0, 0, 0]
Position [280, 174, 305, 216]
ExternalReset "none"
InitialConditionSource "internal"
InitialCondition "0"
LimitOutput off
UpperSaturationLimit "inf"
LowerSaturationLimit "-inf"
ShowSaturationPort off
ShowStatePort off
AbsoluteTolerance "auto"
}
Block {
BlockType Clock
Name "Clock1"
Position [190, 90, 210, 110]
DisplayTime on
Decimation "1"
}
Block {
BlockType Clock
Name "Clock2"
Position [560, 315, 580, 335]
Orientation "left"
DisplayTime on
Decimation "1"
}
Block {
BlockType Constant
Name "Constant"
Position [310, 15, 340, 45]
Value "133"
}
Block {
BlockType Constant
Name "Constant1"
Position [385, 390, 415, 420]
Orientation "left"
Value "25"
}
Block {
BlockType Fcn
Name "Fcn "
Position [255, 81, 375, 119]
Expr "50*sin(1*2*pi*u)"
}
Block {
BlockType Fcn
Name "Fcn2"
Position [370, 305, 490, 345]
Orientation "left"
Expr "5*sin(3*2*pi*u)"
}
Block {
BlockType Gain
Name "Gain"
Position [280, 270, 310, 300]
Orientation "left"
NamePlacement "alternate"
Gain "1"
SaturateOnIntegerOverflow on
}
Block {
BlockType Product
Name "Product"
Ports [2, 1, 0, 0, 0]
Position [555, 123, 580, 172]
Inputs "2"
SaturateOnIntegerOverflow on
}
Block {
BlockType Product
Name "Product1"
Ports [2, 1, 0, 0, 0]
Position [220, 263, 250, 347]
Orientation "left"
NamePlacement "alternate"
Inputs "2"
SaturateOnIntegerOverflow on
}
Block {
BlockType Sum
Name "Sum"
Ports [2, 1, 0, 0, 0]
Position [180, 185, 200, 205]
ShowName off
IconShape "round"
Inputs "|+-"
SaturateOnIntegerOverflow on
}
Block {
BlockType Sum
Name "Sum1"
Ports [2, 1, 0, 0, 0]
Position [435, 20, 455, 40]
ShowName off
IconShape "round"
Inputs "|++"
SaturateOnIntegerOverflow on
}
Block {
BlockType Sum
Name "Sum2"
Ports [2, 1, 0, 0, 0]
Position [315, 315, 335, 335]
Orientation "left"
NamePlacement "alternate"
ShowName off
IconShape "round"
Inputs "|++"
SaturateOnIntegerOverflow on
}
Block {
BlockType Outport
Name "Out1"
Position [605, 143, 635, 157]
Port "1"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Line {
SrcBlock "Sum"
SrcPort 1
DstBlock " 2"
DstPort 1
}
Line {
SrcBlock "Clock1"
SrcPort 1
DstBlock "Fcn "
DstPort 1
}
Line {
SrcBlock " 1"
SrcPort 1
Points [105, 0]
DstBlock "Product"
DstPort 2
}
Line {
SrcBlock " 2"
SrcPort 1
Points [40, 0]
Branch {
DstBlock " 1"
DstPort 1
}
Branch {
Points [0, 90]
DstBlock "Gain"
DstPort 1
}
}
Line {
SrcBlock "Clock2"
SrcPort 1
DstBlock "Fcn2"
DstPort 1
}
Line {
SrcBlock "Gain"
SrcPort 1
DstBlock "Product1"
DstPort 1
}
Line {
SrcBlock "Product1"
SrcPort 1
Points [-25, 0]
DstBlock "Sum"
DstPort 2
}
Line {
SrcBlock "Product"
SrcPort 1
DstBlock "Out1"
DstPort 1
}
Line {
SrcBlock "In1"
SrcPort 1
DstBlock "Sum"
DstPort 1
}
Line {
SrcBlock "Fcn "
SrcPort 1
Points [65, 0]
DstBlock "Sum1"
DstPort 2
}
Line {
SrcBlock "Constant"
SrcPort 1
DstBlock "Sum1"
DstPort 1
}
Line {
SrcBlock "Sum1"
SrcPort 1
Points [80, 0]
DstBlock "Product"
DstPort 1
}
Line {
SrcBlock "Fcn2"
SrcPort 1
DstBlock "Sum2"
DstPort 1
}
Line {
SrcBlock "Sum2"
SrcPort 1
DstBlock "Product1"
DstPort 2
}
Line {
SrcBlock "Constant1"
SrcPort 1
Points [-55, 0]
DstBlock "Sum2"
DstPort 2
}
}
}
Block {
BlockType Sum
Name "Sum"
Ports [2, 1, 0, 0, 0]
Position [145, 170, 165, 190]
ShowName off
IconShape "round"
Inputs "|+-"
SaturateOnIntegerOverflow on
}
Line {
SrcBlock "Mux"
SrcPort 1
DstBlock "Scope"
DstPort 1
}
Line {
SrcBlock "SMC Controller"
SrcPort 1
Points [35, 0]
Branch {
Points [0, -55]
DstBlock "Scope2"
DstPort 1
}
Branch {
DstBlock "Subsystem"
DstPort 1
}
}
Line {
SrcBlock "Signal\nGenerator1"
SrcPort 1
Points [20, 0]
Branch {
DstBlock "Sum"
DstPort 1
}
Branch {
Points [0, -100; 420, 0; 0, 70]
DstBlock "Mux"
DstPort 1
}
}
Line {
SrcBlock "Sum"
SrcPort 1
DstBlock "SMC Controller"
DstPort 1
}
Line {
SrcBlock "Subsystem"
SrcPort 1
Points [95, 0]
Branch {
DstBlock "Mux"
DstPort 2
}
Branch {
Points [0, 105; -390, 0]
DstBlock "Sum"
DstPort 2
}
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -