📄 narayana.mdl
字号:
BlockType BusCreator
Inputs "4"
DisplayOption "none"
BusObject "BusObject"
NonVirtualBus off
}
Block {
BlockType Constant
Value "1"
VectorParams1D on
OutDataTypeMode "Inherit from 'Constant value'"
OutDataType "sfix(16)"
ConRadixGroup "Use specified scaling"
OutScaling "2^0"
SampleTime "inf"
}
Block {
BlockType DataTypeConversion
OutDataTypeMode "Inherit via back propagation"
OutDataType "sfix(16)"
OutScaling "2^0"
LockScale off
ConvertRealWorld "Real World Value (RWV)"
RndMeth "Zero"
SaturateOnIntegerOverflow on
SampleTime "-1"
}
Block {
BlockType Demux
Outputs "4"
DisplayOption "none"
BusSelectionMode off
}
Block {
BlockType Derivative
LinearizePole "inf"
}
Block {
BlockType Gain
Gain "1"
Multiplication "Element-wise(K.*u)"
ParameterDataTypeMode "Same as input"
ParameterDataType "sfix(16)"
ParameterScalingMode "Best Precision: Matrix-wise"
ParameterScaling "2^0"
OutDataTypeMode "Same as input"
OutDataType "sfix(16)"
OutScaling "2^0"
LockScale off
RndMeth "Floor"
SaturateOnIntegerOverflow on
SampleTime "-1"
}
Block {
BlockType If
NumInputs "1"
IfExpression "u1 > 0"
ShowElse on
ZeroCross on
SampleTime "-1"
}
Block {
BlockType Inport
BusObject "BusObject"
BusOutputAsStruct off
PortDimensions "-1"
SampleTime "-1"
DataType "auto"
OutDataType "sfix(16)"
OutScaling "2^0"
SignalType "auto"
SamplingMode "auto"
Interpolate on
}
Block {
BlockType Math
Operator "exp"
OutputSignalType "auto"
SampleTime "-1"
OutDataTypeMode "Same as first input"
OutDataType "sfix(16)"
OutScaling "2^0"
LockScale off
RndMeth "Floor"
SaturateOnIntegerOverflow on
}
Block {
BlockType Merge
Inputs "2"
InitialOutput "[]"
AllowUnequalInputPortWidths off
InputPortOffsets "[]"
}
Block {
BlockType MinMax
Function "min"
Inputs "1"
InputSameDT on
OutDataTypeMode "Inherit via internal rule"
OutDataType "sfix(16)"
OutScaling "2^0"
LockScale off
RndMeth "Floor"
SaturateOnIntegerOverflow on
ZeroCross on
SampleTime "-1"
}
Block {
BlockType Mux
Inputs "4"
DisplayOption "none"
BusObject "BusObject"
NonVirtualBus off
}
Block {
BlockType Outport
Port "1"
BusObject "BusObject"
BusOutputAsStruct off
PortDimensions "-1"
SampleTime "-1"
DataType "auto"
OutDataType "sfix(16)"
OutScaling "2^0"
SignalType "auto"
SamplingMode "auto"
OutputWhenDisabled "held"
InitialOutput "[]"
}
Block {
BlockType Product
Inputs "2"
Multiplication "Element-wise(.*)"
InputSameDT on
OutDataTypeMode "Same as first input"
OutDataType "sfix(16)"
OutScaling "2^0"
LockScale off
RndMeth "Zero"
SaturateOnIntegerOverflow on
SampleTime "-1"
}
Block {
BlockType RelationalOperator
Operator ">="
InputSameDT on
LogicOutDataTypeMode "Logical (see Configuration Parameters: Optimiza"
"tion)"
LogicDataType "uint(8)"
ZeroCross on
SampleTime "-1"
}
Block {
BlockType Scope
Floating off
ModelBased off
TickLabels "OneTimeTick"
ZoomMode "on"
Grid "on"
TimeRange "auto"
YMin "-5"
YMax "5"
SaveToWorkspace off
SaveName "ScopeData"
LimitDataPoints on
MaxDataPoints "5000"
Decimation "1"
SampleInput off
SampleTime "0"
}
Block {
BlockType "S-Function"
FunctionName "system"
PortCounts "[]"
SFunctionModules "''"
}
Block {
BlockType SubSystem
ShowPortLabels on
Permissions "ReadWrite"
PermitHierarchicalResolution "All"
SystemSampleTime "-1"
RTWFcnNameOpts "Auto"
RTWFileNameOpts "Auto"
SimViewingDevice off
DataTypeOverride "UseLocalSettings"
MinMaxOverflowLogging "UseLocalSettings"
}
Block {
BlockType Sum
IconShape "rectangular"
Inputs "++"
InputSameDT on
OutDataTypeMode "Same as first input"
OutDataType "sfix(16)"
OutScaling "2^0"
LockScale off
RndMeth "Floor"
SaturateOnIntegerOverflow on
SampleTime "-1"
}
Block {
BlockType Switch
Criteria "u2 >= Threshold"
Threshold "0"
InputSameDT on
OutDataTypeMode "Inherit via internal rule"
RndMeth "Floor"
SaturateOnIntegerOverflow on
ZeroCross on
SampleTime "-1"
}
Block {
BlockType Terminator
}
Block {
BlockType ZeroOrderHold
SampleTime "1"
}
}
AnnotationDefaults {
HorizontalAlignment "center"
VerticalAlignment "middle"
ForegroundColor "black"
BackgroundColor "white"
DropShadow off
FontName "Helvetica"
FontSize 10
FontWeight "normal"
FontAngle "normal"
}
LineDefaults {
FontName "Helvetica"
FontSize 9
FontWeight "normal"
FontAngle "normal"
}
System {
Name "narayana"
Location [480, 93, 1060, 386]
Open on
ModelBrowserVisibility off
ModelBrowserWidth 200
ScreenColor "white"
PaperOrientation "landscape"
PaperPositionMode "auto"
PaperType "usletter"
PaperUnits "inches"
ZoomFactor "100"
ReportName "simulink-default.rpt"
Block {
BlockType Inport
Name "In1"
Position [90, 88, 120, 102]
Port "1"
IconDisplay "Port number"
DataType "uint8"
LatchInput off
}
Block {
BlockType BusCreator
Name "Bus\nCreator"
Ports [2, 1]
Position [330, 76, 335, 114]
ShowName off
DialogController "Simulink.DDGSource_Bus"
Inputs "2"
DisplayOption "bar"
}
Block {
BlockType Constant
Name "Constant"
Position [100, 30, 130, 60]
OutDataTypeMode "uint8"
}
Block {
BlockType DataTypeConversion
Name "Data Type Conversion"
Position [365, 73, 440, 107]
FontSize 10
OutDataTypeMode "uint16"
RndMeth "Floor"
SaturateOnIntegerOverflow off
}
Block {
BlockType DataTypeConversion
Name "Data Type Conversion1"
Position [170, 128, 245, 162]
FontSize 10
OutDataTypeMode "double"
RndMeth "Floor"
SaturateOnIntegerOverflow off
}
Block {
BlockType DataTypeConversion
Name "Data Type Conversion2"
Position [210, 228, 285, 262]
FontSize 10
OutDataTypeMode "uint8"
RndMeth "Floor"
SaturateOnIntegerOverflow off
}
Block {
BlockType Derivative
Name "Derivative"
Position [15, 134, 65, 166]
Orientation "left"
LinearizePole "1"
MaskIconFrame on
MaskIconOpaque on
MaskIconRotate "none"
MaskIconUnits "autoscale"
}
Block {
BlockType Reference
Name "Fuzzy Logic \nController \nwith Ruleviewer"
Ports [1, 1]
Position [415, 180, 475, 230]
FontSize 10
SourceBlock "fuzblock/Fuzzy Logic \nController \nwith Rulevi"
"ewer"
SourceType "FIS"
ShowPortLabels on
fismatrix "narayanaa"
Ts "2"
}
Block {
BlockType Scope
Name "Scope"
Ports [1]
Position [535, 184, 565, 216]
Location [188, 390, 512, 629]
Open off
NumInputPorts "1"
List {
ListType AxesTitles
axes1 "%<SignalLabel>"
}
DataFormat "StructureWithTime"
}
Block {
BlockType Sum
Name "Sum1"
Ports [2, 1]
Position [185, 40, 205, 80]
Inputs "+-"
OutDataTypeMode "uint8"
}
Line {
SrcBlock "Sum1"
SrcPort 1
Points [0, -5; 5, 0; 0, 30; 10, 0]
Branch {
DstBlock "Bus\nCreator"
DstPort 1
}
Branch {
Points [-70, 0]
DstBlock "Data Type Conversion1"
DstPort 1
}
}
Line {
SrcBlock "Constant"
SrcPort 1
Points [0, 5]
DstBlock "Sum1"
DstPort 1
}
Line {
SrcBlock "In1"
SrcPort 1
Points [20, 0; 0, -25]
DstBlock "Sum1"
DstPort 2
}
Line {
SrcBlock "Data Type Conversion1"
SrcPort 1
Points [15, 0; 0, 35; -185, 0]
DstBlock "Derivative"
DstPort 1
}
Line {
SrcBlock "Derivative"
SrcPort 1
Points [-10, 0; 0, 95]
DstBlock "Data Type Conversion2"
DstPort 1
}
Line {
SrcBlock "Data Type Conversion2"
SrcPort 1
Points [10, 0; 0, -140]
DstBlock "Bus\nCreator"
DstPort 2
}
Line {
SrcBlock "Fuzzy Logic \nController \nwith Ruleviewer"
SrcPort 1
Points [20, 0; 0, -5]
DstBlock "Scope"
DstPort 1
}
Line {
SrcBlock "Bus\nCreator"
SrcPort 1
Points [5, 0; 0, -5]
DstBlock "Data Type Conversion"
DstPort 1
}
Line {
SrcBlock "Data Type Conversion"
SrcPort 1
Points [15, 0; 0, 80; -60, 0]
DstBlock "Fuzzy Logic \nController \nwith Ruleviewer"
DstPort 1
}
Annotation {
Position [204, 209]
}
Annotation {
Position [145, 211]
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -