Model { Name "MarkIVRevJt" Version 7.2 MdlSubVersion 0 GraphicalInterface { NumRootInports 0 NumRootOutports 0 ParameterArgumentNames "" ComputedModelVersion "1.214" NumModelReferences 0 NumTestPointedSignals 0 } SavedCharacterEncoding "windows-1252" SaveDefaultBlockParams on ScopeRefreshTime 0.035000 OverrideScopeRefreshTime on DisableAllScopes off DataTypeOverride "UseLocalSettings" MinMaxOverflowLogging "UseLocalSettings" MinMaxOverflowArchiveMode "Overwrite" Created "Mon Jan 19 17:04:53 2009" Creator "Keith Wakeham" UpdateHistory "UpdateHistoryNever" ModifiedByFormat "%" LastModifiedBy "Keith Wakeham" ModifiedDateFormat "%" LastModifiedDate "Fri Apr 03 13:41:04 2009" RTWModifiedTimeStamp 0 ModelVersionFormat "1.%" ConfigurationManager "None" SampleTimeColors off SampleTimeAnnotations off LibraryLinkDisplay "none" WideLines off ShowLineDimensions off ShowPortDataTypes off ShowLoopsOnError on IgnoreBidirectionalLines off ShowStorageClass off ShowTestPointIcons on ShowSignalResolutionIcons on ShowViewerIcons on SortedOrder off ExecutionContextIcon off ShowLinearizationAnnotations on BlockNameDataTip off BlockParametersDataTip off BlockDescriptionStringDataTip off ToolBar on StatusBar on BrowserShowLibraryLinks off BrowserLookUnderMasks off SimulationMode "normal" LinearizationMsg "none" Profile off ParamWorkspaceSource "MATLABWorkspace" AccelSystemTargetFile "accel.tlc" AccelTemplateMakefile "accel_default_tmf" AccelMakeCommand "make_rtw" TryForcingSFcnDF off RecordCoverage off CovPath "/" CovSaveName "covdata" CovMetricSettings "dw" CovNameIncrementing off CovHtmlReporting on covSaveCumulativeToWorkspaceVar on CovSaveSingleToWorkspaceVar on CovCumulativeVarName "covCumulativeData" CovCumulativeReport off CovReportOnPause on CovModelRefEnable "Off" ExtModeBatchMode off ExtModeEnableFloating on ExtModeTrigType "manual" ExtModeTrigMode "normal" ExtModeTrigPort "1" ExtModeTrigElement "any" ExtModeTrigDuration 1000 ExtModeTrigDurationFloating "auto" ExtModeTrigHoldOff 0 ExtModeTrigDelay 0 ExtModeTrigDirection "rising" ExtModeTrigLevel 0 ExtModeArchiveMode "off" ExtModeAutoIncOneShot off ExtModeIncDirWhenArm off ExtModeAddSuffixToVar off ExtModeWriteAllDataToWs off ExtModeArmWhenConnect on ExtModeSkipDownloadWhenConnect off ExtModeLogAll on ExtModeAutoUpdateStatusClock on BufferReuse on ShowModelReferenceBlockVersion off ShowModelReferenceBlockIO off Array { Type "Handle" Dimension 1 Simulink.ConfigSet { $ObjectID 1 Version "1.5.1" Array { Type "Handle" Dimension 9 Simulink.SolverCC { $ObjectID 2 Version "1.5.1" StartTime "0" StopTime ".6" AbsTol "auto" FixedStep ".00003" InitialStep "auto" MaxNumMinSteps "-1" MaxOrder 5 ZcThreshold "auto" ConsecutiveZCsStepRelTol "10*128*eps" MaxConsecutiveZCs "1000" ExtrapolationOrder 4 NumberNewtonIterations 1 MaxStep "0.00003" MinStep "auto" MaxConsecutiveMinStep "1" RelTol "1e-6" SolverMode "Auto" Solver "ode45" SolverName "ode45" ShapePreserveControl "DisableAll" ZeroCrossControl "UseLocalSettings" ZeroCrossAlgorithm "Nonadaptive" AlgebraicLoopSolver "TrustRegion" SolverResetMethod "Fast" PositivePriorityOrder off AutoInsertRateTranBlk off SampleTimeConstraint "Unconstrained" InsertRTBMode "Whenever possible" SignalSizeVariationType "Allow only fixed size" } Simulink.DataIOCC { $ObjectID 3 Version "1.5.1" Decimation "1" ExternalInput "[t, u]" FinalStateName "xFinal" InitialState "xInitial" LimitDataPoints on MaxDataPoints "10000" LoadExternalInput off LoadInitialState off SaveFinalState off SaveFormat "Array" SaveOutput on SaveState off SignalLogging on InspectSignalLogs off SaveTime on StateSaveName "xout" TimeSaveName "tout" OutputSaveName "yout" SignalLoggingName "logsout" OutputOption "RefineOutputTimes" OutputTimes "[]" Refine "1" } Simulink.OptimizationCC { $ObjectID 4 Version "1.5.1" Array { Type "Cell" Dimension 4 Cell "ZeroExternalMemoryAtStartup" Cell "ZeroInternalMemoryAtStartup" Cell "OptimizeModelRefInitCode" Cell "NoFixptDivByZeroProtection" PropName "DisabledProps" } BlockReduction on BooleanDataType on ConditionallyExecuteInputs on InlineParams off InlineInvariantSignals off OptimizeBlockIOStorage on BufferReuse on EnhancedBackFolding off EnforceIntegerDowncast on ExpressionFolding on EnableMemcpy on MemcpyThreshold 64 ExpressionDepthLimit 2147483647 FoldNonRolledExpr on LocalBlockOutputs on RollThreshold 5 SystemCodeInlineAuto off StateBitsets off DataBitsets off UseTempVars off ZeroExternalMemoryAtStartup on ZeroInternalMemoryAtStartup on InitFltsAndDblsToZero off NoFixptDivByZeroProtection off EfficientFloat2IntCast off EfficientMapNaN2IntZero on OptimizeModelRefInitCode off LifeSpan "inf" BufferReusableBoundary on SimCompilerOptimization "Off" AccelVerboseBuild off } Simulink.DebuggingCC { $ObjectID 5 Version "1.5.1" RTPrefix "error" ConsistencyChecking "none" ArrayBoundsChecking "none" SignalInfNanChecking "none" SignalRangeChecking "none" ReadBeforeWriteMsg "UseLocalSettings" WriteAfterWriteMsg "UseLocalSettings" WriteAfterReadMsg "UseLocalSettings" AlgebraicLoopMsg "warning" ArtificialAlgebraicLoopMsg "warning" SaveWithDisabledLinksMsg "warning" SaveWithParameterizedLinksMsg "warning" CheckSSInitialOutputMsg on UnderspecifiedInitializationDetection "Classic" MergeDetectMultiDrivingBlocksExec "none" CheckExecutionContextPreStartOutputMsg off CheckExecutionContextRuntimeOutputMsg off SignalResolutionControl "UseLocalSettings" BlockPriorityViolationMsg "warning" MinStepSizeMsg "warning" TimeAdjustmentMsg "none" MaxConsecutiveZCsMsg "error" SolverPrmCheckMsg "warning" InheritedTsInSrcMsg "warning" DiscreteInheritContinuousMsg "warning" MultiTaskDSMMsg "error" MultiTaskCondExecSysMsg "error" MultiTaskRateTransMsg "error" SingleTaskRateTransMsg "none" TasksWithSamePriorityMsg "warning" SigSpecEnsureSampleTimeMsg "warning" CheckMatrixSingularityMsg "none" IntegerOverflowMsg "warning" Int32ToFloatConvMsg "warning" ParameterDowncastMsg "error" ParameterOverflowMsg "error" ParameterUnderflowMsg "none" ParameterPrecisionLossMsg "warning" ParameterTunabilityLossMsg "warning" UnderSpecifiedDataTypeMsg "none" UnnecessaryDatatypeConvMsg "none" VectorMatrixConversionMsg "none" InvalidFcnCallConnMsg "error" FcnCallInpInsideContextMsg "Use local settings" SignalLabelMismatchMsg "none" UnconnectedInputMsg "warning" UnconnectedOutputMsg "warning" UnconnectedLineMsg "warning" SFcnCompatibilityMsg "none" UniqueDataStoreMsg "none" BusObjectLabelMismatch "warning" RootOutportRequireBusObject "warning" AssertControl "UseLocalSettings" EnableOverflowDetection off ModelReferenceIOMsg "none" ModelReferenceVersionMismatchMessage "none" ModelReferenceIOMismatchMessage "none" ModelReferenceCSMismatchMessage "none" UnknownTsInhSupMsg "warning" ModelReferenceDataLoggingMessage "warning" ModelReferenceSymbolNameMessage "warning" ModelReferenceExtraNoncontSigs "error" StateNameClashWarn "warning" StrictBusMsg "Warning" LoggingUnavailableSignals "error" BlockIODiagnostic "none" } Simulink.HardwareCC { $ObjectID 6 Version "1.5.1" ProdBitPerChar 8 ProdBitPerShort 16 ProdBitPerInt 32 ProdBitPerLong 32 ProdIntDivRoundTo "Undefined" ProdEndianess "Unspecified" ProdWordSize 32 ProdShiftRightIntArith on ProdHWDeviceType "32-bit Generic" TargetBitPerChar 8 TargetBitPerShort 16 TargetBitPerInt 32 TargetBitPerLong 32 TargetShiftRightIntArith on TargetIntDivRoundTo "Undefined" TargetEndianess "Unspecified" TargetWordSize 32 TargetTypeEmulationWarnSuppressLevel 0 TargetPreprocMaxBitsSint 32 TargetPreprocMaxBitsUint 32 TargetHWDeviceType "Specified" TargetUnknown off ProdEqTarget on } Simulink.ModelReferenceCC { $ObjectID 7 Version "1.5.1" UpdateModelReferenceTargets "IfOutOfDateOrStructuralChange" CheckModelReferenceTargetMessage "error" ModelReferenceNumInstancesAllowed "Multi" ModelReferencePassRootInputsByReference on ModelReferenceMinAlgLoopOccurrences off } Simulink.SFSimCC { $ObjectID 8 Version "1.5.1" SFSimEnableDebug on SFSimOverflowDetection on SFSimEcho on SimUseLocalCustomCode off SimBuildMode "sf_incremental_build" } Simulink.RTWCC { $BackupClass "Simulink.RTWCC" $ObjectID 9 Version "1.5.1" Array { Type "Cell" Dimension 6 Cell "IncludeHyperlinkInReport" Cell "GenerateTraceInfo" Cell "GenerateTraceReport" Cell "GenerateTraceReportSl" Cell "GenerateTraceReportSf" Cell "GenerateTraceReportEml" PropName "DisabledProps" } SystemTargetFile "grt.tlc" GenCodeOnly off MakeCommand "make_rtw" GenerateMakefile on TemplateMakefile "grt_default_tmf" GenerateReport off SaveLog off RTWVerbose on RetainRTWFile off ProfileTLC off TLCDebug off TLCCoverage off TLCAssert off ProcessScriptMode "Default" ConfigurationMode "Optimized" ConfigAtBuild off RTWUseLocalCustomCode off RTWUseSimCustomCode off IncludeHyperlinkInReport off LaunchReport off TargetLang "C" IncludeBusHierarchyInRTWFileBlockHierarchyMap off IncludeERTFirstTime off GenerateTraceInfo off GenerateTraceReport off GenerateTraceReportSl off GenerateTraceReportSf off GenerateTraceReportEml off GenerateCodeInfo off RTWCompilerOptimization "Off" Array { Type "Handle" Dimension 2 Simulink.CodeAppCC { $ObjectID 10 Version "1.5.1" Array { Type "Cell" Dimension 17 Cell "IgnoreCustomStorageClasses" Cell "IgnoreTestpoints" Cell "InsertBlockDesc" Cell "SFDataObjDesc" Cell "SimulinkDataObjDesc" Cell "DefineNamingRule" Cell "SignalNamingRule" Cell "ParamNamingRule" Cell "InlinedPrmAccess" Cell "CustomSymbolStr" Cell "CustomSymbolStrGlobalVar" Cell "CustomSymbolStrType" Cell "CustomSymbolStrField" Cell "CustomSymbolStrFcn" Cell "CustomSymbolStrBlkIO" Cell "CustomSymbolStrTmpVar" Cell "CustomSymbolStrMacro" PropName "DisabledProps" } ForceParamTrailComments off GenerateComments on IgnoreCustomStorageClasses on IgnoreTestpoints off IncHierarchyInIds off MaxIdLength 31 PreserveName off PreserveNameWithParent off ShowEliminatedStatement off IncAutoGenComments off SimulinkDataObjDesc off SFDataObjDesc off IncDataTypeInIds off MangleLength 1 CustomSymbolStrGlobalVar "$R$N$M" CustomSymbolStrType "$N$R$M" CustomSymbolStrField "$N$M" CustomSymbolStrFcn "$R$N$M$F" CustomSymbolStrBlkIO "rtb_$N$M" CustomSymbolStrTmpVar "$N$M" CustomSymbolStrMacro "$R$N$M" DefineNamingRule "None" ParamNamingRule "None" SignalNamingRule "None" InsertBlockDesc off SimulinkBlockComments on EnableCustomComments off InlinedPrmAccess "Literals" ReqsInCode off UseSimReservedNames off } Simulink.GRTTargetCC { $BackupClass "Simulink.TargetCC" $ObjectID 11 Version "1.5.1" Array { Type "Cell" Dimension 16 Cell "IncludeMdlTerminateFcn" Cell "CombineOutputUpdateFcns" Cell "SuppressErrorStatus" Cell "ERTCustomFileBanners" Cell "GenerateSampleERTMain" Cell "GenerateTestInterfaces" Cell "ModelStepFunctionPrototypeControlCompliant" Cell "CPPClassGenCompliant" Cell "MultiInstanceERTCode" Cell "PurelyIntegerCode" Cell "SupportNonFinite" Cell "SupportComplex" Cell "SupportAbsoluteTime" Cell "SupportContinuousTime" Cell "SupportNonInlinedSFcns" Cell "PortableWordSizes" PropName "DisabledProps" } TargetFcnLib "ansi_tfl_table_tmw.mat" TargetLibSuffix "" TargetPreCompLibLocation "" TargetFunctionLibrary "ANSI_C" UtilityFuncGeneration "Auto" ERTMultiwordTypeDef "System defined" ERTMultiwordLength 256 MultiwordLength 2048 GenerateFullHeader on GenerateSampleERTMain off GenerateTestInterfaces off IsPILTarget off ModelReferenceCompliant on CompOptLevelCompliant on IncludeMdlTerminateFcn on CombineOutputUpdateFcns off SuppressErrorStatus off ERTFirstTimeCompliant off IncludeFileDelimiter "Auto" ERTCustomFileBanners off SupportAbsoluteTime on LogVarNameModifier "rt_" MatFileLogging on MultiInstanceERTCode off SupportNonFinite on SupportComplex on PurelyIntegerCode off SupportContinuousTime on SupportNonInlinedSFcns on EnableShiftOperators on ParenthesesLevel "Nominal" PortableWordSizes off ModelStepFunctionPrototypeControlCompliant off CPPClassGenCompliant off AutosarCompliant off UseMalloc off ExtMode off ExtModeStaticAlloc off ExtModeTesting off ExtModeStaticAllocSize 1000000 ExtModeTransport 0 ExtModeMexFile "ext_comm" ExtModeIntrfLevel "Level1" RTWCAPISignals off RTWCAPIParams off RTWCAPIStates off GenerateASAP2 off } PropName "Components" } } hdlcoderui.hdlcc { $ObjectID 12 Version "1.5.1" Description "HDL Coder custom configuration component" Name "HDL Coder" Array { Type "Cell" Dimension 1 Cell "" PropName "HDLConfigFile" } HDLCActiveTab "0" } PropName "Components" } Name "Configuration" CurrentDlgPage "Solver" ConfigPrmDlgPosition " [ 400, 210, 1280, 840 ] " } PropName "ConfigurationSets" } Simulink.ConfigSet { $PropName "ActiveConfigurationSet" $ObjectID 1 } BlockDefaults { Orientation "right" ForegroundColor "black" BackgroundColor "white" DropShadow off NamePlacement "normal" FontName "Helvetica" FontSize 10 FontWeight "normal" FontAngle "normal" ShowName on } AnnotationDefaults { HorizontalAlignment "center" VerticalAlignment "middle" ForegroundColor "black" BackgroundColor "white" DropShadow off FontName "Helvetica" FontSize 10 FontWeight "normal" FontAngle "normal" UseDisplayTextAsClickCallback off } LineDefaults { FontName "Helvetica" FontSize 9 FontWeight "normal" FontAngle "normal" } BlockParameterDefaults { Block { BlockType Clock DisplayTime off } Block { BlockType Constant Value "1" VectorParams1D on SamplingMode "Sample based" OutMin "[]" OutMax "[]" OutDataTypeMode "Inherit from 'Constant value'" OutDataType "fixdt(1,16,0)" ConRadixGroup "Use specified scaling" OutScaling "[]" OutDataTypeStr "Inherit: Inherit from 'Constant value'" LockScale off SampleTime "inf" FramePeriod "inf" } Block { BlockType Demux Outputs "4" DisplayOption "none" BusSelectionMode off } Block { BlockType Derivative LinearizePole "inf" } Block { BlockType Display Format "short" Decimation "10" Floating off SampleTime "-1" } Block { BlockType Fcn Expr "sin(u[1])" SampleTime "-1" } Block { BlockType Ground } Block { BlockType Inport Port "1" UseBusObject off BusObject "BusObject" BusOutputAsStruct off PortDimensions "-1" SampleTime "-1" OutMin "[]" OutMax "[]" DataType "auto" OutDataType "fixdt(1,16,0)" OutScaling "[]" OutDataTypeStr "Inherit: auto" LockScale off SignalType "auto" SamplingMode "auto" LatchByDelayingOutsideSignal off LatchByCopyingInsideSignal off Interpolate on } Block { BlockType Integrator ExternalReset "none" InitialConditionSource "internal" InitialCondition "0" LimitOutput off UpperSaturationLimit "inf" LowerSaturationLimit "-inf" ShowSaturationPort off ShowStatePort off AbsoluteTolerance "auto" IgnoreLimit off ZeroCross on ContinuousStateAttributes "''" } Block { BlockType Logic Operator "AND" Inputs "2" IconShape "rectangular" AllPortsSameDT on OutDataTypeMode "Logical (see Configuration Parameters: Optimization)" LogicDataType "uint(8)" OutDataTypeStr "Inherit: Logical (see Configuration Parameters: Optimization)" SampleTime "-1" } Block { BlockType Math Operator "exp" OutputSignalType "auto" SampleTime "-1" OutMin "[]" OutMax "[]" OutDataTypeMode "Same as first input" OutDataType "fixdt(1,16,0)" OutScaling "[]" OutDataTypeStr "Inherit: Same as first input" LockScale off RndMeth "Floor" SaturateOnIntegerOverflow on } Block { BlockType Mux Inputs "4" DisplayOption "none" UseBusObject off BusObject "BusObject" NonVirtualBus off } Block { BlockType Outport Port "1" UseBusObject off BusObject "BusObject" BusOutputAsStruct off PortDimensions "-1" SampleTime "-1" OutMin "[]" OutMax "[]" DataType "auto" OutDataType "fixdt(1,16,0)" OutScaling "[]" OutDataTypeStr "Inherit: auto" LockScale off SignalType "auto" SamplingMode "auto" SourceOfInitialOutputValue "Dialog" OutputWhenDisabled "held" InitialOutput "[]" } Block { BlockType Product Inputs "2" Multiplication "Element-wise(.*)" CollapseMode "All dimensions" CollapseDim "1" InputSameDT on OutMin "[]" OutMax "[]" OutDataTypeMode "Same as first input" OutDataType "fixdt(1,16,0)" OutScaling "[]" OutDataTypeStr "Inherit: Same as first input" LockScale off RndMeth "Zero" SaturateOnIntegerOverflow on SampleTime "-1" } Block { BlockType RelationalOperator Operator ">=" InputSameDT on LogicOutDataTypeMode "Logical (see Configuration Parameters: Optimization)" LogicDataType "uint(8)" OutDataTypeStr "Inherit: Logical (see Configuration Parameters: Optimization)" ZeroCross on SampleTime "-1" } Block { BlockType "S-Function" FunctionName "system" SFunctionModules "''" PortCounts "[]" SFunctionDeploymentMode off } Block { BlockType Scope 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 "-1" } Block { BlockType SubSystem ShowPortLabels "FromPortIcon" Permissions "ReadWrite" PermitHierarchicalResolution "All" TreatAsAtomicUnit off CheckFcnCallInpInsideContextMsg off SystemSampleTime "-1" RTWFcnNameOpts "Auto" RTWFileNameOpts "Auto" RTWMemSecFuncInitTerm "Inherit from model" RTWMemSecFuncExecute "Inherit from model" RTWMemSecDataConstants "Inherit from model" RTWMemSecDataInternal "Inherit from model" RTWMemSecDataParameters "Inherit from model" SimViewingDevice off DataTypeOverride "UseLocalSettings" MinMaxOverflowLogging "UseLocalSettings" } Block { BlockType Sum IconShape "rectangular" Inputs "++" CollapseMode "All dimensions" CollapseDim "1" InputSameDT on AccumDataTypeStr "Inherit: Inherit via internal rule" OutMin "[]" OutMax "[]" OutDataTypeMode "Same as first input" OutDataType "fixdt(1,16,0)" OutScaling "[]" OutDataTypeStr "Inherit: Same as first input" LockScale off RndMeth "Floor" SaturateOnIntegerOverflow on SampleTime "-1" } Block { BlockType Switch Criteria "u2 >= Threshold" Threshold "0" InputSameDT on OutMin "[]" OutMax "[]" OutDataTypeMode "Inherit via internal rule" OutDataType "fixdt(1,16,0)" OutScaling "[]" OutDataTypeStr "Inherit: Inherit via internal rule" LockScale off RndMeth "Floor" SaturateOnIntegerOverflow on ZeroCross on SampleTime "-1" } Block { BlockType Terminator } Block { BlockType ToWorkspace VariableName "simulink_output" MaxDataPoints "1000" Decimation "1" SampleTime "0" FixptAsFi off } Block { BlockType Trigonometry Operator "sin" OutputSignalType "auto" SampleTime "-1" } Block { BlockType UnitDelay X0 "0" SampleTime "1" StateMustResolveToSignalObject off RTWStateStorageClass "Auto" } } System { Name "MarkIVRevJt" Location [2, 82, 1430, 876] Open on ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" ReportName "simulink-default.rpt" Block { BlockType SubSystem Name "Crank Position" Ports [3, 5] Position [235, 60, 355, 240] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Crank Position" Location [148, 96, 1370, 866] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Crank Inertia" Position [110, 128, 140, 142] IconDisplay "Port number" } Block { BlockType Inport Name "Torque" Position [30, 88, 60, 102] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Initial RPM" Position [145, 259, 175, 281] Port "3" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Display Name "Angular Acc" Ports [1] Position [320, 90, 410, 120] Decimation "1" Lockdown off } Block { BlockType SubSystem Name "Average Torque/omega" Ports [4, 1] Position [790, 521, 905, 584] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Average Torque/omega" Location [334, 170, 1187, 566] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "cycle reset" Position [240, 100, 270, 115] Orientation "down" IconDisplay "Port number" } Block { BlockType Inport Name "time" Position [430, 358, 460, 372] Orientation "left" Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "omega" Position [180, 238, 210, 252] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Torque" Position [45, 18, 75, 32] Port "4" IconDisplay "Port number" } Block { BlockType Display Name "Display" Ports [1] Position [695, 175, 785, 205] Decimation "1" Lockdown off } Block { BlockType Display Name "Display1" Ports [1] Position [685, 284, 830, 316] Format "long" Decimation "1" Lockdown off } Block { BlockType Product Name "Divide1" Ports [2, 1] Position [320, 177, 350, 208] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Divide5" Ports [2, 1] Position [425, 282, 455, 313] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Integrator Name "Integrator3" Ports [2, 1] Position [110, 28, 155, 97] ExternalReset "falling" } Block { BlockType Integrator Name "Integrator4" Ports [2, 1] Position [325, 253, 370, 322] ExternalReset "falling" } Block { BlockType Reference Name "Sample\nand Hold1" Ports [1, 1, 0, 1] Position [415, 169, 525, 211] SourceBlock "dspsigops/Sample\nand Hold" SourceType "Sample and Hold" ShowPortLabels "FromPortIcon" SystemSampleTime "-1" FunctionWithSeparateData "off" RTWMemSecFuncInitTerm "Inherit from model" RTWMemSecFuncExecute "Inherit from model" RTWMemSecDataConstants "Inherit from model" RTWMemSecDataInternal "Inherit from model" RTWMemSecDataParameters "Inherit from model" trig "Falling edge" initCond "0" latchinput "off" } Block { BlockType Reference Name "Sample\nand Hold2" Ports [1, 1, 0, 1] Position [505, 280, 600, 320] SourceBlock "dspsigops/Sample\nand Hold" SourceType "Sample and Hold" ShowPortLabels "FromPortIcon" SystemSampleTime "-1" FunctionWithSeparateData "off" RTWMemSecFuncInitTerm "Inherit from model" RTWMemSecFuncExecute "Inherit from model" RTWMemSecDataConstants "Inherit from model" RTWMemSecDataInternal "Inherit from model" RTWMemSecDataParameters "Inherit from model" trig "Falling edge" initCond "0" latchinput "off" } Block { BlockType UnitDelay Name "Unit Delay" Position [210, 288, 245, 322] SampleTime "-1" } Block { BlockType UnitDelay Name "Unit Delay1" Position [45, 63, 80, 97] SampleTime "-1" } Block { BlockType Outport Name "Average torque" Position [700, 98, 730, 112] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock "Integrator4" SrcPort 1 DstBlock "Divide5" DstPort 1 } Line { SrcBlock "Divide5" SrcPort 1 DstBlock "Sample\nand Hold2" DstPort 1 } Line { SrcBlock "Divide1" SrcPort 1 Points [0, -5] DstBlock "Sample\nand Hold1" DstPort 1 } Line { SrcBlock "Unit Delay1" SrcPort 1 DstBlock "Integrator3" DstPort 2 } Line { SrcBlock "Unit Delay" SrcPort 1 DstBlock "Integrator4" DstPort 2 } Line { SrcBlock "Sample\nand Hold2" SrcPort 1 DstBlock "Display1" DstPort 1 } Line { SrcBlock "Sample\nand Hold1" SrcPort 1 Points [110, 0] Branch { DstBlock "Display" DstPort 1 } Branch { Points [0, -85] DstBlock "Average torque" DstPort 1 } } Line { SrcBlock "Integrator3" SrcPort 1 Points [30, 0; 0, 120] DstBlock "Divide1" DstPort 1 } Line { SrcBlock "Torque" SrcPort 1 Points [0, 20] DstBlock "Integrator3" DstPort 1 } Line { SrcBlock "cycle reset" SrcPort 1 Points [0, 15] Branch { Points [0, 10; 215, 0] DstBlock "Sample\nand Hold1" DstPort trigger } Branch { Points [295, 0] DstBlock "Sample\nand Hold2" DstPort trigger } Branch { Points [-160, 0] Branch { Points [0, 170] DstBlock "Unit Delay" DstPort 1 } Branch { Points [-65, 0] DstBlock "Unit Delay1" DstPort 1 } } } Line { SrcBlock "omega" SrcPort 1 Points [0, 25] DstBlock "Integrator4" DstPort 1 } Line { SrcBlock "time" SrcPort 1 Points [-15, 0] Branch { DstBlock "Divide5" DstPort 2 } Branch { Points [-105, 0] DstBlock "Divide1" DstPort 2 } } } } Block { BlockType SubSystem Name "Cycle Time" Ports [1, 1] Position [525, 486, 650, 544] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Cycle Time" Location [848, 354, 1410, 746] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "cycle reset" Position [135, 38, 165, 52] IconDisplay "Port number" } Block { BlockType Clock Name "Clock1" Position [25, 100, 45, 120] Decimation "10" } Block { BlockType Reference Name "Sample\nand Hold3" Ports [1, 1, 0, 1] Position [130, 89, 240, 131] SourceBlock "dspsigops/Sample\nand Hold" SourceType "Sample and Hold" ShowPortLabels "FromPortIcon" SystemSampleTime "-1" FunctionWithSeparateData "off" RTWMemSecFuncInitTerm "Inherit from model" RTWMemSecFuncExecute "Inherit from model" RTWMemSecDataConstants "Inherit from model" RTWMemSecDataInternal "Inherit from model" RTWMemSecDataParameters "Inherit from model" trig "Falling edge" initCond "0" latchinput "off" } Block { BlockType Reference Name "Sample\nand Hold4" Ports [1, 1, 0, 1] Position [330, 164, 440, 206] SourceBlock "dspsigops/Sample\nand Hold" SourceType "Sample and Hold" ShowPortLabels "FromPortIcon" SystemSampleTime "-1" FunctionWithSeparateData "off" RTWMemSecFuncInitTerm "Inherit from model" RTWMemSecFuncExecute "Inherit from model" RTWMemSecDataConstants "Inherit from model" RTWMemSecDataInternal "Inherit from model" RTWMemSecDataParameters "Inherit from model" trig "Falling edge" initCond "0" latchinput "off" } Block { BlockType Reference Name "Sample\nand Hold5" Ports [1, 1, 0, 1] Position [355, 309, 465, 351] SourceBlock "dspsigops/Sample\nand Hold" SourceType "Sample and Hold" ShowPortLabels "FromPortIcon" SystemSampleTime "-1" FunctionWithSeparateData "off" RTWMemSecFuncInitTerm "Inherit from model" RTWMemSecFuncExecute "Inherit from model" RTWMemSecDataConstants "Inherit from model" RTWMemSecDataInternal "Inherit from model" RTWMemSecDataParameters "Inherit from model" trig "Falling edge" initCond "0" latchinput "off" } Block { BlockType Sum Name "Subtract" Ports [2, 1] Position [285, 242, 315, 273] Inputs "+-" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType UnitDelay Name "Unit Delay3" Position [325, 28, 360, 62] SampleTime "-1" } Block { BlockType Outport Name "cycle time" Position [490, 323, 520, 337] IconDisplay "Port number" } Line { SrcBlock "Clock1" SrcPort 1 DstBlock "Sample\nand Hold3" DstPort 1 } Line { SrcBlock "Unit Delay3" SrcPort 1 Points [20, 0] DstBlock "Sample\nand Hold4" DstPort trigger } Line { SrcBlock "Sample\nand Hold4" SrcPort 1 Points [20, 0; 0, 100; -125, 0; 0, 10; -70, 0] DstBlock "Subtract" DstPort 2 } Line { SrcBlock "Sample\nand Hold3" SrcPort 1 Points [5, 0] Branch { Points [30, 0; 0, 75] DstBlock "Sample\nand Hold4" DstPort 1 } Branch { Points [0, 140] DstBlock "Subtract" DstPort 1 } } Line { SrcBlock "Subtract" SrcPort 1 Points [5, 0; 0, 70] DstBlock "Sample\nand Hold5" DstPort 1 } Line { SrcBlock "cycle reset" SrcPort 1 Points [15, 0] Branch { DstBlock "Sample\nand Hold3" DstPort trigger } Branch { Points [110, 0] Branch { DstBlock "Unit Delay3" DstPort 1 } Branch { Points [0, 195; 115, 0] DstBlock "Sample\nand Hold5" DstPort trigger } } } Line { SrcBlock "Sample\nand Hold5" SrcPort 1 DstBlock "cycle time" DstPort 1 } } } Block { BlockType Product Name "Divide" Ports [2, 1] Position [170, 87, 200, 118] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Integrator Name "Integrator1" Ports [2, 1] Position [340, 268, 385, 337] ExternalReset "falling" } Block { BlockType Integrator Name "Integrator2" Ports [2, 1] Position [245, 218, 290, 287] InitialConditionSource "external" } Block { BlockType Scope Name "Omega dot" Ports [1] Position [410, 149, 440, 181] Floating off Location [465, 280, 1199, 782] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "522.5" YMax "523.5" DataFormat "StructureWithTime" SampleTime "0" } Block { BlockType Scope Name "Theta" Ports [1] Position [525, 244, 555, 276] Floating off Location [122, 581, 1234, 808] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "750" SaveName "ScopeData1" DataFormat "StructureWithTime" SampleTime "0" } Block { BlockType Scope Name "Torque1" Ports [1] Position [130, 24, 160, 56] Floating off Location [69, 409, 1402, 863] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "-100" YMax "325" SaveName "ScopeData10" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType SubSystem Name "reset" Ports [1, 1] Position [445, 340, 515, 400] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "reset" Location [488, 403, 868, 602] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "theta" Position [35, 13, 65, 27] IconDisplay "Port number" } Block { BlockType Constant Name "Initial Position" Position [25, 50, 55, 80] Value "3*pi" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Initial Position3" Position [25, 100, 55, 130] Value "4*pi" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Logic Name "Logical\nOperator" Ports [2, 1] Position [210, 52, 240, 83] AllPortsSameDT off OutDataTypeMode "boolean" OutDataTypeStr "boolean" } Block { BlockType RelationalOperator Name "Relational\nOperator" Position [125, 27, 155, 58] InputSameDT off LogicOutDataTypeMode "boolean" OutDataTypeStr "boolean" } Block { BlockType RelationalOperator Name "Relational\nOperator3" Position [120, 92, 150, 123] Operator "<=" InputSameDT off LogicOutDataTypeMode "boolean" OutDataTypeStr "boolean" } Block { BlockType Outport Name "reset" Position [265, 63, 295, 77] IconDisplay "Port number" } Line { SrcBlock "Initial Position" SrcPort 1 Points [50, 0] DstBlock "Relational\nOperator" DstPort 2 } Line { SrcBlock "Initial Position3" SrcPort 1 DstBlock "Relational\nOperator3" DstPort 2 } Line { SrcBlock "Relational\nOperator" SrcPort 1 Points [0, 15] DstBlock "Logical\nOperator" DstPort 1 } Line { SrcBlock "Relational\nOperator3" SrcPort 1 Points [15, 0; 0, -35] DstBlock "Logical\nOperator" DstPort 2 } Line { SrcBlock "theta" SrcPort 1 Points [0, 15; 20, 0] Branch { DstBlock "Relational\nOperator" DstPort 1 } Branch { Points [0, 65] DstBlock "Relational\nOperator3" DstPort 1 } } Line { SrcBlock "Logical\nOperator" SrcPort 1 DstBlock "reset" DstPort 1 } } } Block { BlockType Outport Name "A" Position [380, 28, 410, 42] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Outport Name "w" Position [440, 223, 470, 237] Port "2" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Outport Name "O" Position [645, 298, 675, 312] Port "3" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Outport Name "Cycle Reset" Position [645, 363, 675, 377] Port "4" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Outport Name "Average Torque" Position [970, 558, 1000, 572] Port "5" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock "Divide" SrcPort 1 Points [25, 0] Branch { DstBlock "Angular Acc" DstPort 1 } Branch { Points [0, -70] DstBlock "A" DstPort 1 } Branch { DstBlock "Integrator2" DstPort 1 } } Line { SrcBlock "Integrator2" SrcPort 1 Points [15, 0] Branch { Points [85, 0; 0, -25] Branch { DstBlock "Omega dot" DstPort 1 } Branch { DstBlock "w" DstPort 1 } } Branch { Points [0, 30] Branch { DstBlock "Integrator1" DstPort 1 } Branch { Labels [0, 0] Points [0, 50; -110, 0; 0, 225] DstBlock "Average Torque/omega" DstPort 3 } } } Line { SrcBlock "Integrator1" SrcPort 1 Points [5, 0] Branch { Points [0, -45] DstBlock "Theta" DstPort 1 } Branch { Points [0, 0] Branch { DstBlock "O" DstPort 1 } Branch { Labels [0, 0] Points [0, 65] DstBlock "reset" DstPort 1 } } } Line { SrcBlock "Crank Inertia" SrcPort 1 Points [10, 0] DstBlock "Divide" DstPort 2 } Line { SrcBlock "Torque" SrcPort 1 Points [15, 0] Branch { Points [0, -55] DstBlock "Torque1" DstPort 1 } Branch { Labels [0, 0] Points [0, 480] DstBlock "Average Torque/omega" DstPort 4 } Branch { DstBlock "Divide" DstPort 1 } } Line { SrcBlock "Initial RPM" SrcPort 1 DstBlock "Integrator2" DstPort 2 } Line { SrcBlock "reset" SrcPort 1 Points [20, 0] Branch { DstBlock "Cycle Reset" DstPort 1 } Branch { Points [0, 95] Branch { Points [-115, 0] Branch { Points [0, 50] DstBlock "Cycle Time" DstPort 1 } Branch { Points [-100, 0] DstBlock "Integrator1" DstPort 2 } } Branch { Points [215, 0; 0, 65] DstBlock "Average Torque/omega" DstPort 1 } } } Line { SrcBlock "Cycle Time" SrcPort 1 Points [35, 0; 0, 30] DstBlock "Average Torque/omega" DstPort 2 } Line { SrcBlock "Average Torque/omega" SrcPort 1 Points [20, 0; 0, 10] DstBlock "Average Torque" DstPort 1 } } } Block { BlockType SubSystem Name "Cylinder" Ports [3, 2] Position [615, 274, 740, 376] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Cylinder" Location [792, 98, 1162, 568] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Crank Mux" Position [25, 48, 55, 62] IconDisplay "Port number" } Block { BlockType Inport Name "Geo Mux" Position [65, 248, 95, 262] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Spark Advance" Position [60, 423, 90, 437] Port "3" IconDisplay "Port number" } Block { BlockType Demux Name "Demux" Ports [1, 8] Position [120, 95, 130, 415] ShowName off Outputs "8" DisplayOption "bar" } Block { BlockType Demux Name "Demux2" Ports [1, 2] Position [90, 15, 105, 95] ShowName off Outputs "2" DisplayOption "bar" } Block { BlockType SubSystem Name "Subsystem" Ports [11, 2] Position [175, 26, 290, 444] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Subsystem" Location [82, 210, 1347, 745] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Omega" Position [715, 323, 745, 337] IconDisplay "Port number" } Block { BlockType Inport Name "Theta" Position [250, 38, 280, 52] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Crank Offset" Position [240, 220, 270, 235] Orientation "down" Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Rod Length" Position [230, 268, 260, 282] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "Bore" Position [25, 298, 55, 312] Port "5" IconDisplay "Port number" } Block { BlockType Inport Name "Case Pressure" Position [35, 348, 65, 362] Port "6" IconDisplay "Port number" } Block { BlockType Inport Name "Compression Ratio" Position [320, 460, 350, 475] Orientation "up" Port "7" IconDisplay "Port number" } Block { BlockType Inport Name "Fuel" Position [740, 353, 770, 367] Port "8" IconDisplay "Port number" } Block { BlockType Inport Name "Valve Lift" Position [790, 368, 820, 382] Port "9" IconDisplay "Port number" } Block { BlockType Inport Name "Valve Dia" Position [830, 383, 860, 397] Port "10" IconDisplay "Port number" } Block { BlockType Inport Name "Spark Advance" Position [815, 438, 845, 452] Port "11" IconDisplay "Port number" } Block { BlockType Constant Name "Atm Pressure(Pa)" Position [730, 235, 795, 265] Value "100000" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Atm Temp (K)" Position [770, 180, 800, 210] Value "300" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType SubSystem Name "Combustion" Ports [14, 1] Position [885, 233, 990, 462] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Combustion" Location [2, 82, 1413, 859] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Atm Temp" Position [555, 78, 585, 92] IconDisplay "Port number" } Block { BlockType Inport Name "Atm Pressure" Position [490, 128, 520, 142] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Theta" Position [30, 65, 60, 80] Orientation "down" Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Volume" Position [870, 148, 900, 162] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "Torque" Position [295, 368, 325, 382] Port "5" IconDisplay "Port number" } Block { BlockType Inport Name "Omega" Position [50, 393, 80, 407] Port "6" IconDisplay "Port number" } Block { BlockType Inport Name "Vc" Position [565, 143, 595, 157] Port "7" IconDisplay "Port number" } Block { BlockType Inport Name "Fuel" Position [1360, 593, 1390, 607] Port "8" IconDisplay "Port number" } Block { BlockType Inport Name "Valve Lift" Position [540, 753, 570, 767] Port "9" IconDisplay "Port number" } Block { BlockType Inport Name "Valve Dia" Position [535, 808, 565, 822] Port "10" IconDisplay "Port number" } Block { BlockType Inport Name "Half Crank" Position [90, 743, 120, 757] Port "11" IconDisplay "Port number" } Block { BlockType Inport Name "bore" Position [90, 798, 120, 812] Port "12" IconDisplay "Port number" } Block { BlockType Inport Name "piston Area" Position [90, 863, 120, 877] Port "13" IconDisplay "Port number" } Block { BlockType Inport Name "Spark Advance" Position [100, 178, 130, 192] Port "14" IconDisplay "Port number" } Block { BlockType Sum Name "Add Flow" Ports [2, 1] Position [1075, 637, 1105, 668] Inputs "-+" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sum Name "Add1" Ports [4, 1] Position [510, 390, 540, 440] Inputs "+-+-" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sum Name "Add4" Ports [2, 1] Position [695, 437, 725, 468] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Clock Name "Clock1" Position [90, 470, 110, 490] Decimation "10" } Block { BlockType SubSystem Name "Crank Duration\nSolver" Ports [4, 1] Position [190, 220, 265, 310] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Crank Duration\nSolver" Location [265, 289, 1153, 882] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "omega (rad/s)" Position [120, 23, 150, 37] IconDisplay "Port number" } Block { BlockType Inport Name "Sl (current m/s)" Position [100, 163, 130, 177] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Fuel" Position [100, 233, 130, 247] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Sl (current m/s)1" Position [130, 423, 160, 437] Port "4" IconDisplay "Port number" } Block { BlockType Product Name "Divide1" Ports [2, 1] Position [210, 27, 240, 63] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Divide2" Ports [3, 1] Position [440, 62, 470, 98] Inputs "***" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Divide3" Ports [2, 1] Position [225, 97, 255, 133] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Divide4" Ports [2, 1] Position [240, 287, 270, 323] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Divide5" Ports [3, 1] Position [470, 322, 500, 358] Inputs "***" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Divide6" Ports [2, 1] Position [255, 357, 285, 393] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Mux Name "Mux" Ports [2, 1] Position [680, 91, 685, 129] ShowName off Inputs "2" DisplayOption "bar" } Block { BlockType Constant Name "Ref theta B (deg)" Position [225, 170, 290, 200] Value "47" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Ref theta B (deg)1" Position [255, 430, 320, 460] Value "25" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Reference lam flame speed" Position [105, 110, 170, 140] OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Reference lam flame speed1" Position [110, 370, 175, 400] OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Reference rad/s" Position [90, 60, 155, 90] Value "377" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Reference rad/s1" Position [85, 320, 150, 350] Value "130" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Scope Name "Scope1" Ports [1] Position [720, 89, 750, 121] Floating off Location [346, 271, 1152, 602] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0.62" YMax "0.84" SaveName "ScopeData5" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Switch Name "Switch1" Position [635, 225, 665, 255] Threshold ".5" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "U^(1/3)" Position [285, 30, 345, 60] Expr "u(1)^(1/3)" } Block { BlockType Fcn Name "U^(1/3)1" Position [300, 100, 360, 130] Expr "u(1)^(2/3)" } Block { BlockType Fcn Name "U^(1/3)2" Position [315, 290, 375, 320] Expr "u(1)^(1/3)" } Block { BlockType Fcn Name "U^(1/3)3" Position [330, 360, 390, 390] Expr "u(1)^(2/3)" } Block { BlockType Fcn Name "delay deg->rad1" Position [335, 170, 395, 200] Expr "(u(1)*2*pi()/360)" } Block { BlockType Fcn Name "delay deg->rad2" Position [365, 430, 425, 460] Expr "(u(1)*2*pi()/360)" } Block { BlockType Outport Name "Theta B" Position [710, 233, 740, 247] IconDisplay "Port number" } Line { SrcBlock "delay deg->rad1" SrcPort 1 Points [10, 0; 0, -95] DstBlock "Divide2" DstPort 3 } Line { SrcBlock "Ref theta B (deg)" SrcPort 1 DstBlock "delay deg->rad1" DstPort 1 } Line { SrcBlock "U^(1/3)1" SrcPort 1 Points [15, 0; 0, -35] DstBlock "Divide2" DstPort 2 } Line { SrcBlock "Divide3" SrcPort 1 DstBlock "U^(1/3)1" DstPort 1 } Line { SrcBlock "U^(1/3)" SrcPort 1 Points [30, 0; 0, 25] DstBlock "Divide2" DstPort 1 } Line { SrcBlock "Divide1" SrcPort 1 DstBlock "U^(1/3)" DstPort 1 } Line { SrcBlock "Reference rad/s" SrcPort 1 Points [0, -20] DstBlock "Divide1" DstPort 2 } Line { SrcBlock "omega (rad/s)" SrcPort 1 Points [0, 5; 25, 0] Branch { DstBlock "Divide1" DstPort 1 } Branch { Points [5, 0; 0, 260] DstBlock "Divide4" DstPort 1 } } Line { SrcBlock "Divide2" SrcPort 1 Points [5, 0; 0, 150; 65, 0] Branch { DstBlock "Switch1" DstPort 1 } Branch { Points [0, -130] DstBlock "Mux" DstPort 1 } } Line { SrcBlock "Sl (current m/s)" SrcPort 1 Points [75, 0] DstBlock "Divide3" DstPort 2 } Line { SrcBlock "Reference lam flame speed" SrcPort 1 Points [0, -20] DstBlock "Divide3" DstPort 1 } Line { SrcBlock "Fuel" SrcPort 1 DstBlock "Switch1" DstPort 2 } Line { SrcBlock "delay deg->rad2" SrcPort 1 Points [10, 0; 0, -95] DstBlock "Divide5" DstPort 3 } Line { SrcBlock "Ref theta B (deg)1" SrcPort 1 DstBlock "delay deg->rad2" DstPort 1 } Line { SrcBlock "U^(1/3)3" SrcPort 1 Points [15, 0; 0, -35] DstBlock "Divide5" DstPort 2 } Line { SrcBlock "Divide6" SrcPort 1 DstBlock "U^(1/3)3" DstPort 1 } Line { SrcBlock "U^(1/3)2" SrcPort 1 Points [30, 0; 0, 25] DstBlock "Divide5" DstPort 1 } Line { SrcBlock "Divide4" SrcPort 1 DstBlock "U^(1/3)2" DstPort 1 } Line { SrcBlock "Reference rad/s1" SrcPort 1 Points [0, -20] DstBlock "Divide4" DstPort 2 } Line { SrcBlock "Divide5" SrcPort 1 Points [95, 0; 0, -90] Branch { DstBlock "Switch1" DstPort 3 } Branch { Points [0, -130] DstBlock "Mux" DstPort 2 } } Line { SrcBlock "Sl (current m/s)1" SrcPort 1 Points [75, 0] DstBlock "Divide6" DstPort 2 } Line { SrcBlock "Reference lam flame speed1" SrcPort 1 Points [0, -20] DstBlock "Divide6" DstPort 1 } Line { SrcBlock "Switch1" SrcPort 1 DstBlock "Theta B" DstPort 1 } Line { SrcBlock "Mux" SrcPort 1 Points [5, 0; 0, -5] DstBlock "Scope1" DstPort 1 } } } Block { BlockType SubSystem Name "CxHy Chem" Ports [3, 1] Position [775, 302, 845, 378] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "CxHy Chem" Location [206, 100, 1274, 795] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "R" Position [60, 48, 90, 62] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "%Burn" Position [385, 268, 415, 282] Port "2" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "U" Position [60, 13, 90, 27] Port "3" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Sum Name "Add" Ports [2, 1] Position [450, 227, 480, 258] Inputs "+-" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sum Name "Add1" Ports [2, 1] Position [595, 227, 625, 258] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "Constant" Position [385, 195, 415, 225] OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType SubSystem Name "Embedded\nMATLAB (Reaction Balance)" Ports [0, 11] Position [25, 83, 115, 377] PermitHierarchicalResolution "ExplicitOnly" MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off MaskType "Stateflow" MaskDescription "Embedded MATLAB block" MaskDisplay "disp('fcn');" MaskSelfModifiable on MaskIconFrame on MaskIconOpaque off MaskIconRotate "none" MaskIconUnits "autoscale" System { Name "Embedded\nMATLAB (Reaction Balance)" Location [257, 457, 812, 717] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Demux Name " Demux " Ports [1, 1] Position [270, 495, 320, 535] Outputs "1" } Block { BlockType Ground Name " Ground " Position [20, 306, 40, 324] } Block { BlockType "S-Function" Name " SFunction " Tag "Stateflow S-Function MarkIVRevJt 5" Ports [1, 12] Position [180, 144, 230, 486] FunctionName "sf_sfun" PortCounts "[1 12]" EnableBusSupport on Port { PortNumber 2 Name "Xch" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 3 Name "Xo2" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 4 Name "Xn2r" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 5 Name "CHm" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 6 Name "O2m" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 7 Name "N2m" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 8 Name "Xco2" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 9 Name "Xh2o" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 10 Name "Xn2p" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 11 Name "CO2m" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 12 Name "H2Om" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } } Block { BlockType Terminator Name " Terminator " Position [460, 506, 480, 524] } Block { BlockType Outport Name "Xch" Position [460, 101, 480, 119] IconDisplay "Port number" } Block { BlockType Outport Name "Xo2" Position [460, 136, 480, 154] Port "2" IconDisplay "Port number" } Block { BlockType Outport Name "Xn2r" Position [460, 171, 480, 189] Port "3" IconDisplay "Port number" } Block { BlockType Outport Name "CHm" Position [460, 206, 480, 224] Port "4" IconDisplay "Port number" } Block { BlockType Outport Name "O2m" Position [460, 246, 480, 264] Port "5" IconDisplay "Port number" } Block { BlockType Outport Name "N2m" Position [460, 281, 480, 299] Port "6" IconDisplay "Port number" } Block { BlockType Outport Name "Xco2" Position [460, 316, 480, 334] Port "7" IconDisplay "Port number" } Block { BlockType Outport Name "Xh2o" Position [460, 351, 480, 369] Port "8" IconDisplay "Port number" } Block { BlockType Outport Name "Xn2p" Position [460, 386, 480, 404] Port "9" IconDisplay "Port number" } Block { BlockType Outport Name "CO2m" Position [460, 426, 480, 444] Port "10" IconDisplay "Port number" } Block { BlockType Outport Name "H2Om" Position [460, 461, 480, 479] Port "11" IconDisplay "Port number" } Line { SrcBlock " SFunction " SrcPort 1 DstBlock " Demux " DstPort 1 } Line { Name "Xch" Labels [0, 0] SrcBlock " SFunction " SrcPort 2 DstBlock "Xch" DstPort 1 } Line { Name "Xo2" Labels [0, 0] SrcBlock " SFunction " SrcPort 3 DstBlock "Xo2" DstPort 1 } Line { Name "Xn2r" Labels [0, 0] SrcBlock " SFunction " SrcPort 4 DstBlock "Xn2r" DstPort 1 } Line { Name "CHm" Labels [0, 0] SrcBlock " SFunction " SrcPort 5 DstBlock "CHm" DstPort 1 } Line { Name "O2m" Labels [0, 0] SrcBlock " SFunction " SrcPort 6 DstBlock "O2m" DstPort 1 } Line { Name "N2m" Labels [0, 0] SrcBlock " SFunction " SrcPort 7 DstBlock "N2m" DstPort 1 } Line { Name "Xco2" Labels [0, 0] SrcBlock " SFunction " SrcPort 8 DstBlock "Xco2" DstPort 1 } Line { Name "Xh2o" Labels [0, 0] SrcBlock " SFunction " SrcPort 9 DstBlock "Xh2o" DstPort 1 } Line { Name "Xn2p" Labels [0, 0] SrcBlock " SFunction " SrcPort 10 DstBlock "Xn2p" DstPort 1 } Line { Name "CO2m" Labels [0, 0] SrcBlock " SFunction " SrcPort 11 DstBlock "CO2m" DstPort 1 } Line { Name "H2Om" Labels [0, 0] SrcBlock " SFunction " SrcPort 12 DstBlock "H2Om" DstPort 1 } Line { SrcBlock " Ground " SrcPort 1 DstBlock " SFunction " DstPort 1 } Line { SrcBlock " Demux " SrcPort 1 DstBlock " Terminator " DstPort 1 } } } Block { BlockType SubSystem Name "Embedded\nMATLAB Post Combustion" Ports [8, 1] Position [285, 264, 355, 446] PermitHierarchicalResolution "ExplicitOnly" MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off MaskType "Stateflow" MaskDescription "Embedded MATLAB block" MaskDisplay "disp('fcn');" MaskSelfModifiable on MaskIconFrame on MaskIconOpaque off MaskIconRotate "none" MaskIconUnits "autoscale" System { Name "Embedded\nMATLAB Post Combustion" Location [257, 457, 812, 717] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "U" Position [20, 101, 40, 119] IconDisplay "Port number" } Block { BlockType Inport Name "R" Position [20, 136, 40, 154] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "N2m" Position [20, 171, 40, 189] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Xco2" Position [20, 206, 40, 224] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "Xh2o" Position [20, 246, 40, 264] Port "5" IconDisplay "Port number" } Block { BlockType Inport Name "Xn2p" Position [20, 281, 40, 299] Port "6" IconDisplay "Port number" } Block { BlockType Inport Name "CO2m" Position [20, 316, 40, 334] Port "7" IconDisplay "Port number" } Block { BlockType Inport Name "H2Om" Position [20, 351, 40, 369] Port "8" IconDisplay "Port number" } Block { BlockType Demux Name " Demux " Ports [1, 1] Position [270, 325, 320, 365] Outputs "1" } Block { BlockType "S-Function" Name " SFunction " Tag "Stateflow S-Function MarkIVRevJt 7" Ports [8, 2] Position [180, 121, 230, 324] FunctionName "sf_sfun" PortCounts "[8 2]" EnableBusSupport on Port { PortNumber 2 Name "Tp" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } } Block { BlockType Terminator Name " Terminator " Position [460, 336, 480, 354] } Block { BlockType Outport Name "Tp" Position [460, 101, 480, 119] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock " SFunction " SrcPort 1 DstBlock " Demux " DstPort 1 } Line { SrcBlock "U" SrcPort 1 DstBlock " SFunction " DstPort 1 } Line { SrcBlock "R" SrcPort 1 DstBlock " SFunction " DstPort 2 } Line { SrcBlock "N2m" SrcPort 1 Points [120, 0] DstBlock " SFunction " DstPort 3 } Line { SrcBlock "Xco2" SrcPort 1 DstBlock " SFunction " DstPort 4 } Line { SrcBlock "Xh2o" SrcPort 1 DstBlock " SFunction " DstPort 5 } Line { SrcBlock "Xn2p" SrcPort 1 DstBlock " SFunction " DstPort 6 } Line { SrcBlock "CO2m" SrcPort 1 DstBlock " SFunction " DstPort 7 } Line { SrcBlock "H2Om" SrcPort 1 DstBlock " SFunction " DstPort 8 } Line { Name "Tp" Labels [0, 0] SrcBlock " SFunction " SrcPort 2 DstBlock "Tp" DstPort 1 } Line { SrcBlock " Demux " SrcPort 1 DstBlock " Terminator " DstPort 1 } } } Block { BlockType SubSystem Name "Embedded\nMATLAB Pre Combustion" Ports [8, 1] Position [285, 47, 355, 223] PermitHierarchicalResolution "ExplicitOnly" MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off MaskType "Stateflow" MaskDescription "Embedded MATLAB block" MaskDisplay "disp('fcn');" MaskSelfModifiable on MaskIconFrame on MaskIconOpaque off MaskIconRotate "none" MaskIconUnits "autoscale" System { Name "Embedded\nMATLAB Pre Combustion" Location [257, 457, 812, 717] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "U" Position [20, 101, 40, 119] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "R" Position [20, 136, 40, 154] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Xch" Position [20, 171, 40, 189] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Xo2" Position [20, 206, 40, 224] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "Xn2r" Position [20, 246, 40, 264] Port "5" IconDisplay "Port number" } Block { BlockType Inport Name "CHm" Position [20, 281, 40, 299] Port "6" IconDisplay "Port number" } Block { BlockType Inport Name "O2m" Position [20, 316, 40, 334] Port "7" IconDisplay "Port number" } Block { BlockType Inport Name "N2m" Position [20, 351, 40, 369] Port "8" IconDisplay "Port number" } Block { BlockType Demux Name " Demux " Ports [1, 1] Position [270, 325, 320, 365] Outputs "1" } Block { BlockType "S-Function" Name " SFunction " Tag "Stateflow S-Function MarkIVRevJt 8" Ports [8, 2] Position [180, 121, 230, 324] FunctionName "sf_sfun" PortCounts "[8 2]" EnableBusSupport on Port { PortNumber 2 Name "Tr" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } } Block { BlockType Terminator Name " Terminator " Position [460, 336, 480, 354] } Block { BlockType Outport Name "Tr" Position [460, 101, 480, 119] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock " SFunction " SrcPort 1 DstBlock " Demux " DstPort 1 } Line { SrcBlock "U" SrcPort 1 DstBlock " SFunction " DstPort 1 } Line { SrcBlock "R" SrcPort 1 DstBlock " SFunction " DstPort 2 } Line { SrcBlock "Xch" SrcPort 1 Points [120, 0] DstBlock " SFunction " DstPort 3 } Line { SrcBlock "Xo2" SrcPort 1 DstBlock " SFunction " DstPort 4 } Line { SrcBlock "Xn2r" SrcPort 1 DstBlock " SFunction " DstPort 5 } Line { SrcBlock "CHm" SrcPort 1 DstBlock " SFunction " DstPort 6 } Line { SrcBlock "O2m" SrcPort 1 DstBlock " SFunction " DstPort 7 } Line { SrcBlock "N2m" SrcPort 1 DstBlock " SFunction " DstPort 8 } Line { Name "Tr" Labels [0, 0] SrcBlock " SFunction " SrcPort 2 DstBlock "Tr" DstPort 1 } Line { SrcBlock " Demux " SrcPort 1 DstBlock " Terminator " DstPort 1 } } } Block { BlockType Product Name "Product" Ports [2, 1] Position [520, 127, 550, 158] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product1" Ports [2, 1] Position [490, 332, 520, 363] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "Tout" Position [675, 238, 705, 252] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock "Constant" SrcPort 1 Points [10, 0; 0, 25] DstBlock "Add" DstPort 1 } Line { SrcBlock "%Burn" SrcPort 1 Points [0, 0] Branch { Points [10, 0; 0, -25] DstBlock "Add" DstPort 2 } Branch { Points [10, 0; 0, 65] DstBlock "Product1" DstPort 1 } } Line { SrcBlock "Add" SrcPort 1 Points [5, 0; 0, -95] DstBlock "Product" DstPort 2 } Line { SrcBlock "Embedded\nMATLAB Pre Combustion" SrcPort 1 DstBlock "Product" DstPort 1 } Line { SrcBlock "Embedded\nMATLAB Post Combustion" SrcPort 1 DstBlock "Product1" DstPort 2 } Line { SrcBlock "Product" SrcPort 1 Points [15, 0; 0, 90] DstBlock "Add1" DstPort 1 } Line { SrcBlock "Product1" SrcPort 1 Points [45, 0; 0, -100] DstBlock "Add1" DstPort 2 } Line { SrcBlock "Add1" SrcPort 1 DstBlock "Tout" DstPort 1 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 1 DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 3 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 2 Points [150, 0] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 4 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 3 Points [0, -10] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 5 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 7 Points [80, 0; 0, 90] DstBlock "Embedded\nMATLAB Post Combustion" DstPort 4 } Line { SrcBlock "R" SrcPort 1 Points [85, 0; 0, 35; 50, 0] Branch { Points [40, 0] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 2 } Branch { Points [0, 215] DstBlock "Embedded\nMATLAB Post Combustion" DstPort 2 } } Line { SrcBlock "U" SrcPort 1 Points [105, 0; 0, 50; 45, 0] Branch { Points [25, 0] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 1 } Branch { Points [0, 215] DstBlock "Embedded\nMATLAB Post Combustion" DstPort 1 } } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 4 Points [25, 0; 0, -15] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 6 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 5 Points [35, 0; 0, -20] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 7 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 6 Points [95, 0] Branch { Points [0, -25] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 8 } Branch { Points [0, 95] DstBlock "Embedded\nMATLAB Post Combustion" DstPort 3 } } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 8 Points [65, 0; 0, 85] DstBlock "Embedded\nMATLAB Post Combustion" DstPort 5 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 9 Points [50, 0; 0, 80] DstBlock "Embedded\nMATLAB Post Combustion" DstPort 6 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 10 Points [35, 0; 0, 75] DstBlock "Embedded\nMATLAB Post Combustion" DstPort 7 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 11 Points [0, 70] DstBlock "Embedded\nMATLAB Post Combustion" DstPort 8 } } } Block { BlockType Product Name "Divide" Ports [2, 1] Position [615, 407, 645, 443] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType SubSystem Name "Energy" Ports [3, 2] Position [1450, 524, 1520, 616] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Energy" Location [209, 88, 1231, 811] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Theta" Position [15, 403, 45, 417] IconDisplay "Port number" } Block { BlockType Inport Name "M" Position [15, 28, 45, 42] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Fuel" Position [105, 563, 135, 577] Port "3" IconDisplay "Port number" } Block { BlockType Constant Name "CONST" Position [85, 490, 115, 520] Value "pi()" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Display Name "Display" Ports [1] Position [700, 30, 790, 60] Decimation "1" Lockdown off } Block { BlockType Display Name "Display1" Ports [1] Position [820, 220, 910, 250] Decimation "1" Lockdown off } Block { BlockType Product Name "Divide" Ports [2, 1] Position [310, 32, 340, 63] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Divide1" Ports [2, 1] Position [405, 42, 435, 73] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Divide2" Ports [2, 1] Position [480, 52, 510, 83] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Divide3" Ports [2, 1] Position [390, 287, 420, 318] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Divide4" Ports [2, 1] Position [485, 297, 515, 328] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Divide5" Ports [2, 1] Position [560, 307, 590, 338] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "Energy Relased gas" Position [435, 207, 515, 233] Value "5324540000" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Energy Relased h2" Position [515, 462, 595, 488] Value "241820000" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Molar Mass" Position [225, 115, 270, 145] Value "30.2619" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Molar Mass1" Position [235, 355, 275, 385] Value "20.9" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Moles \n1/TotalMoles of O2 in Air" Position [305, 150, 335, 180] Value "4.76" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Moles \nTotalMoles of O2 in Air1" Position [370, 405, 400, 435] Value "6.76" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Mux Name "Mux1" Ports [3, 1] Position [820, 326, 830, 374] ShowName off Inputs "3" DisplayOption "bar" } Block { BlockType Constant Name "O2 per mole gas" Position [390, 145, 420, 175] Value "12.5" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "O2 per mole gas1" Position [485, 400, 515, 430] OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "Product" Ports [2, 1] Position [580, 62, 610, 93] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product1" Ports [2, 1] Position [660, 317, 690, 348] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType RelationalOperator Name "Relational\nOperator" Position [170, 477, 200, 508] InputSameDT off LogicOutDataTypeMode "boolean" OutDataTypeStr "boolean" } Block { BlockType Reference Name "Sample\nand Hold" Ports [1, 1, 0, 1] Position [160, 84, 210, 126] SourceBlock "dspsigops/Sample\nand Hold" SourceType "Sample and Hold" ShowPortLabels "FromPortIcon" SystemSampleTime "-1" FunctionWithSeparateData "off" RTWMemSecFuncInitTerm "Inherit from model" RTWMemSecFuncExecute "Inherit from model" RTWMemSecDataConstants "Inherit from model" RTWMemSecDataInternal "Inherit from model" RTWMemSecDataParameters "Inherit from model" trig "Rising edge" initCond "0" latchinput "off" } Block { BlockType Reference Name "Sample\nand Hold1" Ports [1, 1, 0, 1] Position [140, 274, 190, 316] SourceBlock "dspsigops/Sample\nand Hold" SourceType "Sample and Hold" ShowPortLabels "FromPortIcon" SystemSampleTime "-1" FunctionWithSeparateData "off" RTWMemSecFuncInitTerm "Inherit from model" RTWMemSecFuncExecute "Inherit from model" RTWMemSecDataConstants "Inherit from model" RTWMemSecDataInternal "Inherit from model" RTWMemSecDataParameters "Inherit from model" trig "Rising edge" initCond "0" latchinput "off" } Block { BlockType Scope Name "Scope" Ports [1] Position [870, 334, 900, 366] Floating off Location [90, 491, 963, 817] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "1050" SaveName "ScopeData7" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Scope Name "Scope1" Ports [1] Position [825, 604, 855, 636] Floating off Location [418, 398, 1291, 778] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "27.5215" YMax "30.4185" SaveName "ScopeData22" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Scope Name "Scope2" Ports [1] Position [925, 439, 955, 471] Floating off Location [26, 482, 899, 863] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "1020.97" YMax "1128.43" SaveName "ScopeData23" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Switch Name "Switch" Position [805, 555, 835, 585] Threshold ".5" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType Switch Name "Switch1" Position [720, 645, 750, 675] Threshold ".5" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "E" Position [895, 563, 925, 577] IconDisplay "Port number" } Block { BlockType Outport Name "Mmass" Position [930, 668, 960, 682] Port "2" IconDisplay "Port number" } Line { SrcBlock "M" SrcPort 1 Points [5, 0; 0, 70] Branch { DstBlock "Sample\nand Hold" DstPort 1 } Branch { Points [0, 190] DstBlock "Sample\nand Hold1" DstPort 1 } } Line { SrcBlock "Molar Mass" SrcPort 1 Points [0, -75; 10, 0] Branch { DstBlock "Divide" DstPort 2 } Branch { Points [0, 595] DstBlock "Switch1" DstPort 1 } } Line { SrcBlock "Divide" SrcPort 1 DstBlock "Divide1" DstPort 1 } Line { SrcBlock "Moles \n1/TotalMoles of O2 in Air" SrcPort 1 Points [5, 0; 0, -100] DstBlock "Divide1" DstPort 2 } Line { SrcBlock "Divide1" SrcPort 1 DstBlock "Divide2" DstPort 1 } Line { SrcBlock "O2 per mole gas" SrcPort 1 Points [25, 0; 0, -85] DstBlock "Divide2" DstPort 2 } Line { SrcBlock "Divide2" SrcPort 1 DstBlock "Product" DstPort 1 } Line { SrcBlock "Energy Relased gas" SrcPort 1 Points [20, 0; 0, -135] DstBlock "Product" DstPort 2 } Line { SrcBlock "Molar Mass1" SrcPort 1 Points [25, 0] Branch { Points [40, 0; 0, -60] DstBlock "Divide3" DstPort 2 } Branch { Points [0, 300] DstBlock "Switch1" DstPort 3 } } Line { SrcBlock "Divide3" SrcPort 1 DstBlock "Divide4" DstPort 1 } Line { SrcBlock "Moles \nTotalMoles of O2 in Air1" SrcPort 1 Points [20, 0; 0, -100] DstBlock "Divide4" DstPort 2 } Line { SrcBlock "Divide4" SrcPort 1 DstBlock "Divide5" DstPort 1 } Line { SrcBlock "O2 per mole gas1" SrcPort 1 Points [25, 0] DstBlock "Divide5" DstPort 2 } Line { SrcBlock "Divide5" SrcPort 1 DstBlock "Product1" DstPort 1 } Line { SrcBlock "Energy Relased h2" SrcPort 1 Points [20, 0; 0, -135] DstBlock "Product1" DstPort 2 } Line { SrcBlock "Product1" SrcPort 1 Points [10, 0] Branch { Points [35, 0; 0, 15] Branch { DstBlock "Mux1" DstPort 2 } Branch { Points [0, 230] DstBlock "Switch" DstPort 3 } } Branch { Points [0, -100] DstBlock "Display1" DstPort 1 } } Line { SrcBlock "Product" SrcPort 1 Points [55, 0] Branch { Points [110, 0; 0, 255] Branch { DstBlock "Mux1" DstPort 1 } Branch { Points [0, 225] DstBlock "Switch" DstPort 1 } } Branch { Points [0, -35] DstBlock "Display" DstPort 1 } } Line { SrcBlock "Mux1" SrcPort 1 DstBlock "Scope" DstPort 1 } Line { SrcBlock "Sample\nand Hold" SrcPort 1 Points [30, 0; 0, -65] DstBlock "Divide" DstPort 1 } Line { SrcBlock "CONST" SrcPort 1 Points [15, 0; 0, -5] DstBlock "Relational\nOperator" DstPort 2 } Line { SrcBlock "Theta" SrcPort 1 Points [50, 0; 0, 75] DstBlock "Relational\nOperator" DstPort 1 } Line { SrcBlock "Relational\nOperator" SrcPort 1 Points [15, 0; 0, -275] Branch { Points [0, -151] DstBlock "Sample\nand Hold" DstPort trigger } Branch { Points [-55, 0] DstBlock "Sample\nand Hold1" DstPort trigger } } Line { SrcBlock "Sample\nand Hold1" SrcPort 1 DstBlock "Divide3" DstPort 1 } Line { SrcBlock "Fuel" SrcPort 1 Points [475, 0] Branch { DstBlock "Switch" DstPort 2 } Branch { Points [0, 90] DstBlock "Switch1" DstPort 2 } } Line { SrcBlock "Switch" SrcPort 1 Points [15, 0] Branch { DstBlock "E" DstPort 1 } Branch { Points [0, -115] DstBlock "Scope2" DstPort 1 } } Line { SrcBlock "Switch1" SrcPort 1 Points [20, 0] Branch { Points [0, -40] DstBlock "Scope1" DstPort 1 } Branch { Points [0, 15] DstBlock "Mmass" DstPort 1 } } } } Block { BlockType Integrator Name "Exhaust E intergrator" Ports [2, 1] Position [1165, 836, 1205, 894] ExternalReset "falling" LowerSaturationLimit "0" } Block { BlockType SubSystem Name "Exhaust Mdot Calculator" Ports [7, 1] Position [875, 551, 1015, 639] NamePlacement "alternate" MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Exhaust Mdot Calculator" Location [202, 131, 1377, 693] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Crank Angle" Position [45, 233, 75, 247] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Cylinder Pressure1" Position [510, 228, 540, 242] Port "2" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "ex pressure" Position [505, 288, 535, 302] Port "3" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Cyl temp" Position [510, 348, 540, 362] Port "4" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "M mass" Position [275, 443, 305, 457] Port "5" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Valve Lift" Position [215, 163, 245, 177] Port "6" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Valve Dia" Position [190, 103, 220, 117] Port "7" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "A" Ports [2, 1] Position [385, 397, 415, 428] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "Choke" Position [705, 100, 765, 130] Expr "(u(1)*u(2)*u(3)/sqrt(u(6)*u(5)))*(sqrt(u(7)))*(2/(u(7)+1))^((u(7)+1)/(2*(u(7)-1)))" } Block { BlockType Constant Name "Constant1" Position [505, 100, 535, 130] Value ".6" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Constant7" Position [505, 460, 535, 490] Value "1.35" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Fcn Name "Fcn" Position [705, 340, 765, 370] Expr "(2/(u(7)+1))^(u(7)/(u(7)-1))" } Block { BlockType Fcn Name "Fcn1" Position [475, 160, 535, 190] Expr "u(1)*pi" } Block { BlockType Fcn Name "Fcn2" Position [180, 294, 285, 326] Expr "-sin(u(1))" } Block { BlockType SubSystem Name "Lift ex" Ports [1, 1] Position [155, 219, 260, 261] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Lift ex" Location [375, 376, 1095, 734] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Crank Angle" Position [75, 188, 105, 202] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "On" Position [200, 140, 230, 170] OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Switch Name "Switch1" Position [410, 180, 440, 210] Threshold "4*pi" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType Switch Name "Switch2" Position [295, 180, 325, 210] Threshold "3*pi" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "off" Position [190, 225, 220, 255] Value "0" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Outport Name "Lift" Position [495, 188, 525, 202] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock "Switch2" SrcPort 1 Points [25, 0; 0, 10] DstBlock "Switch1" DstPort 3 } Line { SrcBlock "Switch1" SrcPort 1 DstBlock "Lift" DstPort 1 } Line { SrcBlock "On" SrcPort 1 Points [25, 0; 0, 30] DstBlock "Switch2" DstPort 1 } Line { SrcBlock "off" SrcPort 1 Points [10, 0] Branch { Points [0, 10; 120, 0; 0, -65] DstBlock "Switch1" DstPort 1 } Branch { Points [0, -35] DstBlock "Switch2" DstPort 3 } } Line { SrcBlock "Crank Angle" SrcPort 1 Points [140, 0] Branch { Points [0, 40; 145, 0] DstBlock "Switch1" DstPort 2 } Branch { DstBlock "Switch2" DstPort 2 } } } } Block { BlockType Mux Name "Mux" Ports [7, 1] Position [630, 86, 635, 504] ShowName off Inputs "7" DisplayOption "bar" } Block { BlockType Mux Name "Mux1" Ports [2, 1] Position [345, 316, 350, 354] ShowName off Inputs "2" DisplayOption "bar" } Block { BlockType Fcn Name "No Choke" Position [705, 460, 765, 490] Expr "(u(1)*u(2)*u(3)/sqrt(u(6)*u(5)))*(sqrt(u(4)/u(3)))*sqrt((2*u(7)/(u(7)-1))*(1-(u(4)/u(3))^((u(7)-1)/u(" "7))))" } Block { BlockType Product Name "Product" Ports [3, 1] Position [410, 159, 440, 191] Inputs "3" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product1" Ports [2, 1] Position [350, 261, 380, 294] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "Pt/Po" Position [705, 215, 765, 245] Expr "u(4)/u(3)" } Block { BlockType Constant Name "R" Position [275, 385, 305, 415] Value "8314" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType RelationalOperator Name "Relational\nOperator" Position [830, 277, 860, 308] Operator "<=" InputSameDT off LogicOutDataTypeMode "boolean" OutDataTypeStr "boolean" } Block { BlockType Scope Name "Scope" Ports [1] Position [1000, 199, 1030, 231] Floating off Location [6, 46, 1430, 869] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0.0075" YMax "0.0475" SaveName "ScopeData3" DataFormat "StructureWithTime" SampleTime "0" } Block { BlockType Scope Name "Scope2" Ports [1] Position [385, 309, 415, 341] Floating off Location [147, 479, 782, 821] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "-1" YMax "1" SaveName "ScopeData20" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Switch Name "Switch" Position [905, 280, 935, 310] Criteria "u2 > Threshold" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "Exhaust Mdot" Position [1025, 288, 1055, 302] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock "Constant1" SrcPort 1 DstBlock "Mux" DstPort 1 } Line { SrcBlock "Cylinder Pressure1" SrcPort 1 DstBlock "Mux" DstPort 3 } Line { SrcBlock "ex pressure" SrcPort 1 DstBlock "Mux" DstPort 4 } Line { SrcBlock "Cyl temp" SrcPort 1 DstBlock "Mux" DstPort 5 } Line { SrcBlock "Constant7" SrcPort 1 DstBlock "Mux" DstPort 7 } Line { SrcBlock "Mux" SrcPort 1 Points [25, 0] Branch { Points [0, 60] Branch { DstBlock "Fcn" DstPort 1 } Branch { Points [0, 120] DstBlock "No Choke" DstPort 1 } } Branch { Points [0, -65] Branch { DstBlock "Pt/Po" DstPort 1 } Branch { Points [0, -115] DstBlock "Choke" DstPort 1 } } } Line { SrcBlock "Pt/Po" SrcPort 1 Points [20, 0; 0, 55] DstBlock "Relational\nOperator" DstPort 1 } Line { SrcBlock "Fcn" SrcPort 1 Points [20, 0; 0, -55] DstBlock "Relational\nOperator" DstPort 2 } Line { SrcBlock "Relational\nOperator" SrcPort 1 DstBlock "Switch" DstPort 2 } Line { SrcBlock "Choke" SrcPort 1 Points [120, 0] DstBlock "Switch" DstPort 1 } Line { SrcBlock "No Choke" SrcPort 1 Points [120, 0] DstBlock "Switch" DstPort 3 } Line { SrcBlock "Valve Lift" SrcPort 1 Points [145, 0] DstBlock "Product" DstPort 2 } Line { SrcBlock "Valve Dia" SrcPort 1 Points [115, 0; 0, 55] DstBlock "Product" DstPort 1 } Line { SrcBlock "Product" SrcPort 1 DstBlock "Fcn1" DstPort 1 } Line { SrcBlock "Switch" SrcPort 1 Points [20, 0] Branch { DstBlock "Exhaust Mdot" DstPort 1 } Branch { Points [0, -80] DstBlock "Scope" DstPort 1 } } Line { Labels [0, 0] SrcBlock "Fcn1" SrcPort 1 DstBlock "Mux" DstPort 2 } Line { SrcBlock "R" SrcPort 1 Points [30, 0; 0, 5] DstBlock "A" DstPort 1 } Line { SrcBlock "M mass" SrcPort 1 Points [50, 0; 0, -30] DstBlock "A" DstPort 2 } Line { SrcBlock "A" SrcPort 1 DstBlock "Mux" DstPort 6 } Line { SrcBlock "Crank Angle" SrcPort 1 Points [40, 0] Branch { DstBlock "Lift ex" DstPort 1 } Branch { Points [0, 70] DstBlock "Fcn2" DstPort 1 } } Line { SrcBlock "Fcn2" SrcPort 1 Points [20, 0; 0, 15; 15, 0] Branch { DstBlock "Mux1" DstPort 1 } Branch { Points [0, -40] DstBlock "Product1" DstPort 2 } } Line { SrcBlock "Mux1" SrcPort 1 Points [5, 0; 0, -10] DstBlock "Scope2" DstPort 1 } Line { SrcBlock "Lift ex" SrcPort 1 Points [35, 0; 0, 30] Branch { Points [0, 75] DstBlock "Mux1" DstPort 2 } Branch { DstBlock "Product1" DstPort 1 } } Line { SrcBlock "Product1" SrcPort 1 Points [5, 0; 0, -95] DstBlock "Product" DstPort 3 } Annotation { Name "Cd" Position [493, 114] } Annotation { Name "Ar" Position [595, 168] } Annotation { Name "R" Position [495, 410] } Annotation { Name "gamma" Position [472, 476] } Annotation { Name "If Choke, output 1" Position [846, 259] } } } Block { BlockType Sum Name "Flow\nEnergy" Ports [2, 1] Position [1340, 817, 1370, 848] Inputs "+-" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType SubSystem Name "H Chem1" Ports [3, 1] Position [775, 392, 840, 478] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "H Chem1" Location [84, 164, 1295, 789] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "R" Position [95, 103, 125, 117] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "%Burn" Position [420, 323, 450, 337] Port "2" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "U" Position [95, 68, 125, 82] Port "3" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Sum Name "Add" Ports [2, 1] Position [485, 282, 515, 313] Inputs "+-" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sum Name "Add1" Ports [2, 1] Position [630, 282, 660, 313] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "Constant" Position [420, 250, 450, 280] OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType SubSystem Name "Embedded\nMATLAB (Reaction Balance)" Ports [0, 9] Position [80, 138, 170, 432] PermitHierarchicalResolution "ExplicitOnly" MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off MaskType "Stateflow" MaskDescription "Embedded MATLAB block" MaskDisplay "disp('fcn');" MaskSelfModifiable on MaskIconFrame on MaskIconOpaque off MaskIconRotate "none" MaskIconUnits "autoscale" System { Name "Embedded\nMATLAB (Reaction Balance)" Location [257, 457, 812, 717] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Demux Name " Demux " Ports [1, 1] Position [270, 490, 320, 530] Outputs "1" } Block { BlockType Ground Name " Ground " Position [20, 306, 40, 324] } Block { BlockType "S-Function" Name " SFunction " Tag "Stateflow S-Function MarkIVRevJt 1" Ports [1, 10] Position [180, 146, 230, 489] FunctionName "sf_sfun" PortCounts "[1 10]" EnableBusSupport on Port { PortNumber 2 Name "Xh2" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 3 Name "Xo2" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 4 Name "Xn2r" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 5 Name "H2m" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 6 Name "O2m" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 7 Name "N2m" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 8 Name "Xh2o" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 9 Name "Xn2p" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } Port { PortNumber 10 Name "H2Om" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } } Block { BlockType Terminator Name " Terminator " Position [460, 501, 480, 519] } Block { BlockType Outport Name "Xh2" Position [460, 101, 480, 119] IconDisplay "Port number" } Block { BlockType Outport Name "Xo2" Position [460, 136, 480, 154] Port "2" IconDisplay "Port number" } Block { BlockType Outport Name "Xn2r" Position [460, 171, 480, 189] Port "3" IconDisplay "Port number" } Block { BlockType Outport Name "H2m" Position [460, 206, 480, 224] Port "4" IconDisplay "Port number" } Block { BlockType Outport Name "O2m" Position [460, 246, 480, 264] Port "5" IconDisplay "Port number" } Block { BlockType Outport Name "N2m" Position [460, 281, 480, 299] Port "6" IconDisplay "Port number" } Block { BlockType Outport Name "Xh2o" Position [460, 316, 480, 334] Port "7" IconDisplay "Port number" } Block { BlockType Outport Name "Xn2p" Position [460, 351, 480, 369] Port "8" IconDisplay "Port number" } Block { BlockType Outport Name "H2Om" Position [460, 386, 480, 404] Port "9" IconDisplay "Port number" } Line { SrcBlock " SFunction " SrcPort 1 DstBlock " Demux " DstPort 1 } Line { Name "Xh2" Labels [0, 0] SrcBlock " SFunction " SrcPort 2 DstBlock "Xh2" DstPort 1 } Line { Name "Xo2" Labels [0, 0] SrcBlock " SFunction " SrcPort 3 DstBlock "Xo2" DstPort 1 } Line { Name "Xn2r" Labels [0, 0] SrcBlock " SFunction " SrcPort 4 DstBlock "Xn2r" DstPort 1 } Line { Name "H2m" Labels [0, 0] SrcBlock " SFunction " SrcPort 5 DstBlock "H2m" DstPort 1 } Line { Name "O2m" Labels [0, 0] SrcBlock " SFunction " SrcPort 6 DstBlock "O2m" DstPort 1 } Line { Name "N2m" Labels [0, 0] SrcBlock " SFunction " SrcPort 7 DstBlock "N2m" DstPort 1 } Line { Name "Xh2o" Labels [0, 0] SrcBlock " SFunction " SrcPort 8 DstBlock "Xh2o" DstPort 1 } Line { Name "Xn2p" Labels [0, 0] SrcBlock " SFunction " SrcPort 9 DstBlock "Xn2p" DstPort 1 } Line { Name "H2Om" Labels [0, 0] SrcBlock " SFunction " SrcPort 10 DstBlock "H2Om" DstPort 1 } Line { SrcBlock " Ground " SrcPort 1 Points [120, 0] DstBlock " SFunction " DstPort 1 } Line { SrcBlock " Demux " SrcPort 1 DstBlock " Terminator " DstPort 1 } } } Block { BlockType SubSystem Name "Embedded\nMATLAB Post Combustion" Ports [6, 1] Position [320, 316, 390, 494] PermitHierarchicalResolution "ExplicitOnly" MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off MaskType "Stateflow" MaskDescription "Embedded MATLAB block" MaskDisplay "disp('fcn');" MaskSelfModifiable on MaskIconFrame on MaskIconOpaque off MaskIconRotate "none" MaskIconUnits "autoscale" System { Name "Embedded\nMATLAB Post Combustion" Location [257, 457, 812, 717] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "U" Position [20, 101, 40, 119] IconDisplay "Port number" } Block { BlockType Inport Name "R" Position [20, 136, 40, 154] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "N2m" Position [20, 171, 40, 189] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Xh2o" Position [20, 206, 40, 224] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "Xn2p" Position [20, 246, 40, 264] Port "5" IconDisplay "Port number" } Block { BlockType Inport Name "H2Om" Position [20, 281, 40, 299] Port "6" IconDisplay "Port number" } Block { BlockType Demux Name " Demux " Ports [1, 1] Position [270, 330, 320, 370] Outputs "1" } Block { BlockType "S-Function" Name " SFunction " Tag "Stateflow S-Function MarkIVRevJt 2" Ports [6, 2] Position [180, 125, 230, 330] FunctionName "sf_sfun" PortCounts "[6 2]" EnableBusSupport on Port { PortNumber 2 Name "Tp" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } } Block { BlockType Terminator Name " Terminator " Position [460, 341, 480, 359] } Block { BlockType Outport Name "Tp" Position [460, 101, 480, 119] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock " SFunction " SrcPort 1 DstBlock " Demux " DstPort 1 } Line { SrcBlock "U" SrcPort 1 DstBlock " SFunction " DstPort 1 } Line { SrcBlock "R" SrcPort 1 DstBlock " SFunction " DstPort 2 } Line { SrcBlock "N2m" SrcPort 1 DstBlock " SFunction " DstPort 3 } Line { SrcBlock "Xh2o" SrcPort 1 DstBlock " SFunction " DstPort 4 } Line { SrcBlock "Xn2p" SrcPort 1 Points [120, 0] DstBlock " SFunction " DstPort 5 } Line { SrcBlock "H2Om" SrcPort 1 DstBlock " SFunction " DstPort 6 } Line { Name "Tp" Labels [0, 0] SrcBlock " SFunction " SrcPort 2 DstBlock "Tp" DstPort 1 } Line { SrcBlock " Demux " SrcPort 1 DstBlock " Terminator " DstPort 1 } } } Block { BlockType SubSystem Name "Embedded\nMATLAB Pre Combustion" Ports [8, 1] Position [320, 101, 390, 279] PermitHierarchicalResolution "ExplicitOnly" MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off MaskType "Stateflow" MaskDescription "Embedded MATLAB block" MaskDisplay "disp('fcn');" MaskSelfModifiable on MaskIconFrame on MaskIconOpaque off MaskIconRotate "none" MaskIconUnits "autoscale" System { Name "Embedded\nMATLAB Pre Combustion" Location [257, 457, 812, 717] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "U" Position [20, 101, 40, 119] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "R" Position [20, 136, 40, 154] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Xh2" Position [20, 171, 40, 189] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Xo2" Position [20, 206, 40, 224] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "Xn2r" Position [20, 246, 40, 264] Port "5" IconDisplay "Port number" } Block { BlockType Inport Name "H2m" Position [20, 281, 40, 299] Port "6" IconDisplay "Port number" } Block { BlockType Inport Name "O2m" Position [20, 316, 40, 334] Port "7" IconDisplay "Port number" } Block { BlockType Inport Name "N2m" Position [20, 351, 40, 369] Port "8" IconDisplay "Port number" } Block { BlockType Demux Name " Demux " Ports [1, 1] Position [270, 325, 320, 365] Outputs "1" } Block { BlockType "S-Function" Name " SFunction " Tag "Stateflow S-Function MarkIVRevJt 3" Ports [8, 2] Position [180, 121, 230, 324] FunctionName "sf_sfun" PortCounts "[8 2]" EnableBusSupport on Port { PortNumber 2 Name "Tr" RTWStorageClass "Auto" DataLoggingNameMode "SignalName" } } Block { BlockType Terminator Name " Terminator " Position [460, 336, 480, 354] } Block { BlockType Outport Name "Tr" Position [460, 101, 480, 119] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock " SFunction " SrcPort 1 DstBlock " Demux " DstPort 1 } Line { SrcBlock "U" SrcPort 1 DstBlock " SFunction " DstPort 1 } Line { SrcBlock "R" SrcPort 1 DstBlock " SFunction " DstPort 2 } Line { SrcBlock "Xh2" SrcPort 1 Points [120, 0] DstBlock " SFunction " DstPort 3 } Line { SrcBlock "Xo2" SrcPort 1 DstBlock " SFunction " DstPort 4 } Line { SrcBlock "Xn2r" SrcPort 1 DstBlock " SFunction " DstPort 5 } Line { SrcBlock "H2m" SrcPort 1 DstBlock " SFunction " DstPort 6 } Line { SrcBlock "O2m" SrcPort 1 DstBlock " SFunction " DstPort 7 } Line { SrcBlock "N2m" SrcPort 1 DstBlock " SFunction " DstPort 8 } Line { Name "Tr" Labels [0, 0] SrcBlock " SFunction " SrcPort 2 DstBlock "Tr" DstPort 1 } Line { SrcBlock " Demux " SrcPort 1 DstBlock " Terminator " DstPort 1 } } } Block { BlockType Mux Name "Mux" Ports [2, 1] Position [785, 276, 790, 314] ShowName off Inputs "2" DisplayOption "bar" } Block { BlockType Product Name "Product" Ports [2, 1] Position [555, 187, 585, 218] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product1" Ports [2, 1] Position [525, 377, 555, 408] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Scope Name "Scope3" Ports [1] Position [490, 454, 520, 486] Floating off Location [501, 381, 1435, 894] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "3250" SaveName "ScopeData8" DataFormat "StructureWithTime" SampleTime "0" } Block { BlockType Scope Name "Scope5" Ports [1] Position [830, 279, 860, 311] Floating off Location [89, 153, 1023, 666] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "3250" SaveName "ScopeData11" DataFormat "StructureWithTime" SampleTime "0" } Block { BlockType Outport Name "Tout" Position [700, 293, 730, 307] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock "Product1" SrcPort 1 Points [30, 0] Branch { Points [25, 0] DstBlock "Add1" DstPort 2 } Branch { Labels [3, 0] Points [0, 30; 165, 0; 0, -120] DstBlock "Mux" DstPort 2 } } Line { SrcBlock "Product" SrcPort 1 Points [15, 0] Branch { Points [10, 0] DstBlock "Add1" DstPort 1 } Branch { Points [0, -50; 165, 0] DstBlock "Mux" DstPort 1 } } Line { SrcBlock "Embedded\nMATLAB Post Combustion" SrcPort 1 Points [115, 0] DstBlock "Product1" DstPort 2 } Line { SrcBlock "Embedded\nMATLAB Pre Combustion" SrcPort 1 Points [0, 5] DstBlock "Product" DstPort 1 } Line { SrcBlock "Add" SrcPort 1 Points [5, 0; 0, -90] DstBlock "Product" DstPort 2 } Line { SrcBlock "%Burn" SrcPort 1 Points [0, 0] Branch { Points [10, 0; 0, -25] DstBlock "Add" DstPort 2 } Branch { Points [10, 0; 0, 55; 10, 0] Branch { DstBlock "Product1" DstPort 1 } Branch { DstBlock "Scope3" DstPort 1 } } } Line { SrcBlock "Constant" SrcPort 1 Points [10, 0; 0, 25] DstBlock "Add" DstPort 1 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 1 Points [130, 0] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 3 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 2 Points [0, -15] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 4 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 3 Points [20, 0; 0, -25] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 5 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 4 Points [25, 0; 0, -35] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 6 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 5 Points [35, 0; 0, -40; 95, 0] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 7 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 6 Points [40, 0; 0, -50; 45, 0] Branch { Points [45, 0] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 8 } Branch { Points [0, 125] DstBlock "Embedded\nMATLAB Post Combustion" DstPort 3 } } Line { SrcBlock "R" SrcPort 1 Points [80, 0; 0, 35; 60, 0] Branch { Points [35, 0] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 2 } Branch { Points [0, 215] DstBlock "Embedded\nMATLAB Post Combustion" DstPort 2 } } Line { SrcBlock "U" SrcPort 1 Points [105, 0; 0, 50; 50, 0] Branch { Points [20, 0] DstBlock "Embedded\nMATLAB Pre Combustion" DstPort 1 } Branch { Points [0, 205] DstBlock "Embedded\nMATLAB Post Combustion" DstPort 1 } } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 7 Points [65, 0; 0, 75] DstBlock "Embedded\nMATLAB Post Combustion" DstPort 4 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 8 Points [35, 0; 0, 75] DstBlock "Embedded\nMATLAB Post Combustion" DstPort 5 } Line { SrcBlock "Embedded\nMATLAB (Reaction Balance)" SrcPort 9 Points [20, 0; 0, 75] DstBlock "Embedded\nMATLAB Post Combustion" DstPort 6 } Line { SrcBlock "Add1" SrcPort 1 DstBlock "Tout" DstPort 1 } Line { SrcBlock "Mux" SrcPort 1 DstBlock "Scope5" DstPort 1 } } } Block { BlockType SubSystem Name "Heat Transfer" Ports [7, 1] Position [310, 744, 415, 856] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Heat Transfer" Location [150, 249, 1104, 735] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "omega" Position [60, 13, 90, 27] IconDisplay "Port number" } Block { BlockType Inport Name "half crank" Position [45, 48, 75, 62] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "bore" Position [70, 73, 100, 87] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "T cyl" Position [65, 223, 95, 237] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "Twall" Position [60, 268, 90, 282] Port "5" IconDisplay "Port number" } Block { BlockType Inport Name "Volume" Position [65, 403, 95, 417] Port "6" IconDisplay "Port number" } Block { BlockType Inport Name "Piston Area" Position [60, 448, 90, 462] Port "7" IconDisplay "Port number" } Block { BlockType Constant Name "A const" Position [260, 95, 325, 125] Value "0.2" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Sum Name "Add" Ports [2, 1] Position [640, 217, 670, 248] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Display Name "Display" Ports [1] Position [750, 335, 840, 365] Decimation "1" Lockdown off } Block { BlockType Product Name "Divide1" Ports [2, 1] Position [455, 162, 485, 193] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Divide2" Ports [2, 1] Position [175, 402, 205, 433] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "Fcn" Position [280, 45, 340, 75] Expr "u(1)^0.8" } Block { BlockType Fcn Name "Fcn1" Position [280, 275, 340, 305] Expr "u(1)^4" } Block { BlockType Fcn Name "Fcn2" Position [280, 325, 340, 355] Expr "u(1)^4" } Block { BlockType Integrator Name "Integrator1" Ports [2, 1] Position [780, 231, 820, 289] ExternalReset "falling" } Block { BlockType Mux Name "Mux" Ports [2, 1] Position [630, 126, 635, 164] ShowName off Inputs "2" DisplayOption "bar" } Block { BlockType SubSystem Name "Reynolds" Ports [3, 1] Position [155, 27, 255, 93] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Reynolds" Location [462, 619, 777, 794] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "omega" Position [20, 18, 50, 32] IconDisplay "Port number" } Block { BlockType Inport Name "half crank" Position [35, 48, 65, 62] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "bore" Position [75, 93, 105, 107] Port "3" IconDisplay "Port number" } Block { BlockType Product Name "Divide1" Ports [3, 1] Position [205, 64, 235, 96] Inputs "**/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "approx mean dynam viscosity" Position [90, 120, 155, 150] Value ".000254" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "mean piston speed" Ports [2, 1] Position [90, 27, 140, 63] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "Reynolds" Position [260, 73, 290, 87] IconDisplay "Port number" } Line { SrcBlock "mean piston speed" SrcPort 1 Points [20, 0; 0, 25] DstBlock "Divide1" DstPort 1 } Line { SrcBlock "approx mean dynam viscosity" SrcPort 1 Points [15, 0; 0, -45] DstBlock "Divide1" DstPort 3 } Line { SrcBlock "omega" SrcPort 1 Points [0, 10] DstBlock "mean piston speed" DstPort 1 } Line { SrcBlock "half crank" SrcPort 1 DstBlock "mean piston speed" DstPort 2 } Line { SrcBlock "bore" SrcPort 1 Points [0, -20] DstBlock "Divide1" DstPort 2 } Line { SrcBlock "Divide1" SrcPort 1 DstBlock "Reynolds" DstPort 1 } } } Block { BlockType Scope Name "Scope1" Ports [1] Position [670, 124, 700, 156] Floating off Location [5, 47, 1445, 894] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "-50000" YMax "1e+006" SaveName "ScopeData6" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Sum Name "Subtract" Ports [2, 1] Position [455, 222, 485, 253] Inputs "+-" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sum Name "Subtract1" Ports [2, 1] Position [410, 297, 440, 328] Inputs "+-" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "k" Position [260, 140, 325, 170] Value ".1" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "k1" Position [385, 360, 450, 390] Value "4.29*10^(-9)" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "k2" Position [235, 443, 275, 467] Value "pi()" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "x1" Ports [3, 1] Position [395, 56, 425, 84] Inputs "3" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "x2" Ports [2, 1] Position [540, 208, 570, 237] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "x3" Ports [2, 1] Position [505, 308, 535, 337] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "x4" Ports [3, 1] Position [300, 415, 330, 445] Inputs "3" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "x5" Ports [2, 1] Position [715, 228, 745, 257] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "Q" Position [880, 253, 910, 267] IconDisplay "Port number" } Line { SrcBlock "bore" SrcPort 1 Points [15, 0] Branch { DstBlock "Reynolds" DstPort 3 } Branch { Points [0, 105; 105, 0] Branch { DstBlock "Divide1" DstPort 2 } Branch { Points [0, 235] DstBlock "x4" DstPort 1 } } } Line { SrcBlock "Reynolds" SrcPort 1 DstBlock "Fcn" DstPort 1 } Line { SrcBlock "Fcn" SrcPort 1 DstBlock "x1" DstPort 1 } Line { SrcBlock "A const" SrcPort 1 Points [30, 0; 0, -40] DstBlock "x1" DstPort 2 } Line { SrcBlock "k" SrcPort 1 Points [40, 0; 0, -75] DstBlock "x1" DstPort 3 } Line { SrcBlock "x1" SrcPort 1 Points [5, 0; 0, 100] DstBlock "Divide1" DstPort 1 } Line { SrcBlock "omega" SrcPort 1 Points [0, 20] DstBlock "Reynolds" DstPort 1 } Line { SrcBlock "half crank" SrcPort 1 Points [0, 5] DstBlock "Reynolds" DstPort 2 } Line { SrcBlock "T cyl" SrcPort 1 Points [65, 0] Branch { DstBlock "Subtract" DstPort 1 } Branch { Points [0, 60] DstBlock "Fcn1" DstPort 1 } } Line { SrcBlock "Twall" SrcPort 1 Points [45, 0] Branch { Points [0, -30] DstBlock "Subtract" DstPort 2 } Branch { Points [0, 65] DstBlock "Fcn2" DstPort 1 } } Line { SrcBlock "Fcn1" SrcPort 1 Points [25, 0; 0, 15] DstBlock "Subtract1" DstPort 1 } Line { SrcBlock "Fcn2" SrcPort 1 Points [25, 0; 0, -20] DstBlock "Subtract1" DstPort 2 } Line { SrcBlock "Divide1" SrcPort 1 Points [15, 0; 0, 35] DstBlock "x2" DstPort 1 } Line { SrcBlock "Subtract" SrcPort 1 Points [15, 0; 0, -10] DstBlock "x2" DstPort 2 } Line { SrcBlock "Subtract1" SrcPort 1 DstBlock "x3" DstPort 1 } Line { SrcBlock "k1" SrcPort 1 Points [35, 0] DstBlock "x3" DstPort 2 } Line { SrcBlock "x2" SrcPort 1 Points [20, 0] Branch { DstBlock "Add" DstPort 1 } Branch { Points [0, -90] DstBlock "Mux" DstPort 1 } } Line { SrcBlock "x3" SrcPort 1 Points [45, 0; 0, -85; 30, 0] Branch { DstBlock "Add" DstPort 2 } Branch { DstBlock "Mux" DstPort 2 } } Line { SrcBlock "Volume" SrcPort 1 DstBlock "Divide2" DstPort 1 } Line { SrcBlock "Piston Area" SrcPort 1 Points [35, 0; 0, -30] DstBlock "Divide2" DstPort 2 } Line { SrcBlock "Divide2" SrcPort 1 Points [5, 0; 0, 10] DstBlock "x4" DstPort 2 } Line { SrcBlock "k2" SrcPort 1 Points [0, -15] DstBlock "x4" DstPort 3 } Line { SrcBlock "Add" SrcPort 1 DstBlock "x5" DstPort 1 } Line { SrcBlock "x4" SrcPort 1 Points [365, 0; 0, -80] Branch { DstBlock "x5" DstPort 2 } Branch { DstBlock "Display" DstPort 1 } } Line { SrcBlock "Mux" SrcPort 1 Points [5, 0; 0, -5] DstBlock "Scope1" DstPort 1 } Line { SrcBlock "x5" SrcPort 1 DstBlock "Integrator1" DstPort 1 } Line { SrcBlock "Integrator1" SrcPort 1 DstBlock "Q" DstPort 1 } } } Block { BlockType SubSystem Name "Initial Air Mass Calculator" Ports [5, 1] Position [660, 109, 800, 191] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Initial Air Mass Calculator" Location [85, 537, 857, 800] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Temperature" Position [115, 28, 145, 42] IconDisplay "Port number" } Block { BlockType Inport Name "Pressure (Pa)" Position [155, 83, 185, 97] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Volume (m^3)" Position [155, 185, 185, 200] Orientation "up" Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "R" Position [75, 93, 105, 107] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "MW" Position [410, 128, 440, 142] Port "5" IconDisplay "Port number" } Block { BlockType Product Name "Divide" Ports [2, 1] Position [390, 37, 420, 68] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Divide1" Ports [2, 1] Position [645, 67, 675, 98] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "P x V" Ports [2, 1] Position [235, 90, 285, 125] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "P x V1" Ports [2, 1] Position [250, 25, 300, 60] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "P x V2" Ports [2, 1] Position [525, 80, 575, 115] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "R1" Position [545, 161, 600, 199] Value "1000" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Outport Name "Mass (kg)" Position [700, 78, 730, 92] IconDisplay "Port number" } Line { SrcBlock "R" SrcPort 1 Points [10, 0; 0, -35; 115, 0] DstBlock "P x V1" DstPort 2 } Line { SrcBlock "P x V" SrcPort 1 Points [80, 0; 0, -65] DstBlock "Divide" DstPort 1 } Line { SrcBlock "P x V1" SrcPort 1 Points [35, 0; 0, 15] DstBlock "Divide" DstPort 2 } Line { SrcBlock "MW" SrcPort 1 Points [30, 0; 0, -30] DstBlock "P x V2" DstPort 2 } Line { SrcBlock "R1" SrcPort 1 Points [10, 0; 0, -90] DstBlock "Divide1" DstPort 2 } Line { SrcBlock "P x V2" SrcPort 1 Points [25, 0; 0, -25] DstBlock "Divide1" DstPort 1 } Line { SrcBlock "Divide" SrcPort 1 Points [40, 0; 0, 35] DstBlock "P x V2" DstPort 1 } Line { SrcBlock "Pressure (Pa)" SrcPort 1 Points [0, 10] DstBlock "P x V" DstPort 1 } Line { SrcBlock "Volume (m^3)" SrcPort 1 Points [0, -65] DstBlock "P x V" DstPort 2 } Line { SrcBlock "Temperature" SrcPort 1 DstBlock "P x V1" DstPort 1 } Line { SrcBlock "Divide1" SrcPort 1 DstBlock "Mass (kg)" DstPort 1 } } } Block { BlockType Constant Name "Initial Energy\nof H2 and Air (J/kg)1" Position [380, 534, 455, 566] Value "1.0485e6" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Initial Energy\nof gas and air (J/kg)2" Position [370, 459, 445, 491] Value "218940" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Initial Energy\nof gas and air (J/kg)3" Position [70, 519, 145, 551] Value "218940" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Initial Energy\nof gas and air (J/kg)4" Position [85, 424, 160, 456] Value "0" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Integrator Name "Intake E intergrator" Ports [2, 1] Position [1250, 771, 1290, 829] ExternalReset "falling" LowerSaturationLimit "0" } Block { BlockType SubSystem Name "Intake Mdot Calculator" Ports [7, 1] Position [875, 650, 1020, 730] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Intake Mdot Calculator" Location [194, 314, 1245, 841] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Crank Angle" Position [55, 193, 85, 207] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Intake Pressure" Position [420, 203, 450, 217] Port "2" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Cyl Pressure" Position [435, 263, 465, 277] Port "3" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Intake Temp" Position [480, 323, 510, 337] Port "4" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "M mass" Position [265, 418, 295, 432] Port "5" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Valve lift" Position [105, 63, 135, 77] Port "6" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Valve dia" Position [110, 33, 140, 47] Port "7" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "A" Ports [2, 1] Position [325, 372, 355, 403] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "Choke" Position [645, 75, 705, 105] Expr "(u(1)*u(2)*u(3)/sqrt(u(6)*u(5)))*(sqrt(u(7)))*(2/(u(7)+1))^((u(7)+1)/(2*(u(7)-1)))" } Block { BlockType Constant Name "Constant1" Position [445, 75, 475, 105] Value ".6" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Constant7" Position [445, 435, 475, 465] Value "1.35" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Fcn Name "Fcn" Position [645, 315, 705, 345] Expr "(2/(u(7)+1))^(u(7)/(u(7)-1))" } Block { BlockType Fcn Name "Fcn1" Position [415, 135, 475, 165] Expr "u(1)*pi" } Block { BlockType Fcn Name "Fcn2" Position [155, 245, 215, 275] Expr "sin(u(1))" } Block { BlockType SubSystem Name "Lift intake" Ports [1, 1] Position [145, 181, 235, 219] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Lift intake" Location [375, 376, 1095, 734] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Crank Angle" Position [75, 188, 105, 202] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "On" Position [200, 140, 230, 170] OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Switch Name "Switch1" Position [410, 180, 440, 210] Threshold "pi()" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType Switch Name "Switch2" Position [295, 180, 325, 210] InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "off" Position [190, 225, 220, 255] Value "0" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Outport Name "Lift" Position [495, 188, 525, 202] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock "Crank Angle" SrcPort 1 Points [140, 0] Branch { DstBlock "Switch2" DstPort 2 } Branch { Points [0, 40; 145, 0] DstBlock "Switch1" DstPort 2 } } Line { SrcBlock "off" SrcPort 1 Points [10, 0] Branch { Points [0, -35] DstBlock "Switch2" DstPort 3 } Branch { Points [0, 10; 120, 0; 0, -65] DstBlock "Switch1" DstPort 1 } } Line { SrcBlock "On" SrcPort 1 Points [25, 0; 0, 30] DstBlock "Switch2" DstPort 1 } Line { SrcBlock "Switch1" SrcPort 1 DstBlock "Lift" DstPort 1 } Line { SrcBlock "Switch2" SrcPort 1 Points [25, 0; 0, 10] DstBlock "Switch1" DstPort 3 } } } Block { BlockType Mux Name "Mux" Ports [7, 1] Position [570, 61, 575, 479] ShowName off Inputs "7" DisplayOption "bar" } Block { BlockType Mux Name "Mux1" Ports [2, 1] Position [275, 266, 280, 304] ShowName off Inputs "2" DisplayOption "bar" } Block { BlockType Fcn Name "No Choke" Position [645, 435, 705, 465] Expr "(u(1)*u(2)*u(3)/sqrt(u(6)*u(5)))*(sqrt(u(4)/u(3)))*sqrt((2*u(7)/(u(7)-1))*(1-(u(4)/u(3))^((u(7)-1)/u(" "7))))" } Block { BlockType Product Name "Product" Ports [3, 1] Position [350, 134, 380, 166] Inputs "3" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product1" Ports [2, 1] Position [280, 211, 310, 244] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "Pt/Po" Position [645, 190, 705, 220] Expr "u(4)/u(3)" } Block { BlockType Constant Name "R" Position [215, 360, 245, 390] Value "8314" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType RelationalOperator Name "Relational\nOperator" Position [770, 252, 800, 283] Operator "<=" InputSameDT off LogicOutDataTypeMode "boolean" OutDataTypeStr "boolean" } Block { BlockType Scope Name "Scope" Ports [1] Position [940, 174, 970, 206] Floating off Location [6, 46, 1430, 869] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "-1" YMax "1" SaveName "ScopeData3" DataFormat "StructureWithTime" SampleTime "0" } Block { BlockType Scope Name "Scope1" Ports [1] Position [315, 259, 345, 291] Floating off Location [147, 479, 782, 821] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "-1" YMax "1" SaveName "ScopeData19" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Switch Name "Switch" Position [845, 255, 875, 285] Criteria "u2 > Threshold" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "Intake Mdot" Position [965, 263, 995, 277] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock "Constant1" SrcPort 1 DstBlock "Mux" DstPort 1 } Line { SrcBlock "Intake Pressure" SrcPort 1 DstBlock "Mux" DstPort 3 } Line { SrcBlock "Cyl Pressure" SrcPort 1 DstBlock "Mux" DstPort 4 } Line { SrcBlock "Intake Temp" SrcPort 1 DstBlock "Mux" DstPort 5 } Line { SrcBlock "Constant7" SrcPort 1 DstBlock "Mux" DstPort 7 } Line { SrcBlock "Mux" SrcPort 1 Points [25, 0] Branch { Points [0, 60] Branch { DstBlock "Fcn" DstPort 1 } Branch { Points [0, 120] DstBlock "No Choke" DstPort 1 } } Branch { Points [0, -65] Branch { DstBlock "Pt/Po" DstPort 1 } Branch { Points [0, -115] DstBlock "Choke" DstPort 1 } } } Line { SrcBlock "Pt/Po" SrcPort 1 Points [20, 0; 0, 55] DstBlock "Relational\nOperator" DstPort 1 } Line { SrcBlock "Fcn" SrcPort 1 Points [20, 0; 0, -55] DstBlock "Relational\nOperator" DstPort 2 } Line { SrcBlock "Relational\nOperator" SrcPort 1 DstBlock "Switch" DstPort 2 } Line { SrcBlock "Choke" SrcPort 1 Points [120, 0] DstBlock "Switch" DstPort 1 } Line { SrcBlock "No Choke" SrcPort 1 Points [120, 0] DstBlock "Switch" DstPort 3 } Line { SrcBlock "Product" SrcPort 1 DstBlock "Fcn1" DstPort 1 } Line { SrcBlock "Switch" SrcPort 1 Points [20, 0] Branch { DstBlock "Intake Mdot" DstPort 1 } Branch { Points [0, -80] DstBlock "Scope" DstPort 1 } } Line { SrcBlock "Fcn1" SrcPort 1 DstBlock "Mux" DstPort 2 } Line { SrcBlock "R" SrcPort 1 Points [30, 0; 0, 5] DstBlock "A" DstPort 1 } Line { SrcBlock "M mass" SrcPort 1 Points [0, -30] DstBlock "A" DstPort 2 } Line { SrcBlock "A" SrcPort 1 DstBlock "Mux" DstPort 6 } Line { SrcBlock "Lift intake" SrcPort 1 Points [10, 0] Branch { Points [0, 95] DstBlock "Mux1" DstPort 2 } Branch { Points [10, 0; 0, 20] DstBlock "Product1" DstPort 1 } } Line { SrcBlock "Crank Angle" SrcPort 1 Points [25, 0] Branch { DstBlock "Lift intake" DstPort 1 } Branch { Points [0, 60] DstBlock "Fcn2" DstPort 1 } } Line { SrcBlock "Fcn2" SrcPort 1 Points [20, 0; 0, 15; 15, 0] Branch { DstBlock "Mux1" DstPort 1 } Branch { Points [0, -40] DstBlock "Product1" DstPort 2 } } Line { SrcBlock "Mux1" SrcPort 1 Points [5, 0; 0, -10] DstBlock "Scope1" DstPort 1 } Line { SrcBlock "Product1" SrcPort 1 Points [10, 0; 0, -70] DstBlock "Product" DstPort 3 } Line { SrcBlock "Valve lift" SrcPort 1 Points [95, 0; 0, 80] DstBlock "Product" DstPort 2 } Line { SrcBlock "Valve dia" SrcPort 1 Points [190, 0] DstBlock "Product" DstPort 1 } Annotation { Name "Cd" Position [433, 89] } Annotation { Name "Ar" Position [535, 143] } Annotation { Name "gamma" Position [412, 451] } Annotation { Name "If Choke, output 1" Position [786, 234] } } } Block { BlockType Integrator Name "Integrator" Ports [2, 1] Position [430, 381, 470, 439] ExternalReset "falling" } Block { BlockType Integrator Name "Mass intergrator" Ports [3, 1] Position [1240, 641, 1280, 699] ExternalReset "falling" InitialConditionSource "external" LowerSaturationLimit "0" } Block { BlockType Mux Name "Mux1" Ports [3, 1] Position [1020, 366, 1030, 414] ShowName off Inputs "3" DisplayOption "bar" } Block { BlockType Product Name "P x V2" Ports [2, 1] Position [355, 375, 405, 410] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType SubSystem Name "P=nRT/V1" Ports [5, 1] Position [980, 120, 1115, 190] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "P=nRT/V1" Location [140, 361, 895, 741] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Temperature" Position [60, 28, 90, 42] IconDisplay "Port number" } Block { BlockType Inport Name "m (kg)" Position [55, 123, 85, 137] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Volume (m^3)" Position [340, 165, 370, 180] Orientation "up" Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "R" Position [85, 88, 115, 102] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "MW" Position [35, 243, 65, 257] Port "5" IconDisplay "Port number" } Block { BlockType Product Name "Divide1" Ports [2, 1] Position [375, 52, 405, 83] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Mole Solver" Ports [2, 1] Position [180, 122, 210, 153] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Mole Solver1" Ports [2, 1] Position [110, 242, 140, 273] Inputs "**" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "P x V1" Ports [4, 1] Position [250, 30, 300, 85] Inputs "4" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "R1" Position [175, 191, 230, 229] OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "R3" Position [15, 276, 70, 314] Value "10^-3" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Outport Name "Pressure" Position [590, 63, 620, 77] IconDisplay "Port number" } Line { SrcBlock "R1" SrcPort 1 DstBlock "P x V1" DstPort 4 } Line { SrcBlock "Divide1" SrcPort 1 DstBlock "Pressure" DstPort 1 } Line { SrcBlock "Volume (m^3)" SrcPort 1 Points [0, -85] DstBlock "Divide1" DstPort 2 } Line { SrcBlock "P x V1" SrcPort 1 DstBlock "Divide1" DstPort 1 } Line { SrcBlock "Mole Solver" SrcPort 1 Points [0, -75] DstBlock "P x V1" DstPort 3 } Line { SrcBlock "m (kg)" SrcPort 1 DstBlock "Mole Solver" DstPort 1 } Line { SrcBlock "R" SrcPort 1 Points [30, 0; 0, -45] DstBlock "P x V1" DstPort 2 } Line { SrcBlock "Temperature" SrcPort 1 DstBlock "P x V1" DstPort 1 } Line { SrcBlock "MW" SrcPort 1 DstBlock "Mole Solver1" DstPort 1 } Line { SrcBlock "R3" SrcPort 1 Points [10, 0; 0, -30] DstBlock "Mole Solver1" DstPort 2 } Line { SrcBlock "Mole Solver1" SrcPort 1 Points [15, 0; 0, -115] DstBlock "Mole Solver" DstPort 2 } } } Block { BlockType Constant Name "R" Position [495, 214, 545, 246] Value "8.31451" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Scope Name "Scope" Ports [1] Position [1360, 654, 1390, 686] Floating off Location [693, 46, 1430, 446] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0.000233952" YMax "0.000233952" SaveName "ScopeData9" DataFormat "StructureWithTime" SampleTime "0" } Block { BlockType Scope Name "Scope1" Ports [1] Position [1070, 374, 1100, 406] Floating off Location [360, 373, 1233, 699] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "3000" SaveName "ScopeData12" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Scope Name "Scope2" Ports [1] Position [1330, 99, 1360, 131] Floating off Location [325, 351, 1062, 751] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "5.75e+006" SaveName "ScopeData24" DataFormat "StructureWithTime" SampleTime "0" } Block { BlockType Switch Name "Switch" Position [905, 410, 935, 440] Threshold "1" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType Switch Name "Switch1" Position [575, 465, 605, 495] Threshold "1" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType Switch Name "Switch2" Position [205, 465, 235, 495] Threshold ".02" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "Wall Temp" Position [195, 790, 260, 820] Value "600" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType SubSystem Name "Weibe" Ports [4, 4] Position [345, 94, 450, 241] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Weibe" Location [-61, 127, 1367, 904] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Theta" Position [95, 268, 125, 282] IconDisplay "Port number" } Block { BlockType Inport Name "E of Burn (J)" Position [635, 168, 665, 182] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Spark" Position [150, 308, 180, 322] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Burn Duration" Position [210, 353, 240, 367] Port "4" IconDisplay "Port number" } Block { BlockType Product Name "% * E" Ports [2, 1] Position [850, 250, 900, 285] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "% * E1" Ports [2, 1] Position [970, 315, 1020, 350] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "% * E2" Ports [2, 1] Position [1180, 485, 1230, 520] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Scope Name "% Burn1" Ports [1] Position [850, 134, 880, 166] Floating off Location [591, 345, 1435, 822] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "1" SaveName "ScopeData3" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Scope Name "% Burn2" Ports [1] Position [1380, 584, 1410, 616] Floating off Location [125, 514, 969, 991] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "3750" SaveName "ScopeData13" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Scope Name "% Burn3" Ports [1] Position [1030, 449, 1060, 481] Floating off Location [538, 401, 1382, 878] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "1000" SaveName "ScopeData17" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Scope Name "% Burn4" Ports [1] Position [1085, 379, 1115, 411] Floating off Location [49, 417, 893, 894] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "1100" YMax "1800" SaveName "ScopeData18" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Constant Name "A" Position [80, 199, 115, 221] Value "5" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Derivative Name "Derivative" Position [800, 365, 830, 395] } Block { BlockType Integrator Name "Integrator1" Ports [2, 1] Position [1270, 576, 1310, 634] ExternalReset "falling" LowerSaturationLimit "0" } Block { BlockType Integrator Name "Integrator2" Ports [2, 1] Position [895, 341, 935, 399] ExternalReset "falling" LowerSaturationLimit "0" } Block { BlockType Constant Name "M + 1" Position [125, 217, 160, 243] Value "3" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Mux Name "Mux" Ports [5, 1] Position [335, 142, 345, 238] ShowName off Inputs "5" DisplayOption "bar" } Block { BlockType SubSystem Name "Switch for Weibe" Ports [4, 1] Position [545, 226, 670, 319] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Switch for Weibe" Location [112, 307, 1387, 790] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Weibe Input" Position [475, 223, 505, 237] IconDisplay "Port number" } Block { BlockType Inport Name "Crank Position" Position [120, 168, 150, 182] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Spark" Position [260, 183, 290, 197] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Burn Duration" Position [300, 398, 330, 412] Port "4" IconDisplay "Port number" } Block { BlockType Scope Name "1" Ports [1] Position [525, 59, 555, 91] Floating off Location [591, 417, 1435, 894] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "1" SaveName "ScopeData14" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Scope Name "2" Ports [1] Position [750, 59, 780, 91] Floating off Location [5, 180, 1449, 1031] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "-1" YMax "1" SaveName "ScopeData15" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Scope Name "3" Ports [1] Position [1020, 74, 1050, 106] Floating off Location [591, 417, 1435, 894] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "1" SaveName "ScopeData16" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Sum Name "Add" Ports [2, 1] Position [445, 382, 475, 413] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "After Burn Value" Position [835, 250, 900, 280] OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Before Burn Value" Position [130, 110, 195, 140] Value "0" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Switch Name "Intake\nCompression\nSwitch" Position [945, 185, 975, 215] Threshold "1" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType Switch Name "Intake\nCompression\nSwitch1" Position [590, 140, 620, 170] Threshold "1" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType RelationalOperator Name "Relational\nOperator" Position [340, 167, 370, 198] Operator "<=" InputSameDT off LogicOutDataTypeMode "boolean" OutDataTypeStr "boolean" } Block { BlockType RelationalOperator Name "Relational\nOperator1" Position [680, 307, 710, 338] Operator "<=" InputSameDT off LogicOutDataTypeMode "boolean" OutDataTypeStr "boolean" } Block { BlockType Outport Name "% E released" Position [880, 133, 910, 147] IconDisplay "Port number" } Line { SrcBlock "Before Burn Value" SrcPort 1 Points [15, 0; 0, 20] DstBlock "Intake\nCompression\nSwitch1" DstPort 1 } Line { SrcBlock "Spark" SrcPort 1 Points [15, 0] Branch { DstBlock "Relational\nOperator" DstPort 2 } Branch { Points [0, 200] DstBlock "Add" DstPort 1 } } Line { SrcBlock "Crank Position" SrcPort 1 Points [80, 0] Branch { DstBlock "Relational\nOperator" DstPort 1 } Branch { Points [0, 140] DstBlock "Relational\nOperator1" DstPort 1 } } Line { SrcBlock "Relational\nOperator" SrcPort 1 Points [75, 0] Branch { Points [25, 0; 0, -30] DstBlock "Intake\nCompression\nSwitch1" DstPort 2 } Branch { Points [0, -110] DstBlock "1" DstPort 1 } } Line { SrcBlock "Weibe Input" SrcPort 1 Points [30, 0; 0, -65] DstBlock "Intake\nCompression\nSwitch1" DstPort 3 } Line { SrcBlock "Relational\nOperator1" SrcPort 1 Points [85, 0; 0, -125] DstBlock "Intake\nCompression\nSwitch" DstPort 2 } Line { SrcBlock "Burn Duration" SrcPort 1 DstBlock "Add" DstPort 2 } Line { SrcBlock "Add" SrcPort 1 Points [90, 0; 0, -70] DstBlock "Relational\nOperator1" DstPort 2 } Line { SrcBlock "Intake\nCompression\nSwitch" SrcPort 1 Points [25, 0] DstBlock "3" DstPort 1 } Line { SrcBlock "After Burn Value" SrcPort 1 Points [10, 0; 0, -55] DstBlock "Intake\nCompression\nSwitch" DstPort 3 } Line { SrcBlock "Intake\nCompression\nSwitch1" SrcPort 1 Points [85, 0] Branch { Points [0, -80] DstBlock "2" DstPort 1 } Branch { Points [60, 0] Branch { Points [5, 0; 0, 35] DstBlock "Intake\nCompression\nSwitch" DstPort 1 } Branch { Points [0, -15] DstBlock "% E released" DstPort 1 } } } } } Block { BlockType SubSystem Name "Switch for Weibe1" Ports [4, 1] Position [965, 536, 1090, 629] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Switch for Weibe1" Location [112, 307, 1387, 790] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Weibe Input" Position [475, 223, 505, 237] IconDisplay "Port number" } Block { BlockType Inport Name "Crank Position" Position [120, 168, 150, 182] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Spark" Position [260, 183, 290, 197] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Burn Duration" Position [300, 398, 330, 412] Port "4" IconDisplay "Port number" } Block { BlockType Scope Name "1" Ports [1] Position [525, 59, 555, 91] Floating off Location [591, 417, 1435, 894] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "1" SaveName "ScopeData14" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Scope Name "2" Ports [1] Position [750, 59, 780, 91] Floating off Location [5, 180, 1449, 1031] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "-1" YMax "1" SaveName "ScopeData15" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Scope Name "3" Ports [1] Position [1020, 74, 1050, 106] Floating off Location [591, 417, 1435, 894] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "1" SaveName "ScopeData16" DataFormat "StructureWithTime" LimitDataPoints off SampleTime "0" } Block { BlockType Sum Name "Add" Ports [2, 1] Position [445, 382, 475, 413] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "After Burn Value" Position [835, 250, 900, 280] Value "0" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Before Burn Value" Position [130, 110, 195, 140] Value "0" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Switch Name "Intake\nCompression\nSwitch" Position [945, 185, 975, 215] Threshold "1" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType Switch Name "Intake\nCompression\nSwitch1" Position [590, 140, 620, 170] Threshold "1" InputSameDT off OutDataType "sfix(16)" OutScaling "2^0" SaturateOnIntegerOverflow off } Block { BlockType RelationalOperator Name "Relational\nOperator" Position [340, 167, 370, 198] Operator "<=" InputSameDT off LogicOutDataTypeMode "boolean" OutDataTypeStr "boolean" } Block { BlockType RelationalOperator Name "Relational\nOperator1" Position [680, 307, 710, 338] Operator "<=" InputSameDT off LogicOutDataTypeMode "boolean" OutDataTypeStr "boolean" } Block { BlockType Outport Name "% E released" Position [880, 133, 910, 147] IconDisplay "Port number" } Line { SrcBlock "Intake\nCompression\nSwitch1" SrcPort 1 Points [85, 0] Branch { Points [60, 0] Branch { Points [0, -15] DstBlock "% E released" DstPort 1 } Branch { Points [5, 0; 0, 35] DstBlock "Intake\nCompression\nSwitch" DstPort 1 } } Branch { Points [0, -80] DstBlock "2" DstPort 1 } } Line { SrcBlock "After Burn Value" SrcPort 1 Points [10, 0; 0, -55] DstBlock "Intake\nCompression\nSwitch" DstPort 3 } Line { SrcBlock "Intake\nCompression\nSwitch" SrcPort 1 Points [25, 0] DstBlock "3" DstPort 1 } Line { SrcBlock "Add" SrcPort 1 Points [90, 0; 0, -70] DstBlock "Relational\nOperator1" DstPort 2 } Line { SrcBlock "Burn Duration" SrcPort 1 DstBlock "Add" DstPort 2 } Line { SrcBlock "Relational\nOperator1" SrcPort 1 Points [85, 0; 0, -125] DstBlock "Intake\nCompression\nSwitch" DstPort 2 } Line { SrcBlock "Weibe Input" SrcPort 1 Points [30, 0; 0, -65] DstBlock "Intake\nCompression\nSwitch1" DstPort 3 } Line { SrcBlock "Relational\nOperator" SrcPort 1 Points [75, 0] Branch { Points [0, -110] DstBlock "1" DstPort 1 } Branch { Points [25, 0; 0, -30] DstBlock "Intake\nCompression\nSwitch1" DstPort 2 } } Line { SrcBlock "Crank Position" SrcPort 1 Points [80, 0] Branch { Points [0, 140] DstBlock "Relational\nOperator1" DstPort 1 } Branch { DstBlock "Relational\nOperator" DstPort 1 } } Line { SrcBlock "Spark" SrcPort 1 Points [15, 0] Branch { Points [0, 200] DstBlock "Add" DstPort 1 } Branch { DstBlock "Relational\nOperator" DstPort 2 } } Line { SrcBlock "Before Burn Value" SrcPort 1 Points [15, 0; 0, 20] DstBlock "Intake\nCompression\nSwitch1" DstPort 1 } } } Block { BlockType Fcn Name "Weibe" Position [420, 215, 480, 245] Expr "1-(exp(-5*( (u(1)-u(2))/ u(3) )^3))" } Block { BlockType Outport Name "Energy " Position [965, 263, 995, 277] IconDisplay "Port number" } Block { BlockType Outport Name "Energy 1" Position [1090, 328, 1120, 342] Port "2" IconDisplay "Port number" } Block { BlockType Outport Name "Energy 2" Position [1400, 498, 1430, 512] Port "3" IconDisplay "Port number" } Block { BlockType Outport Name "%Burn" Position [855, 208, 885, 222] Port "4" IconDisplay "Port number" } Line { SrcBlock "Weibe" SrcPort 1 Points [45, 0] DstBlock "Switch for Weibe" DstPort 1 } Line { SrcBlock "Theta" SrcPort 1 Points [145, 0; 0, -5] Branch { Points [0, -120] DstBlock "Mux" DstPort 1 } Branch { Points [150, 0] Branch { Points [105, 0] DstBlock "Switch for Weibe" DstPort 2 } Branch { Points [0, 300] DstBlock "Switch for Weibe1" DstPort 2 } } } Line { SrcBlock "% * E" SrcPort 1 DstBlock "Energy " DstPort 1 } Line { SrcBlock "Switch for Weibe" SrcPort 1 Points [35, 0] Branch { Points [85, 0] Branch { DstBlock "% * E" DstPort 2 } Branch { Points [0, -60] Branch { Points [0, -65] DstBlock "% Burn1" DstPort 1 } Branch { DstBlock "%Burn" DstPort 1 } } } Branch { Points [0, 105] DstBlock "Derivative" DstPort 1 } } Line { SrcBlock "E of Burn (J)" SrcPort 1 Points [105, 0; 0, 85] Branch { DstBlock "% * E" DstPort 1 } Branch { Points [0, 65] Branch { DstBlock "% * E1" DstPort 1 } Branch { Points [0, 170] DstBlock "% * E2" DstPort 1 } } } Line { SrcBlock "Spark" SrcPort 1 Points [100, 0] Branch { Points [0, -145] DstBlock "Mux" DstPort 2 } Branch { Points [115, 0] Branch { Points [60, 0; 0, -30] DstBlock "Switch for Weibe" DstPort 3 } Branch { Points [0, 280] DstBlock "Switch for Weibe1" DstPort 3 } } } Line { SrcBlock "Mux" SrcPort 1 Points [25, 0; 0, 40] DstBlock "Weibe" DstPort 1 } Line { SrcBlock "Burn Duration" SrcPort 1 Points [75, 0] Branch { DstBlock "Mux" DstPort 3 } Branch { Points [40, 0] Branch { Points [130, 0; 0, -50] DstBlock "Switch for Weibe" DstPort 4 } Branch { Points [0, 260] DstBlock "Switch for Weibe1" DstPort 4 } } } Line { SrcBlock "M + 1" SrcPort 1 DstBlock "Mux" DstPort 5 } Line { SrcBlock "A" SrcPort 1 DstBlock "Mux" DstPort 4 } Line { SrcBlock "Derivative" SrcPort 1 Points [10, 0] Branch { Points [20, 0] Branch { Points [0, 85] DstBlock "% Burn3" DstPort 1 } Branch { Points [0, -25] DstBlock "Integrator2" DstPort 1 } } Branch { Points [0, 165] DstBlock "Switch for Weibe1" DstPort 1 } } Line { SrcBlock "Integrator2" SrcPort 1 Points [5, 0; 0, -30] DstBlock "% * E1" DstPort 2 } Line { SrcBlock "% * E1" SrcPort 1 Points [25, 0] Branch { DstBlock "Energy 1" DstPort 1 } Branch { Points [0, 60] DstBlock "% Burn4" DstPort 1 } } Line { SrcBlock "Switch for Weibe1" SrcPort 1 Points [15, 0; 0, 5; 40, 0; 0, -80] DstBlock "% * E2" DstPort 2 } Line { SrcBlock "Integrator1" SrcPort 1 Points [25, 0] Branch { Points [25, 0] DstBlock "% Burn2" DstPort 1 } Branch { Points [0, -100] DstBlock "Energy 2" DstPort 1 } } Line { SrcBlock "% * E2" SrcPort 1 Points [10, 0; 0, 85] DstBlock "Integrator1" DstPort 1 } } } Block { BlockType Fcn Name "delay deg->rad" Position [150, 170, 210, 200] Expr "2*pi()-(u(1)*2*pi()/360)" } Block { BlockType Constant Name "lam flame\nspeed" Position [110, 245, 135, 275] OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "x2" Ports [2, 1] Position [1070, 830, 1120, 865] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "x3" Ports [2, 1] Position [1180, 765, 1230, 800] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "Pressure" Position [1275, 148, 1305, 162] IconDisplay "Port number" } Line { Labels [0, 0] SrcBlock "Atm Pressure" SrcPort 1 Points [30, 0] Branch { DstBlock "Initial Air Mass Calculator" DstPort 2 } Branch { Points [0, 455] Branch { Points [0, 80] DstBlock "Intake Mdot Calculator" DstPort 2 } Branch { Points [305, 0] DstBlock "Exhaust Mdot Calculator" DstPort 3 } } } Line { SrcBlock "Atm Temp" SrcPort 1 Points [30, 0; 0, 35] Branch { DstBlock "Initial Air Mass Calculator" DstPort 1 } Branch { Points [0, 570] DstBlock "Intake Mdot Calculator" DstPort 4 } } Line { SrcBlock "P x V2" SrcPort 1 DstBlock "Integrator" DstPort 1 } Line { SrcBlock "Theta" SrcPort 1 Points [0, 35] Branch { Points [0, 490; 255, 0] Branch { Points [0, 50] DstBlock "Intake Mdot Calculator" DstPort 1 } Branch { Points [0, -45] DstBlock "Exhaust Mdot Calculator" DstPort 1 } } Branch { Points [245, 0] Branch { Points [40, 0] DstBlock "Weibe" DstPort 1 } Branch { Labels [2, 0] Points [0, 420] DstBlock "Energy" DstPort 1 } } } Line { SrcBlock "Volume" SrcPort 1 Points [40, 0] Branch { DstBlock "P=nRT/V1" DstPort 3 } Branch { Points [0, -105; -910, 0; 0, 780] DstBlock "Heat Transfer" DstPort 6 } } Line { SrcBlock "Torque" SrcPort 1 Points [10, 0] DstBlock "P x V2" DstPort 1 } Line { SrcBlock "Omega" SrcPort 1 Points [5, 0] Branch { Labels [0, 0] Points [0, -165] DstBlock "Crank Duration\nSolver" DstPort 1 } Branch { Points [135, 0] Branch { DstBlock "P x V2" DstPort 2 } Branch { Labels [0, 0] Points [0, 355] DstBlock "Heat Transfer" DstPort 1 } } } Line { SrcBlock "Integrator" SrcPort 1 DstBlock "Add1" DstPort 2 } Line { SrcBlock "Add1" SrcPort 1 DstBlock "Divide" DstPort 1 } Line { SrcBlock "Divide" SrcPort 1 Points [30, 0] DstBlock "Add4" DstPort 1 } Line { SrcBlock "delay deg->rad" SrcPort 1 DstBlock "Weibe" DstPort 3 } Line { SrcBlock "lam flame\nspeed" SrcPort 1 Points [15, 0] Branch { Points [20, 0] DstBlock "Crank Duration\nSolver" DstPort 2 } Branch { Points [0, 35] DstBlock "Crank Duration\nSolver" DstPort 4 } } Line { SrcBlock "Crank Duration\nSolver" SrcPort 1 Points [25, 0; 0, -45] DstBlock "Weibe" DstPort 4 } Line { SrcBlock "Exhaust Mdot Calculator" SrcPort 1 Points [30, 0; 0, 50] Branch { DstBlock "Add Flow" DstPort 1 } Branch { Points [0, 195] DstBlock "x2" DstPort 1 } } Line { SrcBlock "Intake Mdot Calculator" SrcPort 1 Points [35, 0] Branch { DstBlock "Add Flow" DstPort 2 } Branch { Points [0, 85] DstBlock "x3" DstPort 1 } } Line { SrcBlock "Add Flow" SrcPort 1 Points [115, 0] DstBlock "Mass intergrator" DstPort 1 } Line { SrcBlock "Mass intergrator" SrcPort 1 Points [40, 0] Branch { Points [0, -100] Branch { Points [0, -300; -400, 0] Branch { Points [0, -130] DstBlock "P=nRT/V1" DstPort 2 } Branch { Points [-325, 0] DstBlock "Divide" DstPort 2 } } Branch { DstBlock "Energy" DstPort 2 } } Branch { DstBlock "Scope" DstPort 1 } } Line { SrcBlock "Vc" SrcPort 1 DstBlock "Initial Air Mass Calculator" DstPort 3 } Line { SrcBlock "Initial Air Mass Calculator" SrcPort 1 Points [40, 0; 0, 70; 285, 0; 0, 470] DstBlock "Mass intergrator" DstPort 3 } Line { SrcBlock "Add4" SrcPort 1 Points [15, 0] Branch { Points [0, 400] DstBlock "x2" DstPort 2 } Branch { Points [15, 0] DstBlock "H Chem1" DstPort 3 } Branch { Points [0, -90] DstBlock "CxHy Chem" DstPort 3 } } Line { SrcBlock "Switch" SrcPort 1 Points [25, 0] Branch { Points [0, -95; -50, 0; 0, -205] DstBlock "P=nRT/V1" DstPort 1 } Branch { Points [0, 80; -135, 0] Branch { Points [0, 90] DstBlock "Exhaust Mdot Calculator" DstPort 4 } Branch { Points [-550, 0; 0, 295] DstBlock "Heat Transfer" DstPort 4 } } } Line { SrcBlock "x3" SrcPort 1 DstBlock "Intake E intergrator" DstPort 1 } Line { SrcBlock "Intake E intergrator" SrcPort 1 Points [15, 0; 0, 25] DstBlock "Flow\nEnergy" DstPort 1 } Line { SrcBlock "Exhaust E intergrator" SrcPort 1 Points [100, 0; 0, -25] DstBlock "Flow\nEnergy" DstPort 2 } Line { SrcBlock "Flow\nEnergy" SrcPort 1 Points [5, 0; 0, 75; -900, 0; 0, -490] DstBlock "Add1" DstPort 3 } Line { SrcBlock "x2" SrcPort 1 DstBlock "Exhaust E intergrator" DstPort 1 } Line { SrcBlock "Weibe" SrcPort 3 Points [20, 0; 0, 215] DstBlock "Add1" DstPort 1 } Line { SrcBlock "R" SrcPort 1 Points [25, 0] Branch { Points [55, 0] Branch { Points [0, -65] DstBlock "Initial Air Mass Calculator" DstPort 4 } Branch { Points [305, 0; 0, -60] DstBlock "P=nRT/V1" DstPort 4 } } Branch { Points [0, 90] Branch { Points [0, 85] DstBlock "H Chem1" DstPort 1 } Branch { Points [185, 0] DstBlock "CxHy Chem" DstPort 1 } } } Line { SrcBlock "P=nRT/V1" SrcPort 1 Points [70, 0] Branch { DstBlock "Pressure" DstPort 1 } Branch { Points [0, 355; -380, 0; 0, 65] Branch { DstBlock "Exhaust Mdot Calculator" DstPort 2 } Branch { Points [0, 105] DstBlock "Intake Mdot Calculator" DstPort 3 } } Branch { Points [0, -40] DstBlock "Scope2" DstPort 1 } } Line { SrcBlock "Energy" SrcPort 1 Points [5, 0; 0, -250; -1205, 0; 0, -150] DstBlock "Weibe" DstPort 2 } Line { SrcBlock "Fuel" SrcPort 1 Points [20, 0] Branch { DstBlock "Energy" DstPort 3 } Branch { Points [0, 330; -540, 0] Branch { Points [-700, 0] DstBlock "Crank Duration\nSolver" DstPort 3 } Branch { Points [0, -45] Branch { Points [0, -460] DstBlock "Switch" DstPort 2 } Branch { Points [-340, 0; 0, -405] DstBlock "Switch1" DstPort 2 } } } } Line { SrcBlock "Energy" SrcPort 2 Points [20, 0; 0, -360; -580, 0] Branch { DstBlock "P=nRT/V1" DstPort 5 } Branch { Points [-295, 0] Branch { Points [-25, 0] DstBlock "Initial Air Mass Calculator" DstPort 5 } Branch { Points [0, 375; 20, 0] Branch { Points [0, 90] DstBlock "Intake Mdot Calculator" DstPort 5 } Branch { Points [170, 0] DstBlock "Exhaust Mdot Calculator" DstPort 5 } } } } Line { SrcBlock "Valve Lift" SrcPort 1 Points [260, 0] Branch { Points [10, 0; 0, -50] DstBlock "Intake Mdot Calculator" DstPort 6 } Branch { Points [0, -145] DstBlock "Exhaust Mdot Calculator" DstPort 6 } } Line { SrcBlock "Valve Dia" SrcPort 1 Points [245, 0] Branch { Points [40, 0; 0, -95] DstBlock "Intake Mdot Calculator" DstPort 7 } Branch { Points [0, -190] DstBlock "Exhaust Mdot Calculator" DstPort 7 } } Line { SrcBlock "Half Crank" SrcPort 1 Points [30, 0; 0, 20] DstBlock "Heat Transfer" DstPort 2 } Line { Labels [0, 0] SrcBlock "bore" SrcPort 1 Points [30, 0; 0, -20] DstBlock "Heat Transfer" DstPort 3 } Line { SrcBlock "Wall Temp" SrcPort 1 Points [15, 0; 0, 10] DstBlock "Heat Transfer" DstPort 5 } Line { SrcBlock "piston Area" SrcPort 1 Points [170, 0] DstBlock "Heat Transfer" DstPort 7 } Line { SrcBlock "Heat Transfer" SrcPort 1 Points [70, 0; 0, -370] DstBlock "Add1" DstPort 4 } Line { SrcBlock "CxHy Chem" SrcPort 1 Points [40, 0; 0, 35] Branch { DstBlock "Switch" DstPort 1 } Branch { DstBlock "Mux1" DstPort 1 } } Line { SrcBlock "H Chem1" SrcPort 1 Points [25, 0] Branch { DstBlock "Switch" DstPort 3 } Branch { Points [0, -45] DstBlock "Mux1" DstPort 2 } } Line { SrcBlock "Weibe" SrcPort 4 Points [35, 0; 0, 125; 240, 0] Branch { Points [30, 0] DstBlock "CxHy Chem" DstPort 2 } Branch { Points [0, 90] DstBlock "H Chem1" DstPort 2 } } Line { SrcBlock "Initial Energy\nof gas and air (J/kg)2" SrcPort 1 Points [110, 0] DstBlock "Switch1" DstPort 1 } Line { SrcBlock "Switch1" SrcPort 1 Points [550, 0; 0, 310] DstBlock "x3" DstPort 2 } Line { SrcBlock "Mux1" SrcPort 1 DstBlock "Scope1" DstPort 1 } Line { SrcBlock "Clock1" SrcPort 1 DstBlock "Switch2" DstPort 2 } Line { SrcBlock "Initial Energy\nof gas and air (J/kg)3" SrcPort 1 Points [40, 0] DstBlock "Switch2" DstPort 3 } Line { SrcBlock "Initial Energy\nof gas and air (J/kg)4" SrcPort 1 Points [25, 0] DstBlock "Switch2" DstPort 1 } Line { SrcBlock "Switch2" SrcPort 1 Points [80, 0; 0, -25; 360, 0] DstBlock "Add4" DstPort 2 } Line { SrcBlock "Initial Energy\nof H2 and Air (J/kg)1" SrcPort 1 Points [100, 0] DstBlock "Switch1" DstPort 3 } Line { SrcBlock "Spark Advance" SrcPort 1 DstBlock "delay deg->rad" DstPort 1 } Annotation { Position [685, 409] } } } Block { BlockType Mux Name "Mux1" Ports [3, 1] Position [1115, 357, 1125, 453] ShowName off Inputs "3" DisplayOption "bar" } Block { BlockType Reference Name "P vs theta" Ports [2] Position [1060, 28, 1140, 97] SourceBlock "simulink/Sinks/XY Graph" SourceType "XY scope." ShowPortLabels "FromPortIcon" SystemSampleTime "-1" FunctionWithSeparateData "off" RTWMemSecFuncInitTerm "Inherit from model" RTWMemSecFuncExecute "Inherit from model" RTWMemSecDataConstants "Inherit from model" RTWMemSecDataInternal "Inherit from model" RTWMemSecDataParameters "Inherit from model" xmin "0" xmax "4.5*pi" ymin "0" ymax "7e6" st "-1" } Block { BlockType SubSystem Name "Piston Force" Ports [3, 2] Position [110, 310, 285, 400] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Piston Force" Location [480, 289, 1261, 752] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Piston Dia (m)" Position [180, 83, 210, 97] IconDisplay "Port number" } Block { BlockType Inport Name "Case Pressure" Position [140, 233, 170, 247] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Piston Pressure Top" Position [195, 335, 225, 350] Orientation "up" Port "3" IconDisplay "Port number" } Block { BlockType Sum Name "Add" Ports [2, 1] Position [240, 222, 270, 253] Inputs "-+" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Force" Ports [2, 1] Position [410, 157, 440, 188] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "P area" Position [235, 75, 295, 105] Expr "pi*(u/2)^2" } Block { BlockType Outport Name "Piston Force" Position [600, 158, 630, 172] IconDisplay "Port number" } Block { BlockType Outport Name "Piston Area" Position [330, 148, 360, 162] Port "2" IconDisplay "Port number" } Line { SrcBlock "P area" SrcPort 1 Points [10, 0] Branch { Points [85, 0] DstBlock "Force" DstPort 1 } Branch { Points [5, 0] DstBlock "Piston Area" DstPort 1 } } Line { SrcBlock "Add" SrcPort 1 Points [120, 0] DstBlock "Force" DstPort 2 } Line { SrcBlock "Piston Pressure Top" SrcPort 1 Points [15, 0] DstBlock "Add" DstPort 2 } Line { SrcBlock "Piston Dia (m)" SrcPort 1 DstBlock "P area" DstPort 1 } Line { SrcBlock "Force" SrcPort 1 Points [0, -10] DstBlock "Piston Force" DstPort 1 } Line { SrcBlock "Case Pressure" SrcPort 1 Points [0, -10] DstBlock "Add" DstPort 1 } } } Block { BlockType SubSystem Name "Piston Position based on Geometry" Ports [6, 4] Position [385, 194, 585, 411] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Piston Position based on Geometry" Location [70, 219, 1365, 852] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Theta" Position [200, 33, 230, 47] IconDisplay "Port number" } Block { BlockType Inport Name "Crank Offset" Position [25, 28, 55, 42] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Connecting Rod Length" Position [95, 83, 125, 97] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Piston Force" Position [530, 343, 560, 357] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "Piston Area" Position [15, 200, 45, 215] Orientation "down" Port "5" IconDisplay "Port number" } Block { BlockType Inport Name "Compression Ratio" Position [90, 418, 120, 432] Port "6" IconDisplay "Port number" } Block { BlockType Sum Name "Add" Ports [2, 1] Position [720, 517, 750, 548] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType SubSystem Name "Clearance Volume Solver" Ports [3, 2] Position [250, 365, 445, 435] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Clearance Volume Solver" Location [269, 153, 957, 484] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Piston Area" Position [200, 65, 230, 80] Orientation "down" IconDisplay "Port number" } Block { BlockType Inport Name "Half Stroke" Position [100, 68, 130, 82] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Compression Ratio" Position [95, 198, 125, 212] Port "3" IconDisplay "Port number" } Block { BlockType Product Name "Divide" Ports [2, 1] Position [435, 157, 465, 188] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "Fcn" Position [195, 190, 255, 220] Expr "u-1" } Block { BlockType Constant Name "Stroke" Position [70, 125, 135, 155] Value "2" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "Swept Volume calc" Ports [3, 1] Position [230, 91, 270, 149] Inputs "3" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "Clearance Volume" Position [550, 168, 580, 182] IconDisplay "Port number" } Block { BlockType Outport Name "Swept Volume" Position [385, 73, 415, 87] Port "2" IconDisplay "Port number" } Line { SrcBlock "Stroke" SrcPort 1 DstBlock "Swept Volume calc" DstPort 3 } Line { SrcBlock "Fcn" SrcPort 1 Points [160, 0] DstBlock "Divide" DstPort 2 } Line { SrcBlock "Swept Volume calc" SrcPort 1 Points [70, 0; 0, 45; 20, 0] Branch { DstBlock "Divide" DstPort 1 } Branch { Points [-10, 0; 0, -85] DstBlock "Swept Volume" DstPort 1 } } Line { SrcBlock "Piston Area" SrcPort 1 DstBlock "Swept Volume calc" DstPort 1 } Line { SrcBlock "Half Stroke" SrcPort 1 Points [25, 0; 0, 45] DstBlock "Swept Volume calc" DstPort 2 } Line { SrcBlock "Divide" SrcPort 1 DstBlock "Clearance Volume" DstPort 1 } Line { SrcBlock "Compression Ratio" SrcPort 1 DstBlock "Fcn" DstPort 1 } } } Block { BlockType SubSystem Name "Phi solver" Ports [3, 1] Position [395, 222, 540, 298] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Phi solver" Location [620, 446, 1272, 804] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Omega" Position [25, 25, 55, 40] Orientation "down" IconDisplay "Port number" } Block { BlockType Inport Name "Crank offset (half Stroke)" Position [80, 158, 110, 172] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Connecting Rod Length" Position [200, 198, 230, 212] Port "3" IconDisplay "Port number" } Block { BlockType Product Name "Divide" Ports [2, 1] Position [250, 97, 280, 128] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Trigonometry Name "Inverse to Phi" Ports [1, 1] Position [330, 100, 360, 130] Operator "asin" } Block { BlockType Product Name "Product" Ports [2, 1] Position [170, 87, 200, 118] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Trigonometry Name "Trigonometric\nFunction" Ports [1, 1] Position [55, 45, 85, 75] } Block { BlockType Outport Name "Phi" Position [385, 108, 415, 122] IconDisplay "Port number" } Line { SrcBlock "Trigonometric\nFunction" SrcPort 1 Points [30, 0; 0, 35] DstBlock "Product" DstPort 1 } Line { SrcBlock "Product" SrcPort 1 DstBlock "Divide" DstPort 1 } Line { SrcBlock "Divide" SrcPort 1 DstBlock "Inverse to Phi" DstPort 1 } Line { SrcBlock "Omega" SrcPort 1 DstBlock "Trigonometric\nFunction" DstPort 1 } Line { SrcBlock "Crank offset (half Stroke)" SrcPort 1 Points [0, -55] DstBlock "Product" DstPort 2 } Line { SrcBlock "Connecting Rod Length" SrcPort 1 DstBlock "Divide" DstPort 2 } Line { SrcBlock "Inverse to Phi" SrcPort 1 DstBlock "Phi" DstPort 1 } } } Block { BlockType SubSystem Name "Piston Resolver" Ports [3, 1] Position [315, 26, 480, 104] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Piston Resolver" Location [374, 271, 1305, 778] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Crank Position" Position [250, 28, 280, 42] Orientation "left" IconDisplay "Port number" } Block { BlockType Inport Name "Crank Length A" Position [85, 178, 115, 192] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Crank Length L" Position [25, 243, 55, 257] Port "3" IconDisplay "Port number" } Block { BlockType Math Name "Math\nFunction" Ports [1, 1] Position [605, 370, 635, 400] Operator "sqrt" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "Product" Ports [2, 1] Position [255, 162, 285, 193] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product1" Ports [2, 1] Position [215, 227, 245, 258] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product2" Ports [2, 1] Position [105, 242, 135, 273] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product3" Ports [2, 1] Position [435, 247, 465, 278] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product4" Ports [2, 1] Position [380, 207, 410, 238] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sum Name "Subtract" Ports [2, 1] Position [540, 367, 570, 398] Inputs "+-" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sum Name "Sum" Ports [2, 1] Position [630, 170, 650, 190] ShowName off IconShape "round" Inputs "|++" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Trigonometry Name "Trigonometric\nFunction" Ports [1, 1] Position [160, 90, 190, 120] Operator "cos" OutputSignalType "real" } Block { BlockType Trigonometry Name "Trigonometric\nFunction1" Ports [1, 1] Position [265, 90, 295, 120] OutputSignalType "real" } Block { BlockType Outport Name "Length S" Position [700, 173, 730, 187] IconDisplay "Port number" } Line { SrcBlock "Trigonometric\nFunction" SrcPort 1 Points [20, 0; 0, 65] DstBlock "Product" DstPort 1 } Line { SrcBlock "Crank Length A" SrcPort 1 Points [50, 0] Branch { Points [0, 50; 20, 0] Branch { Points [0, 15] DstBlock "Product1" DstPort 2 } Branch { DstBlock "Product1" DstPort 1 } } Branch { DstBlock "Product" DstPort 2 } } Line { SrcBlock "Product" SrcPort 1 DstBlock "Sum" DstPort 1 } Line { SrcBlock "Crank Length L" SrcPort 1 Points [15, 0] Branch { Points [0, 15] DstBlock "Product2" DstPort 2 } Branch { DstBlock "Product2" DstPort 1 } } Line { SrcBlock "Trigonometric\nFunction1" SrcPort 1 Points [45, 0; 0, 110; 0, 0] Branch { DstBlock "Product4" DstPort 1 } Branch { Points [0, 15] DstBlock "Product4" DstPort 2 } } Line { SrcBlock "Product2" SrcPort 1 Points [10, 0; 0, 115] DstBlock "Subtract" DstPort 1 } Line { SrcBlock "Product3" SrcPort 1 Points [30, 0; 0, 125] DstBlock "Subtract" DstPort 2 } Line { SrcBlock "Subtract" SrcPort 1 DstBlock "Math\nFunction" DstPort 1 } Line { SrcBlock "Math\nFunction" SrcPort 1 DstBlock "Sum" DstPort 2 } Line { SrcBlock "Crank Position" SrcPort 1 Points [-15, 0] Branch { Points [-85, 0] DstBlock "Trigonometric\nFunction" DstPort 1 } Branch { Points [0, 70] DstBlock "Trigonometric\nFunction1" DstPort 1 } } Line { SrcBlock "Sum" SrcPort 1 DstBlock "Length S" DstPort 1 } Line { SrcBlock "Product1" SrcPort 1 Points [85, 0; 0, 25] DstBlock "Product3" DstPort 2 } Line { SrcBlock "Product4" SrcPort 1 Points [5, 0] DstBlock "Product3" DstPort 1 } } } Block { BlockType SubSystem Name "Torque Solver" Ports [4, 1] Position [685, 307, 880, 418] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Torque Solver" Location [221, 379, 1175, 765] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Connecting Rod Angle" Position [510, 28, 540, 42] Orientation "left" IconDisplay "Port number" } Block { BlockType Inport Name "Force on Piston" Position [70, 58, 100, 72] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Crank Angle Omega" Position [305, 200, 335, 215] Orientation "down" Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Crank Length" Position [615, 295, 645, 310] Orientation "up" Port "4" IconDisplay "Port number" } Block { BlockType Sum Name "B" Ports [3, 1] Position [455, 151, 505, 209] Inputs "+--" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "Connecting Rod Length1" Position [315, 145, 345, 175] Value "pi/2" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "F CR" Ports [2, 1] Position [195, 57, 225, 88] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" RndMeth "Floor" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Force1" Ports [3, 1] Position [645, 185, 695, 245] Inputs "3" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Trigonometry Name "Trigonometric\nFunction" Ports [1, 1] Position [280, 50, 310, 80] Operator "cos" } Block { BlockType Trigonometry Name "Trigonometric\nFunction1" Ports [1, 1] Position [555, 165, 585, 195] Operator "cos" } Block { BlockType Outport Name "Torque Output" Position [785, 208, 815, 222] IconDisplay "Port number" } Line { SrcBlock "Trigonometric\nFunction" SrcPort 1 Points [40, 0; 0, 45; -175, 0] DstBlock "F CR" DstPort 2 } Line { SrcBlock "Connecting Rod Length1" SrcPort 1 DstBlock "B" DstPort 1 } Line { SrcBlock "B" SrcPort 1 DstBlock "Trigonometric\nFunction1" DstPort 1 } Line { SrcBlock "Trigonometric\nFunction1" SrcPort 1 Points [40, 0] DstBlock "Force1" DstPort 1 } Line { SrcBlock "F CR" SrcPort 1 Points [15, 0; 0, 165; 375, 0; 0, -25] DstBlock "Force1" DstPort 2 } Line { SrcBlock "Connecting Rod Angle" SrcPort 1 Points [-105, 0] Branch { Points [-135, 0] DstBlock "Trigonometric\nFunction" DstPort 1 } Branch { Points [0, 145] DstBlock "B" DstPort 2 } } Line { SrcBlock "Crank Angle Omega" SrcPort 1 Points [120, 0] DstBlock "B" DstPort 3 } Line { SrcBlock "Crank Length" SrcPort 1 DstBlock "Force1" DstPort 3 } Line { SrcBlock "Force on Piston" SrcPort 1 DstBlock "F CR" DstPort 1 } Line { SrcBlock "Force1" SrcPort 1 DstBlock "Torque Output" DstPort 1 } } } Block { BlockType SubSystem Name "Volume Calc" Ports [5, 1] Position [1060, 88, 1215, 192] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Volume Calc" Location [401, 245, 1051, 688] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Half Stroke" Position [25, 33, 55, 47] IconDisplay "Port number" } Block { BlockType Inport Name "Connecting Rod" Position [25, 78, 55, 92] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "S" Position [25, 118, 55, 132] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Piston Area" Position [150, 88, 180, 102] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "Clearance Volume" Position [225, 228, 255, 242] Port "5" IconDisplay "Port number" } Block { BlockType Sum Name "Add" Ports [3, 1] Position [90, 29, 130, 131] Inputs "++-" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sum Name "Add1" Ports [2, 1] Position [280, 196, 320, 249] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Force1" Ports [2, 1] Position [215, 72, 245, 103] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "Volume" Position [345, 218, 375, 232] IconDisplay "Port number" } Line { SrcBlock "Add" SrcPort 1 DstBlock "Force1" DstPort 1 } Line { SrcBlock "Force1" SrcPort 1 Points [0, 125; 15, 0] DstBlock "Add1" DstPort 1 } Line { SrcBlock "Half Stroke" SrcPort 1 Points [15, 0] DstBlock "Add" DstPort 1 } Line { SrcBlock "Connecting Rod" SrcPort 1 Points [15, 0] DstBlock "Add" DstPort 2 } Line { SrcBlock "S" SrcPort 1 Points [15, 0] DstBlock "Add" DstPort 3 } Line { SrcBlock "Piston Area" SrcPort 1 DstBlock "Force1" DstPort 2 } Line { SrcBlock "Add1" SrcPort 1 DstBlock "Volume" DstPort 1 } Line { SrcBlock "Clearance Volume" SrcPort 1 DstBlock "Add1" DstPort 2 } } } Block { BlockType Outport Name "V" Position [1240, 133, 1270, 147] IconDisplay "Port number" } Block { BlockType Outport Name "Total Cylinder Volume" Position [870, 528, 900, 542] Port "2" IconDisplay "Port number" } Block { BlockType Outport Name "Clearance" Position [845, 573, 875, 587] Port "3" IconDisplay "Port number" } Block { BlockType Outport Name "Torque" Position [905, 358, 935, 372] Port "4" IconDisplay "Port number" } Line { SrcBlock "Clearance Volume Solver" SrcPort 1 Points [80, 0] Branch { Points [95, 0] Branch { Points [40, 0; 0, -85; 370, 0; 0, -120] DstBlock "Volume Calc" DstPort 5 } Branch { Points [0, 140] DstBlock "Add" DstPort 1 } } Branch { Points [0, 195] DstBlock "Clearance" DstPort 1 } } Line { SrcBlock "Phi solver" SrcPort 1 Points [0, 5; 95, 0; 0, 60] DstBlock "Torque Solver" DstPort 1 } Line { Labels [0, 0] SrcBlock "Connecting Rod Length" SrcPort 1 Points [95, 0] Branch { Labels [0, 0] Points [0, 30] DstBlock "Volume Calc" DstPort 2 } Branch { Points [45, 0] Branch { Labels [0, 0] Points [0, 195] DstBlock "Phi solver" DstPort 3 } Branch { DstBlock "Piston Resolver" DstPort 3 } } } Line { Labels [0, 0] SrcBlock "Crank Offset" SrcPort 1 Points [15, 0] Branch { Labels [0, 0] Points [0, 365] DstBlock "Clearance Volume Solver" DstPort 2 } Branch { Points [65, 0; 0, 30; 35, 0] Branch { Points [20, 0] Branch { Labels [0, 0] Points [0, 35] DstBlock "Volume Calc" DstPort 1 } Branch { Points [85, 0] Branch { Labels [0, 0] Points [0, 195] DstBlock "Phi solver" DstPort 2 } Branch { DstBlock "Piston Resolver" DstPort 2 } } } Branch { Labels [0, 0] Points [0, 410; 495, 0] DstBlock "Torque Solver" DstPort 4 } } } Line { SrcBlock "Piston Resolver" SrcPort 1 Points [140, 0; 0, 75] DstBlock "Volume Calc" DstPort 3 } Line { SrcBlock "Theta" SrcPort 1 Points [15, 0] Branch { DstBlock "Piston Resolver" DstPort 1 } Branch { Points [0, 110; 125, 0; 0, -20; 5, 0] Branch { DstBlock "Phi solver" DstPort 1 } Branch { Labels [0, 0] Points [230, 0; 0, 245] DstBlock "Torque Solver" DstPort 3 } } } Line { SrcBlock "Piston Area" SrcPort 1 Points [0, 10; 205, 0] Branch { DstBlock "Clearance Volume Solver" DstPort 1 } Branch { Labels [0, 0] Points [0, -70] DstBlock "Volume Calc" DstPort 4 } } Line { SrcBlock "Volume Calc" SrcPort 1 DstBlock "V" DstPort 1 } Line { SrcBlock "Piston Force" SrcPort 1 DstBlock "Torque Solver" DstPort 2 } Line { SrcBlock "Torque Solver" SrcPort 1 DstBlock "Torque" DstPort 1 } Line { SrcBlock "Clearance Volume Solver" SrcPort 2 Points [35, 0; 0, 120] DstBlock "Add" DstPort 2 } Line { SrcBlock "Compression Ratio" SrcPort 1 DstBlock "Clearance Volume Solver" DstPort 3 } Line { SrcBlock "Add" SrcPort 1 DstBlock "Total Cylinder Volume" DstPort 1 } } } Block { BlockType Reference Name "Pressure Volume Graph" Ports [2] Position [1100, 138, 1180, 207] SourceBlock "simulink/Sinks/XY Graph" SourceType "XY scope." ShowPortLabels "FromPortIcon" SystemSampleTime "-1" FunctionWithSeparateData "off" RTWMemSecFuncInitTerm "Inherit from model" RTWMemSecFuncExecute "Inherit from model" RTWMemSecDataConstants "Inherit from model" RTWMemSecDataInternal "Inherit from model" RTWMemSecDataParameters "Inherit from model" xmin "0" xmax "0.0006" ymin "0" ymax "7e6" st "-1" } Block { BlockType Reference Name "Pressure Volume Graph1" Ports [2] Position [1160, 248, 1240, 317] SourceBlock "simulink/Sinks/XY Graph" SourceType "XY scope." ShowPortLabels "FromPortIcon" SystemSampleTime "-1" FunctionWithSeparateData "off" RTWMemSecFuncInitTerm "Inherit from model" RTWMemSecFuncExecute "Inherit from model" RTWMemSecDataConstants "Inherit from model" RTWMemSecDataInternal "Inherit from model" RTWMemSecDataParameters "Inherit from model" xmin "0" xmax "0.0006" ymin ".8e5" ymax "1.3e5" st "-1" } Block { BlockType ToWorkspace Name "To Workspace" Position [1160, 390, 1220, 420] VariableName "Pressure" MaxDataPoints "inf" SampleTime "-1" SaveFormat "Array" } Block { BlockType Outport Name "Torque" Position [665, 465, 680, 495] IconDisplay "Port number" } Block { BlockType Outport Name "Cyl Vol" Position [610, 268, 640, 282] Port "2" IconDisplay "Port number" } Line { SrcBlock "Piston Force" SrcPort 1 Points [0, -15] DstBlock "Piston Position based on Geometry" DstPort 4 } Line { SrcBlock "Piston Position based on Geometry" SrcPort 4 Points [0, 70; 5, 0] Branch { Labels [0, 0] Points [40, 0; 0, -145] DstBlock "Combustion" DstPort 5 } Branch { Points [0, 25] DstBlock "Torque" DstPort 1 } } Line { SrcBlock "Piston Position based on Geometry" SrcPort 1 Points [45, 0] Branch { Labels [0, 0] Points [0, 75] DstBlock "Combustion" DstPort 4 } Branch { Points [0, -65; 400, 0] Branch { DstBlock "Pressure Volume Graph" DstPort 1 } Branch { Points [0, 110] Branch { DstBlock "Pressure Volume Graph1" DstPort 1 } Branch { Points [0, 170] DstBlock "Mux1" DstPort 3 } } } } Line { Labels [0, 0] SrcBlock "Piston Force" SrcPort 2 Points [0, -25; 35, 0] Branch { DstBlock "Piston Position based on Geometry" DstPort 5 } Branch { Points [0, 75] DstBlock "Combustion" DstPort 13 } } Line { SrcBlock "Combustion" SrcPort 1 Points [75, 0] Branch { Points [0, -35] Branch { Points [0, -125] Branch { DstBlock "Pressure Volume Graph" DstPort 2 } Branch { Points [-130, 0; 0, -110] DstBlock "P vs theta" DstPort 2 } } Branch { Points [75, 0] DstBlock "Pressure Volume Graph1" DstPort 2 } } Branch { Points [0, 25] Branch { Points [0, 135; -995, 0; 0, -125] DstBlock "Piston Force" DstPort 3 } Branch { DstBlock "Mux1" DstPort 1 } } } Line { Labels [0, 0] SrcBlock "Atm Temp (K)" SrcPort 1 Points [65, 0] DstBlock "Combustion" DstPort 1 } Line { Labels [0, 0] SrcBlock "Atm Pressure(Pa)" SrcPort 1 Points [30, 0; 0, 15] DstBlock "Combustion" DstPort 2 } Line { SrcBlock "Theta" SrcPort 1 Points [15, 0] Branch { Labels [0, 0] Points [0, 110; 70, 0] DstBlock "Piston Position based on Geometry" DstPort 1 } Branch { Labels [0, 0] Points [345, 0] Branch { Points [0, 235] DstBlock "Combustion" DstPort 3 } Branch { Points [380, 0] Branch { DstBlock "P vs theta" DstPort 1 } Branch { Points [0, 360] DstBlock "Mux1" DstPort 2 } } } } Line { SrcBlock "Piston Position based on Geometry" SrcPort 3 Points [30, 0; 0, 10] DstBlock "Combustion" DstPort 7 } Line { SrcBlock "Crank Offset" SrcPort 1 Points [95, 0; 0, 10] Branch { DstBlock "Piston Position based on Geometry" DstPort 2 } Branch { Points [0, 150] DstBlock "Combustion" DstPort 11 } } Line { SrcBlock "Bore" SrcPort 1 Points [15, 0] Branch { Points [20, 0] DstBlock "Piston Force" DstPort 1 } Branch { Points [0, 110] DstBlock "Combustion" DstPort 12 } } Line { SrcBlock "Omega" SrcPort 1 Points [120, 0] DstBlock "Combustion" DstPort 6 } Line { SrcBlock "Valve Lift" SrcPort 1 Points [45, 0] DstBlock "Combustion" DstPort 9 } Line { SrcBlock "Compression Ratio" SrcPort 1 Points [35, 0] DstBlock "Piston Position based on Geometry" DstPort 6 } Line { SrcBlock "Piston Position based on Geometry" SrcPort 2 DstBlock "Cyl Vol" DstPort 1 } Line { SrcBlock "Rod Length" SrcPort 1 Points [0, 10] DstBlock "Piston Position based on Geometry" DstPort 3 } Line { SrcBlock "Case Pressure" SrcPort 1 DstBlock "Piston Force" DstPort 2 } Line { SrcBlock "Fuel" SrcPort 1 Points [95, 0] DstBlock "Combustion" DstPort 8 } Line { SrcBlock "Valve Dia" SrcPort 1 Points [5, 0] DstBlock "Combustion" DstPort 10 } Line { SrcBlock "Spark Advance" SrcPort 1 DstBlock "Combustion" DstPort 14 } Line { SrcBlock "Mux1" SrcPort 1 DstBlock "To Workspace" DstPort 1 } } } Block { BlockType Outport Name "Torque" Position [315, 123, 345, 137] IconDisplay "Port number" } Block { BlockType Outport Name "Cyl Vol" Position [315, 333, 345, 347] Port "2" IconDisplay "Port number" } Line { SrcBlock "Demux" SrcPort 1 DstBlock "Subsystem" DstPort 3 } Line { SrcBlock "Demux" SrcPort 2 DstBlock "Subsystem" DstPort 4 } Line { SrcBlock "Demux" SrcPort 3 DstBlock "Subsystem" DstPort 5 } Line { SrcBlock "Demux" SrcPort 4 DstBlock "Subsystem" DstPort 6 } Line { SrcBlock "Demux" SrcPort 5 DstBlock "Subsystem" DstPort 7 } Line { SrcBlock "Demux" SrcPort 6 DstBlock "Subsystem" DstPort 8 } Line { SrcBlock "Demux" SrcPort 7 DstBlock "Subsystem" DstPort 9 } Line { SrcBlock "Demux" SrcPort 8 DstBlock "Subsystem" DstPort 10 } Line { SrcBlock "Demux2" SrcPort 1 DstBlock "Subsystem" DstPort 1 } Line { SrcBlock "Demux2" SrcPort 2 DstBlock "Subsystem" DstPort 2 } Line { SrcBlock "Crank Mux" SrcPort 1 DstBlock "Demux2" DstPort 1 } Line { SrcBlock "Subsystem" SrcPort 1 DstBlock "Torque" DstPort 1 } Line { SrcBlock "Geo Mux" SrcPort 1 DstBlock "Demux" DstPort 1 } Line { SrcBlock "Subsystem" SrcPort 2 DstBlock "Cyl Vol" DstPort 1 } Line { SrcBlock "Spark Advance" SrcPort 1 Points [20, 0; 0, 5] DstBlock "Subsystem" DstPort 11 } } } Block { BlockType Display Name "Display" Ports [1] Position [455, 205, 545, 235] Decimation "1" Lockdown off } Block { BlockType SubSystem Name "Friction Model" Ports [3, 1] Position [765, 324, 955, 466] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Friction Model" Location [570, 187, 1188, 717] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Cyl Vol" Position [270, 493, 300, 507] IconDisplay "Port number" } Block { BlockType Inport Name "Crank Mux" Position [150, 68, 180, 82] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "F Mux" Position [25, 278, 55, 292] Port "3" IconDisplay "Port number" } Block { BlockType Demux Name "Demux1" Ports [1, 10] Position [80, 125, 90, 445] ShowName off Outputs "10" DisplayOption "bar" } Block { BlockType Demux Name "Demux3" Ports [1, 2] Position [215, 29, 230, 116] ShowName off Outputs "2" DisplayOption "bar" } Block { BlockType SubSystem Name "Friction" Ports [12, 1] Position [325, 108, 505, 507] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Friction" Location [460, 273, 1326, 720] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Omega" Position [85, 348, 115, 362] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "B (bore)" Position [85, 118, 115, 132] Port "2" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "half S (stroke)" Position [35, 148, 65, 162] Port "3" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Rc (compression ratio)" Position [90, 793, 120, 807] Port "4" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Lx (valve lift)" Position [90, 1333, 120, 1347] Port "5" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "nc (# of cylinders)" Position [85, 213, 115, 227] Port "6" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "nb (# of main bearings)" Position [85, 303, 115, 317] Port "7" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Pa (atm pressure)" Position [80, 758, 110, 772] Port "8" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "ncs (# of camhafts)" Position [90, 1003, 120, 1017] Port "9" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "ncb (# of camshaft bearings)" Position [90, 1038, 120, 1052] Port "10" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "nv (# of valves/cyl)" Position [90, 1188, 120, 1202] Port "11" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Vd (displaced vol per cycle)" Position [90, 1368, 120, 1382] Port "12" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "CAM C1 (600 or 0)" Position [90, 1075, 120, 1105] Value "600" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType SubSystem Name "Calc Aux FMEP (Pa)" Ports [1, 1] Position [2025, 430, 2125, 490] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Calc Aux FMEP (Pa)" Location [485, 209, 1118, 577] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Omega" Position [25, 83, 55, 97] IconDisplay "Port number" } Block { BlockType Constant Name "Aux C1" Position [200, 25, 230, 55] Value "6.23" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Aux C2" Position [190, 126, 240, 154] Value "5.22e-3" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Aux C3" Position [190, 249, 240, 281] Value "-1.79e-7" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Math Name "Math\nFunction" Ports [1, 1] Position [200, 185, 230, 215] Operator "square" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "Product" Ports [2, 1] Position [280, 82, 310, 113] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product1" Ports [2, 1] Position [280, 192, 310, 223] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sum Name "Sum" Ports [3, 1] Position [360, 90, 380, 110] ShowName off IconShape "round" Inputs "+++" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "rad/s to RPM" Position [90, 75, 150, 105] Expr "u*60/(2*pi)" } Block { BlockType Outport Name "Aux FMEP" Position [535, 93, 565, 107] IconDisplay "Port number" } Line { SrcBlock "Aux C1" SrcPort 1 Points [135, 0] DstBlock "Sum" DstPort 1 } Line { SrcBlock "Product" SrcPort 1 DstBlock "Sum" DstPort 2 } Line { SrcBlock "Product1" SrcPort 1 Points [55, 0] DstBlock "Sum" DstPort 3 } Line { SrcBlock "Aux C3" SrcPort 1 Points [10, 0; 0, -50] DstBlock "Product1" DstPort 2 } Line { SrcBlock "Math\nFunction" SrcPort 1 DstBlock "Product1" DstPort 1 } Line { SrcBlock "Aux C2" SrcPort 1 Points [10, 0; 0, -35] DstBlock "Product" DstPort 2 } Line { SrcBlock "rad/s to RPM" SrcPort 1 Points [15, 0] Branch { DstBlock "Product" DstPort 1 } Branch { Points [0, 110] DstBlock "Math\nFunction" DstPort 1 } } Line { SrcBlock "Omega" SrcPort 1 DstBlock "rad/s to RPM" DstPort 1 } Line { SrcBlock "Sum" SrcPort 1 DstBlock "Aux FMEP" DstPort 1 } } } Block { BlockType SubSystem Name "Calc Cam Follower FMEP" Ports [6, 1] Position [1770, 282, 1890, 423] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Calc Cam Follower FMEP" Location [234, 239, 784, 541] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Omega" Position [25, 33, 55, 47] IconDisplay "Port number" } Block { BlockType Inport Name "Cam C1" Position [25, 78, 55, 92] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "nv" Position [25, 148, 55, 162] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "S" Position [25, 178, 55, 192] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "nc" Position [25, 208, 55, 222] Port "5" IconDisplay "Port number" } Block { BlockType Inport Name "Cam C2" Position [25, 238, 55, 252] Port "6" IconDisplay "Port number" } Block { BlockType Fcn Name "Fcn" Position [195, 25, 255, 55] Expr "1+(1000/u)" } Block { BlockType Product Name "Product" Ports [2, 1] Position [315, 32, 345, 63] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product1" Ports [5, 1] Position [305, 115, 360, 255] Inputs "**//*" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sum Name "Sum" Ports [2, 1] Position [390, 90, 410, 110] ShowName off IconShape "round" Inputs "+|+" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "rad/s to RPM" Position [90, 25, 150, 55] Expr "u*60/(2*pi)" } Block { BlockType Outport Name "Cam Follower FMEP" Position [465, 93, 495, 107] IconDisplay "Port number" } Line { SrcBlock "rad/s to RPM" SrcPort 1 Points [10, 0] Branch { DstBlock "Fcn" DstPort 1 } Branch { Points [0, 85] DstBlock "Product1" DstPort 1 } } Line { SrcBlock "Fcn" SrcPort 1 DstBlock "Product" DstPort 1 } Line { SrcBlock "Product" SrcPort 1 Points [50, 0] DstBlock "Sum" DstPort 1 } Line { SrcBlock "Product1" SrcPort 1 Points [35, 0] DstBlock "Sum" DstPort 2 } Line { SrcBlock "Omega" SrcPort 1 DstBlock "rad/s to RPM" DstPort 1 } Line { SrcBlock "S" SrcPort 1 DstBlock "Product1" DstPort 3 } Line { SrcBlock "nc" SrcPort 1 DstBlock "Product1" DstPort 4 } Line { SrcBlock "Cam C1" SrcPort 1 Points [210, 0; 0, -30] DstBlock "Product" DstPort 2 } Line { SrcBlock "Sum" SrcPort 1 DstBlock "Cam Follower FMEP" DstPort 1 } Line { SrcBlock "nv" SrcPort 1 DstBlock "Product1" DstPort 2 } Line { SrcBlock "Cam C2" SrcPort 1 DstBlock "Product1" DstPort 5 } } } Block { BlockType SubSystem Name "Calc Camshaft FMEP" Ports [9, 1] Position [1770, 77, 1885, 253] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Calc Camshaft FMEP" Location [452, 120, 1161, 627] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Omega" Position [45, 33, 75, 47] IconDisplay "Port number" } Block { BlockType Inport Name "Dcb" Position [45, 98, 75, 112] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Lcb" Position [45, 143, 75, 157] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "ncs" Position [45, 183, 75, 197] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "ncb" Position [45, 218, 75, 232] Port "5" IconDisplay "Port number" } Block { BlockType Inport Name "S" Position [45, 333, 75, 347] Port "6" IconDisplay "Port number" } Block { BlockType Inport Name "B" Position [45, 278, 75, 292] Port "7" IconDisplay "Port number" } Block { BlockType Inport Name "nc" Position [45, 373, 75, 387] Port "8" IconDisplay "Port number" } Block { BlockType Inport Name "Loadfactor" Position [45, 408, 75, 422] Port "9" IconDisplay "Port number" } Block { BlockType Constant Name "Constant" Position [125, 434, 180, 466] Value "3.03e-4" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Fcn Name "Dcb^3" Position [120, 90, 180, 120] Expr "u^3" } Block { BlockType Math Name "Math\nFunction" Ports [1, 1] Position [135, 270, 165, 300] Operator "square" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "Product" Ports [10, 1] Position [380, 129, 480, 341] Inputs "*****///**" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "rad/s to RPM" Position [120, 25, 180, 55] Expr "u*60/(2*pi)" } Block { BlockType Outport Name "Camshaft FMEP" Position [550, 228, 580, 242] IconDisplay "Port number" } Line { SrcBlock "Constant" SrcPort 1 Points [125, 0; 0, -125] DstBlock "Product" DstPort 10 } Line { SrcBlock "Math\nFunction" SrcPort 1 Points [40, 0; 0, -40] DstBlock "Product" DstPort 6 } Line { SrcBlock "rad/s to RPM" SrcPort 1 Points [85, 0; 0, 105] DstBlock "Product" DstPort 1 } Line { SrcBlock "Dcb^3" SrcPort 1 Points [65, 0; 0, 60] DstBlock "Product" DstPort 2 } Line { SrcBlock "Omega" SrcPort 1 DstBlock "rad/s to RPM" DstPort 1 } Line { SrcBlock "S" SrcPort 1 Points [155, 0; 0, -75] DstBlock "Product" DstPort 7 } Line { SrcBlock "B" SrcPort 1 DstBlock "Math\nFunction" DstPort 1 } Line { SrcBlock "nc" SrcPort 1 Points [175, 0; 0, -95] DstBlock "Product" DstPort 8 } Line { SrcBlock "Dcb" SrcPort 1 DstBlock "Dcb^3" DstPort 1 } Line { SrcBlock "Lcb" SrcPort 1 Points [150, 0; 0, 35] DstBlock "Product" DstPort 3 } Line { SrcBlock "ncs" SrcPort 1 Points [125, 0; 0, 15] DstBlock "Product" DstPort 4 } Line { SrcBlock "ncb" SrcPort 1 DstBlock "Product" DstPort 5 } Line { SrcBlock "Product" SrcPort 1 DstBlock "Camshaft FMEP" DstPort 1 } Line { SrcBlock "Loadfactor" SrcPort 1 Points [200, 0; 0, -110] DstBlock "Product" DstPort 9 } } } Block { BlockType SubSystem Name "Calc Con Rod FMEP" Ports [7, 1] Position [1005, 420, 1100, 600] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Calc Con Rod FMEP" Location [339, 131, 898, 511] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Omega" Position [25, 38, 55, 52] IconDisplay "Port number" } Block { BlockType Inport Name "Dbig" Position [25, 83, 55, 97] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Lbig" Position [25, 118, 55, 132] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "nbig" Position [25, 158, 55, 172] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "S" Position [25, 243, 55, 257] Port "5" IconDisplay "Port number" } Block { BlockType Inport Name "B" Position [25, 193, 55, 207] Port "6" IconDisplay "Port number" } Block { BlockType Inport Name "nc" Position [25, 283, 55, 297] Port "7" IconDisplay "Port number" } Block { BlockType Constant Name "Constant" Position [205, 301, 255, 329] Value "3.03e-4" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Math Name "Math\nFunction" Ports [1, 1] Position [160, 185, 190, 215] Operator "square" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "Product" Ports [8, 1] Position [350, 27, 420, 203] Inputs "****///*" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "rad/s to RPM" Position [90, 30, 150, 60] Expr "u*60/(2*pi)" } Block { BlockType Outport Name "Con Rod FMEP" Position [470, 108, 500, 122] IconDisplay "Port number" } Line { SrcBlock "Constant" SrcPort 1 Points [55, 0; 0, -130] DstBlock "Product" DstPort 8 } Line { SrcBlock "rad/s to RPM" SrcPort 1 DstBlock "Product" DstPort 1 } Line { SrcBlock "Math\nFunction" SrcPort 1 Points [25, 0; 0, -75] DstBlock "Product" DstPort 5 } Line { SrcBlock "Omega" SrcPort 1 DstBlock "rad/s to RPM" DstPort 1 } Line { SrcBlock "S" SrcPort 1 Points [180, 0; 0, -105] DstBlock "Product" DstPort 6 } Line { SrcBlock "B" SrcPort 1 DstBlock "Math\nFunction" DstPort 1 } Line { SrcBlock "nc" SrcPort 1 Points [200, 0; 0, -125] DstBlock "Product" DstPort 7 } Line { SrcBlock "Dbig" SrcPort 1 Points [110, 0; 0, -25] DstBlock "Product" DstPort 2 } Line { SrcBlock "Lbig" SrcPort 1 Points [130, 0; 0, -40] DstBlock "Product" DstPort 3 } Line { SrcBlock "nbig" SrcPort 1 Points [145, 0; 0, -60] DstBlock "Product" DstPort 4 } Line { SrcBlock "Product" SrcPort 1 DstBlock "Con Rod FMEP" DstPort 1 } } } Block { BlockType SubSystem Name "Calc Lube FMEP" Ports [7, 2] Position [405, 234, 485, 416] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Calc Lube FMEP" Location [321, 139, 1207, 566] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "B" Position [55, 38, 85, 52] IconDisplay "Port number" } Block { BlockType Inport Name "Db" Position [55, 73, 85, 87] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "nc" Position [55, 108, 85, 122] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Lb" Position [55, 243, 85, 257] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "nb" Position [55, 283, 85, 297] Port "5" IconDisplay "Port number" } Block { BlockType Inport Name "S" Position [55, 323, 85, 337] Port "6" IconDisplay "Port number" } Block { BlockType Inport Name "Omega" Position [55, 363, 85, 377] Port "7" IconDisplay "Port number" } Block { BlockType Math Name "B^2" Ports [1, 1] Position [585, 135, 615, 165] Operator "square" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType SubSystem Name "Calc Loadfactor" Ports [5, 1] Position [235, 66, 315, 224] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Calc Loadfactor" Location [551, 234, 1103, 604] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "B" Position [30, 38, 60, 52] IconDisplay "Port number" } Block { BlockType Inport Name "nc" Position [30, 88, 60, 102] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Db" Position [30, 138, 60, 152] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Lb" Position [30, 188, 60, 202] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "nb" Position [30, 238, 60, 252] Port "5" IconDisplay "Port number" } Block { BlockType Constant Name "Constant" Position [145, 260, 175, 290] Value "0.65" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Math Name "Math\nFunction" Ports [1, 1] Position [140, 30, 170, 60] Operator "square" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "Product" Ports [6, 1] Position [295, 124, 365, 246] Inputs "**///*" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "Loadfactor" Position [415, 178, 445, 192] IconDisplay "Port number" } Line { SrcBlock "Constant" SrcPort 1 Points [25, 0; 0, -40] DstBlock "Product" DstPort 6 } Line { SrcBlock "Math\nFunction" SrcPort 1 Points [25, 0; 0, 90] DstBlock "Product" DstPort 1 } Line { SrcBlock "B" SrcPort 1 DstBlock "Math\nFunction" DstPort 1 } Line { SrcBlock "nc" SrcPort 1 Points [65, 0; 0, 60] DstBlock "Product" DstPort 2 } Line { SrcBlock "Db" SrcPort 1 Points [35, 0; 0, 30] DstBlock "Product" DstPort 3 } Line { SrcBlock "Product" SrcPort 1 DstBlock "Loadfactor" DstPort 1 } Line { SrcBlock "Lb" SrcPort 1 DstBlock "Product" DstPort 4 } Line { SrcBlock "nb" SrcPort 1 Points [40, 0; 0, -30] DstBlock "Product" DstPort 5 } } } Block { BlockType Constant Name "Constant" Position [560, 361, 615, 389] Value "3.03e-4" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Fcn Name "Db^3" Position [575, 80, 635, 110] Expr "u^3" } Block { BlockType Product Name "Product" Ports [9, 1] Position [715, 182, 805, 358] Inputs "*****///*" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "rad/s to RPM" Position [370, 195, 430, 225] Expr "u*60/(2*pi)" } Block { BlockType Outport Name "Lube FMEP" Position [835, 263, 865, 277] IconDisplay "Port number" } Block { BlockType Outport Name "Loadfactor" Position [835, 58, 865, 72] Port "2" IconDisplay "Port number" } Line { SrcBlock "Lb" SrcPort 1 Points [55, 0] Branch { Points [0, -75] DstBlock "Calc Loadfactor" DstPort 4 } Branch { DstBlock "Product" DstPort 4 } } Line { SrcBlock "nb" SrcPort 1 Points [80, 0; 0, -20] Branch { DstBlock "Product" DstPort 5 } Branch { Points [0, -65] DstBlock "Calc Loadfactor" DstPort 5 } } Line { SrcBlock "Calc Loadfactor" SrcPort 1 Points [140, 0] Branch { Labels [2, 0] Points [0, 45] DstBlock "Product" DstPort 1 } Branch { Points [0, -80] DstBlock "Loadfactor" DstPort 1 } } Line { SrcBlock "Constant" SrcPort 1 Points [25, 0; 0, -25] DstBlock "Product" DstPort 9 } Line { SrcBlock "rad/s to RPM" SrcPort 1 DstBlock "Product" DstPort 2 } Line { SrcBlock "Db^3" SrcPort 1 Points [35, 0; 0, 135] DstBlock "Product" DstPort 3 } Line { SrcBlock "B^2" SrcPort 1 Points [30, 0; 0, 140] DstBlock "Product" DstPort 6 } Line { SrcBlock "B" SrcPort 1 Points [110, 0] Branch { Points [0, 40] DstBlock "Calc Loadfactor" DstPort 1 } Branch { Points [285, 0; 0, 105] DstBlock "B^2" DstPort 1 } } Line { SrcBlock "Db" SrcPort 1 Points [80, 0] Branch { Points [0, -55; 340, 0; 0, 70] DstBlock "Db^3" DstPort 1 } Branch { Points [0, 65] DstBlock "Calc Loadfactor" DstPort 3 } } Line { SrcBlock "nc" SrcPort 1 Points [110, 0] Branch { DstBlock "Calc Loadfactor" DstPort 2 } Branch { Points [0, 215] DstBlock "Product" DstPort 8 } } Line { SrcBlock "S" SrcPort 1 Points [80, 0; 0, -20] DstBlock "Product" DstPort 7 } Line { SrcBlock "Product" SrcPort 1 DstBlock "Lube FMEP" DstPort 1 } Line { SrcBlock "Omega" SrcPort 1 Points [250, 0; 0, -160] DstBlock "rad/s to RPM" DstPort 1 } } } Block { BlockType SubSystem Name "Calc Oscillating FMEP" Ports [8, 1] Position [1775, 455, 1890, 705] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Calc Oscillating FMEP" Location [174, 109, 923, 681] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Valve C1" Position [25, 33, 55, 47] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Lx" Position [25, 68, 55, 82] Port "2" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Omega" Position [25, 118, 55, 132] Port "3" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "nv" Position [25, 173, 55, 187] Port "4" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "B" Position [25, 208, 55, 222] Port "5" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "S" Position [25, 243, 55, 257] Port "6" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "nc" Position [25, 278, 55, 292] Port "7" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Inport Name "Valve C2" Position [25, 313, 55, 327] Port "8" IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Fcn Name "Fcn" Position [145, 60, 205, 90] Expr "u^1.5" } Block { BlockType Fcn Name "Fcn1" Position [220, 110, 280, 140] Expr "u^0.5" } Block { BlockType Fcn Name "Fcn2" Position [240, 335, 300, 365] Expr "1+(1000/u)" } Block { BlockType Product Name "Product" Ports [7, 1] Position [405, 21, 455, 209] Inputs "****///" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "Product1" Ports [6, 1] Position [405, 301, 455, 489] Inputs "****//" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sum Name "Sum" Ports [2, 1] Position [520, 250, 540, 270] ShowName off IconShape "round" Inputs "+|+" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "rad/s to RPM" Position [115, 110, 175, 140] Expr "u*60/(2*pi)" } Block { BlockType Outport Name "Oscillating FMEP" Position [625, 253, 655, 267] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock "Valve C1" SrcPort 1 DstBlock "Product" DstPort 1 } Line { SrcBlock "Lx" SrcPort 1 Points [15, 0] Branch { DstBlock "Fcn" DstPort 1 } Branch { Points [0, 305] DstBlock "Product1" DstPort 3 } } Line { SrcBlock "Fcn" SrcPort 1 Points [45, 0; 0, -10] DstBlock "Product" DstPort 2 } Line { SrcBlock "Omega" SrcPort 1 DstBlock "rad/s to RPM" DstPort 1 } Line { SrcBlock "rad/s to RPM" SrcPort 1 Points [15, 0] Branch { DstBlock "Fcn1" DstPort 1 } Branch { Points [0, 225] DstBlock "Fcn2" DstPort 1 } } Line { SrcBlock "Fcn1" SrcPort 1 Points [10, 0; 0, -35] DstBlock "Product" DstPort 3 } Line { SrcBlock "nv" SrcPort 1 Points [40, 0] Branch { Points [220, 0; 0, -65] DstBlock "Product" DstPort 4 } Branch { Points [0, 230] DstBlock "Product1" DstPort 4 } } Line { SrcBlock "B" SrcPort 1 Points [280, 0; 0, -75] DstBlock "Product" DstPort 5 } Line { SrcBlock "S" SrcPort 1 Points [65, 0] Branch { Points [235, 0; 0, -85] DstBlock "Product" DstPort 6 } Branch { Points [0, 190] DstBlock "Product1" DstPort 5 } } Line { SrcBlock "nc" SrcPort 1 Points [90, 0] Branch { Points [230, 0; 0, -95] DstBlock "Product" DstPort 7 } Branch { Points [0, 185] DstBlock "Product1" DstPort 6 } } Line { SrcBlock "Product" SrcPort 1 Points [70, 0] DstBlock "Sum" DstPort 1 } Line { SrcBlock "Valve C2" SrcPort 1 DstBlock "Product1" DstPort 1 } Line { SrcBlock "Fcn2" SrcPort 1 DstBlock "Product1" DstPort 2 } Line { SrcBlock "Product1" SrcPort 1 Points [70, 0] DstBlock "Sum" DstPort 2 } Line { SrcBlock "Sum" SrcPort 1 DstBlock "Oscillating FMEP" DstPort 1 } } } Block { BlockType SubSystem Name "Calc Piston FMEP" Ports [2, 1] Position [1005, 73, 1080, 157] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Calc Piston FMEP" Location [323, 249, 922, 579] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Sp" Position [50, 43, 80, 57] IconDisplay "Port number" } Block { BlockType Inport Name "B" Position [50, 88, 80, 102] Port "2" IconDisplay "Port number" } Block { BlockType Constant Name "Constant" Position [140, 135, 170, 165] Value "294" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "Product" Ports [3, 1] Position [230, 66, 280, 124] Inputs "*/*" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "Piston FMEP" Position [345, 88, 375, 102] IconDisplay "Port number" } Line { SrcBlock "Constant" SrcPort 1 Points [20, 0; 0, -35] DstBlock "Product" DstPort 3 } Line { SrcBlock "B" SrcPort 1 DstBlock "Product" DstPort 2 } Line { SrcBlock "Sp" SrcPort 1 Points [110, 0; 0, 25] DstBlock "Product" DstPort 1 } Line { SrcBlock "Product" SrcPort 1 DstBlock "Piston FMEP" DstPort 1 } } } Block { BlockType Sum Name "Calc Reciprocating FMEP" Ports [3, 1] Position [1220, 267, 1255, 313] Inputs "+++" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType SubSystem Name "Calc Ring FMEP" Ports [6, 1] Position [995, 206, 1105, 374] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Calc Ring FMEP" Location [607, 225, 1210, 660] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Omega" Position [35, 43, 65, 57] IconDisplay "Port number" } Block { BlockType Inport Name "B" Position [35, 88, 65, 102] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Sp" Position [35, 228, 65, 242] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Pi" Position [35, 263, 65, 277] Port "4" IconDisplay "Port number" } Block { BlockType Inport Name "Pa" Position [35, 298, 65, 312] Port "5" IconDisplay "Port number" } Block { BlockType Inport Name "Rc" Position [35, 333, 65, 347] Port "6" IconDisplay "Port number" } Block { BlockType SubSystem Name "Calc Ring No Gas Load FMEP" Ports [2, 1] Position [145, 27, 290, 118] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Calc Ring No Gas Load FMEP" Location [375, 306, 1031, 547] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Omega" Position [70, 58, 100, 72] IconDisplay "Port number" } Block { BlockType Inport Name "B" Position [70, 113, 100, 127] Port "2" IconDisplay "Port number" } Block { BlockType Constant Name "Constant" Position [240, 134, 295, 166] Value "4.06e+4" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Fcn Name "Fcn" Position [235, 50, 295, 80] Expr "1+(1000/u)" } Block { BlockType Math Name "Math\nFunction" Ports [1, 1] Position [150, 105, 180, 135] Operator "square" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "Product" Ports [3, 1] Position [395, 56, 440, 114] Inputs "*/*" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "rad/s to RPM" Position [135, 50, 195, 80] Expr "u*60/(2*pi)" } Block { BlockType Outport Name "Ring No Gas Load FMEP" Position [520, 78, 550, 92] IconDisplay "Port number" } Line { SrcBlock "Constant" SrcPort 1 Points [40, 0; 0, -45] DstBlock "Product" DstPort 3 } Line { SrcBlock "rad/s to RPM" SrcPort 1 DstBlock "Fcn" DstPort 1 } Line { SrcBlock "Fcn" SrcPort 1 DstBlock "Product" DstPort 1 } Line { SrcBlock "Math\nFunction" SrcPort 1 Points [130, 0; 0, -35] DstBlock "Product" DstPort 2 } Line { SrcBlock "Omega" SrcPort 1 DstBlock "rad/s to RPM" DstPort 1 } Line { SrcBlock "B" SrcPort 1 DstBlock "Math\nFunction" DstPort 1 } Line { SrcBlock "Product" SrcPort 1 DstBlock "Ring No Gas Load FMEP" DstPort 1 } } } Block { BlockType SubSystem Name "Subsystem" Ports [4, 1] Position [145, 216, 295, 359] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Subsystem" Location [350, 200, 1195, 581] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Sp" Position [35, 153, 65, 167] IconDisplay "Port number" } Block { BlockType Inport Name "Pi" Position [35, 208, 65, 222] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Pa" Position [35, 258, 65, 272] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "Rc" Position [35, 33, 65, 47] Port "4" IconDisplay "Port number" } Block { BlockType Constant Name "Constant" Position [455, 258, 500, 292] Value "6.89" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Fcn Name "Fcn" Position [175, 25, 235, 55] Expr "0.088*u" } Block { BlockType Fcn Name "Fcn1" Position [400, 100, 460, 130] Expr "0.182*u" } Block { BlockType Fcn Name "Fcn2" Position [155, 145, 230, 175] Expr "1.33-0.0238*u" } Block { BlockType Math Name "Math\nFunction" Ports [2, 1] Position [310, 97, 340, 128] Operator "pow" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "Product" Ports [4, 1] Position [590, 184, 640, 266] Inputs "**/*" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sum Name "Sum" Ports [2, 1] Position [495, 105, 515, 125] ShowName off IconShape "round" Inputs "++|" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "Ring Due To Gas FMEP" Position [710, 218, 740, 232] IconDisplay "Port number" } Line { SrcBlock "Rc" SrcPort 1 Points [20, 65; 0, 0] Branch { DstBlock "Fcn" DstPort 1 } Branch { Points [0, 65] DstBlock "Math\nFunction" DstPort 1 } } Line { SrcBlock "Constant" SrcPort 1 Points [40, 0; 0, -20] DstBlock "Product" DstPort 4 } Line { SrcBlock "Math\nFunction" SrcPort 1 DstBlock "Fcn1" DstPort 1 } Line { SrcBlock "Fcn2" SrcPort 1 Points [30, 0; 0, -40] DstBlock "Math\nFunction" DstPort 2 } Line { SrcBlock "Fcn" SrcPort 1 Points [265, 0] DstBlock "Sum" DstPort 1 } Line { SrcBlock "Fcn1" SrcPort 1 DstBlock "Sum" DstPort 2 } Line { SrcBlock "Sum" SrcPort 1 Points [25, 0; 0, 80] DstBlock "Product" DstPort 1 } Line { SrcBlock "Sp" SrcPort 1 DstBlock "Fcn2" DstPort 1 } Line { SrcBlock "Pi" SrcPort 1 DstBlock "Product" DstPort 2 } Line { SrcBlock "Product" SrcPort 1 DstBlock "Ring Due To Gas FMEP" DstPort 1 } Line { SrcBlock "Pa" SrcPort 1 Points [350, 0; 0, -30] DstBlock "Product" DstPort 3 } } } Block { BlockType Sum Name "Sum1" Ports [2, 1] Position [375, 175, 395, 195] ShowName off IconShape "round" Inputs "+|+" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "Ring FMEP" Position [485, 178, 515, 192] IconDisplay "Port number" } Line { SrcBlock "Calc Ring No Gas Load FMEP" SrcPort 1 Points [90, 0] DstBlock "Sum1" DstPort 1 } Line { SrcBlock "Subsystem" SrcPort 1 Points [85, 0] DstBlock "Sum1" DstPort 2 } Line { SrcBlock "Omega" SrcPort 1 DstBlock "Calc Ring No Gas Load FMEP" DstPort 1 } Line { SrcBlock "B" SrcPort 1 DstBlock "Calc Ring No Gas Load FMEP" DstPort 2 } Line { SrcBlock "Sp" SrcPort 1 DstBlock "Subsystem" DstPort 1 } Line { SrcBlock "Sum1" SrcPort 1 DstBlock "Ring FMEP" DstPort 1 } Line { SrcBlock "Pi" SrcPort 1 DstBlock "Subsystem" DstPort 2 } Line { SrcBlock "Pa" SrcPort 1 DstBlock "Subsystem" DstPort 3 } Line { SrcBlock "Rc" SrcPort 1 DstBlock "Subsystem" DstPort 4 } } } Block { BlockType Sum Name "Calc Rotating FMEP" Ports [3, 1] Position [610, 257, 645, 303] Inputs "+++" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType SubSystem Name "Calc Seal FMEP" Ports [4, 1] Position [405, 65, 490, 155] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Calc Seal FMEP" Location [368, 159, 1037, 439] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Db" Position [75, 18, 105, 32] IconDisplay "Port number" } Block { BlockType Inport Name "B" Position [75, 58, 105, 72] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "S" Position [75, 118, 105, 132] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "nc" Position [75, 153, 105, 167] Port "4" IconDisplay "Port number" } Block { BlockType Constant Name "Constant" Position [165, 196, 220, 224] Value "122000" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Math Name "Math\nFunction" Ports [1, 1] Position [180, 50, 210, 80] Operator "square" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "Product" Ports [5, 1] Position [395, 68, 455, 182] Inputs "*///*" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "Seal FMEP" Position [545, 118, 575, 132] IconDisplay "Port number" } Line { SrcBlock "Math\nFunction" SrcPort 1 Points [95, 0; 0, 40] DstBlock "Product" DstPort 2 } Line { SrcBlock "Constant" SrcPort 1 Points [155, 0] DstBlock "Product" DstPort 5 } Line { SrcBlock "B" SrcPort 1 DstBlock "Math\nFunction" DstPort 1 } Line { SrcBlock "Product" SrcPort 1 DstBlock "Seal FMEP" DstPort 1 } Line { SrcBlock "Db" SrcPort 1 Points [225, 0; 0, 60] DstBlock "Product" DstPort 1 } Line { SrcBlock "S" SrcPort 1 DstBlock "Product" DstPort 3 } Line { SrcBlock "nc" SrcPort 1 Points [135, 0; 0, -15] DstBlock "Product" DstPort 4 } } } Block { BlockType SubSystem Name "Calc T(friction)" Ports [3, 1] Position [2480, 339, 2575, 411] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Calc T(friction)" Location [294, 155, 834, 461] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Total FMEP" Position [25, 33, 55, 47] IconDisplay "Port number" } Block { BlockType Inport Name "Vd" Position [115, 58, 145, 72] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Omega" Position [25, 193, 55, 207] Port "3" IconDisplay "Port number" } Block { BlockType Product Name "Clac T(friction)" Ports [3, 1] Position [290, 29, 330, 101] Inputs "**/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "Constant" Position [170, 74, 215, 106] Value "4*pi" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Math Name "Math\nFunction" Ports [1, 1] Position [160, 185, 190, 215] Operator "square" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Outport Name "T(friction)" Position [435, 58, 465, 72] IconDisplay "Port number" } Line { SrcBlock "Total FMEP" SrcPort 1 DstBlock "Clac T(friction)" DstPort 1 } Line { SrcBlock "Vd" SrcPort 1 DstBlock "Clac T(friction)" DstPort 2 } Line { SrcBlock "Clac T(friction)" SrcPort 1 DstBlock "T(friction)" DstPort 1 } Line { SrcBlock "Constant" SrcPort 1 DstBlock "Clac T(friction)" DstPort 3 } } } Block { BlockType Sum Name "Calc Total FMEP" Ports [4, 1] Position [2235, 313, 2280, 382] Inputs "++++" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType SubSystem Name "Calc Turb FMEP" Ports [4, 1] Position [400, 483, 490, 607] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Calc Turb FMEP" Location [422, 188, 1126, 533] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Inport Name "Db" Position [40, 33, 70, 47] IconDisplay "Port number" } Block { BlockType Inport Name "nb" Position [40, 88, 70, 102] Port "2" IconDisplay "Port number" } Block { BlockType Inport Name "Omega" Position [40, 153, 70, 167] Port "3" IconDisplay "Port number" } Block { BlockType Inport Name "nc" Position [40, 208, 70, 222] Port "4" IconDisplay "Port number" } Block { BlockType Constant Name "Constant" Position [225, 235, 280, 265] Value "1.35e-10" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Math Name "Math\nFunction" Ports [1, 1] Position [200, 25, 230, 55] Operator "square" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Math Name "Math\nFunction1" Ports [1, 1] Position [200, 145, 230, 175] Operator "square" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "Product" Ports [5, 1] Position [345, 55, 415, 185] Inputs "***/*" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Fcn Name "rad/s to RPM" Position [105, 145, 165, 175] Expr "u*60/(2*pi)" } Block { BlockType Outport Name "Turb FMEP" Position [465, 113, 495, 127] IconDisplay "Port number" } Line { SrcBlock "Constant" SrcPort 1 Points [25, 0; 0, -80] DstBlock "Product" DstPort 5 } Line { SrcBlock "Math\nFunction" SrcPort 1 Points [15, 0; 0, 30] DstBlock "Product" DstPort 1 } Line { SrcBlock "rad/s to RPM" SrcPort 1 DstBlock "Math\nFunction1" DstPort 1 } Line { SrcBlock "Db" SrcPort 1 DstBlock "Math\nFunction" DstPort 1 } Line { SrcBlock "Omega" SrcPort 1 DstBlock "rad/s to RPM" DstPort 1 } Line { SrcBlock "nc" SrcPort 1 Points [210, 0; 0, -70] DstBlock "Product" DstPort 4 } Line { SrcBlock "Product" SrcPort 1 DstBlock "Turb FMEP" DstPort 1 } Line { SrcBlock "Math\nFunction1" SrcPort 1 Points [25, 0; 0, -40] DstBlock "Product" DstPort 3 } Line { SrcBlock "nb" SrcPort 1 DstBlock "Product" DstPort 2 } } } Block { BlockType Sum Name "Calc Valve Train FMEP" Ports [3, 1] Position [2060, 332, 2095, 378] Inputs "+++" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^-10" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "Cam C2 (0 or 0.0227)" Position [90, 1130, 120, 1160] Value "600" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Cam dia" Position [20, 935, 60, 965] Value ".34" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Cam length" Position [15, 980, 55, 1010] Value ".2224" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "Clac T(friction)" Ports [2, 1] Position [2370, 341, 2410, 414] Inputs "*/" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "Constant" Position [2295, 379, 2340, 411] Value "1000" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Db/D" Position [65, 55, 95, 85] Value "0.6" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "Force" Ports [2, 1] Position [145, 62, 175, 93] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Constant Name "L/D" Position [15, 255, 45, 285] Value "0.222" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Mux Name "Mux" Ports [3, 1] Position [1215, 391, 1220, 429] ShowName off Inputs "3" DisplayOption "bar" } Block { BlockType Mux Name "Mux1" Ports [3, 1] Position [615, 361, 620, 399] ShowName off Inputs "3" DisplayOption "bar" } Block { BlockType Mux Name "Mux2" Ports [3, 1] Position [2060, 696, 2065, 734] ShowName off Inputs "3" DisplayOption "bar" } Block { BlockType Scope Name "T" Ports [1] Position [2390, 264, 2420, 296] Floating off Location [183, 80, 1295, 830] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "1.28571e+008" YMax "1.28571e+008" SaveName "ScopeData4" DataFormat "StructureWithTime" SampleTime "0" } Block { BlockType Scope Name "T1" Ports [1] Position [1270, 394, 1300, 426] Floating off Location [248, 153, 1360, 903] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "7.5e+006" SaveName "ScopeData25" DataFormat "StructureWithTime" SampleTime "0" } Block { BlockType Scope Name "T2" Ports [1] Position [670, 364, 700, 396] Floating off Location [183, 80, 1295, 830] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "1.1e+007" SaveName "ScopeData26" DataFormat "StructureWithTime" SampleTime "0" } Block { BlockType Scope Name "T3" Ports [1] Position [2115, 699, 2145, 731] Floating off Location [183, 80, 1295, 830] Open off NumInputPorts "1" List { ListType AxesTitles axes1 "%" } YMin "0" YMax "1.2e+008" SaveName "ScopeData27" DataFormat "StructureWithTime" SampleTime "0" } Block { BlockType Constant Name "Valve C1" Position [90, 1225, 120, 1255] Value "0" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Valve C2" Position [90, 1280, 120, 1310] Value "0" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "const" Position [30, 185, 60, 215] Value "2" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "crank pin dia" Position [15, 810, 45, 840] Value "0.57" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "crank pin length" Position [15, 860, 55, 890] Value "0.2337" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Product Name "x" Ports [2, 1] Position [175, 157, 205, 188] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "x1" Ports [2, 1] Position [140, 247, 170, 278] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "x2" Ports [2, 1] Position [120, 597, 150, 628] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "x3" Ports [2, 1] Position [95, 817, 125, 848] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "x4" Ports [2, 1] Position [95, 857, 125, 888] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "x5" Ports [2, 1] Position [115, 917, 145, 948] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Product Name "x6" Ports [2, 1] Position [125, 962, 155, 993] InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Outport Name "T(friction)" Position [2615, 368, 2645, 382] IconDisplay "Port number" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock "nc (# of cylinders)" SrcPort 1 Points [65, 0] Branch { Points [80, 0] Branch { Points [0, -80] DstBlock "Calc Seal FMEP" DstPort 4 } Branch { Labels [0, 0] Points [0, 80] Branch { DstBlock "Calc Lube FMEP" DstPort 3 } Branch { Labels [0, 0] Points [0, 290] Branch { DstBlock "Calc Turb FMEP" DstPort 4 } Branch { Labels [0, 0] Points [0, 105; 535, 0] Branch { Points [0, -110] DstBlock "Calc Con Rod FMEP" DstPort 7 } Branch { Labels [0, 0] Points [630, 0; 0, -40] Branch { Points [0, -265] Branch { Points [0, -165] DstBlock "Calc Camshaft FMEP" DstPort 8 } Branch { Labels [0, 0] DstBlock "Calc Cam Follower FMEP" DstPort 5 } } Branch { DstBlock "Calc Oscillating FMEP" DstPort 7 } } } } } } Branch { Points [0, 290; -25, 0; 0, 395; 135, 0; 0, -100; 645, 0; 0, -295] DstBlock "Calc Con Rod FMEP" DstPort 4 } } Line { SrcBlock "Calc Seal FMEP" SrcPort 1 Points [20, 0; 0, 155; 40, 0] Branch { DstBlock "Calc Rotating FMEP" DstPort 1 } Branch { Points [0, 125] DstBlock "Mux1" DstPort 3 } } Line { SrcBlock "B (bore)" SrcPort 1 Points [5, 0] Branch { Points [120, 0] Branch { Points [0, -25] DstBlock "Calc Seal FMEP" DstPort 2 } Branch { Labels [0, 0] Points [0, 125] Branch { DstBlock "Calc Lube FMEP" DstPort 1 } Branch { Labels [0, 0] Points [0, 390; 515, 0] Branch { Points [0, -80] Branch { Points [0, -315] Branch { Points [0, -110] DstBlock "Calc Piston FMEP" DstPort 2 } Branch { Labels [0, 0] DstBlock "Calc Ring FMEP" DstPort 2 } } Branch { Labels [0, 0] DstBlock "Calc Con Rod FMEP" DstPort 6 } } Branch { Labels [0, 0] Points [620, 0; 0, -45] Branch { Points [0, -390] DstBlock "Calc Camshaft FMEP" DstPort 7 } Branch { DstBlock "Calc Oscillating FMEP" DstPort 5 } } } } } Branch { Points [0, -40] DstBlock "Force" DstPort 2 } Branch { Points [0, 65] Branch { DstBlock "x1" DstPort 1 } Branch { Points [0, 65; -60, 0; 0, 570] DstBlock "x3" DstPort 1 } } } Line { SrcBlock "Force" SrcPort 1 Points [45, 0] Branch { DstBlock "Calc Seal FMEP" DstPort 1 } Branch { Labels [0, 0] Points [0, 195] Branch { DstBlock "Calc Lube FMEP" DstPort 2 } Branch { Labels [0, 0] Points [0, 225] DstBlock "Calc Turb FMEP" DstPort 1 } } } Line { SrcBlock "Omega" SrcPort 1 Points [45, 0; 0, 45] Branch { Points [150, 0] Branch { DstBlock "Calc Lube FMEP" DstPort 7 } Branch { Labels [0, 0] Points [0, 160] Branch { DstBlock "Calc Turb FMEP" DstPort 3 } Branch { Labels [0, 0] Points [0, 95; 445, 0] Branch { Points [0, -220] Branch { Points [0, -220] DstBlock "Calc Ring FMEP" DstPort 1 } Branch { Labels [0, 0] DstBlock "Calc Con Rod FMEP" DstPort 1 } } Branch { Labels [0, 0] Points [620, 0] Branch { Points [0, -120] Branch { Points [0, -245] Branch { Points [0, -205] DstBlock "Calc Camshaft FMEP" DstPort 1 } Branch { Labels [0, 0] DstBlock "Calc Cam Follower FMEP" DstPort 1 } } Branch { DstBlock "Calc Oscillating FMEP" DstPort 3 } } Branch { Labels [0, 0] Points [0, 75; 560, 0; 0, -210] Branch { Points [0, -60] DstBlock "Calc Aux FMEP (Pa)" DstPort 1 } Branch { Labels [0, 0] Points [505, 0; 0, -120] DstBlock "Calc T(friction)" DstPort 3 } } } } } } Branch { Points [-60, 0] DstBlock "x2" DstPort 1 } } Line { SrcBlock "Calc Lube FMEP" SrcPort 1 Points [75, 0] Branch { DstBlock "Calc Rotating FMEP" DstPort 2 } Branch { Points [0, 100] DstBlock "Mux1" DstPort 2 } } Line { Labels [0, 0] SrcBlock "x1" SrcPort 1 Points [25, 0; 0, 60] DstBlock "Calc Lube FMEP" DstPort 4 } Line { Labels [0, 0] SrcBlock "nb (# of main bearings)" SrcPort 1 Points [60, 0; 0, 40; 110, 0] Branch { DstBlock "Calc Lube FMEP" DstPort 5 } Branch { Points [0, 180] DstBlock "Calc Turb FMEP" DstPort 2 } } Line { SrcBlock "Calc Turb FMEP" SrcPort 1 Points [20, 0; 0, -250; 70, 0] Branch { DstBlock "Calc Rotating FMEP" DstPort 3 } Branch { Points [0, 75] DstBlock "Mux1" DstPort 1 } } Line { SrcBlock "Calc Rotating FMEP" SrcPort 1 Points [50, 0; 0, -255; 1510, 0; 0, 300] DstBlock "Calc Total FMEP" DstPort 1 } Line { SrcBlock "x2" SrcPort 1 Points [45, 0; 0, 100; 620, 0; 0, -440] Branch { Points [0, -180] DstBlock "Calc Piston FMEP" DstPort 1 } Branch { Labels [0, 0] DstBlock "Calc Ring FMEP" DstPort 3 } } Line { SrcBlock "Calc Ring FMEP" SrcPort 1 Points [55, 0] Branch { DstBlock "Calc Reciprocating FMEP" DstPort 2 } Branch { Points [0, 120] DstBlock "Mux" DstPort 2 } } Line { SrcBlock "Calc Piston FMEP" SrcPort 1 Points [55, 0; 0, 160; 15, 0] Branch { DstBlock "Calc Reciprocating FMEP" DstPort 1 } Branch { Points [0, 145] DstBlock "Mux" DstPort 3 } } Line { SrcBlock "Pa (atm pressure)" SrcPort 1 Points [25, 0] Branch { Points [85, 0; 0, -20; 635, 0; 0, -410] DstBlock "Calc Ring FMEP" DstPort 5 } Branch { Points [0, -35; 700, 0; 0, -425] DstBlock "Calc Ring FMEP" DstPort 4 } } Line { SrcBlock "Rc (compression ratio)" SrcPort 1 Points [120, 0; 0, -40; 635, 0; 0, -395] DstBlock "Calc Ring FMEP" DstPort 6 } Line { SrcBlock "x3" SrcPort 1 Points [135, 0; 0, -60; 635, 0; 0, -315] DstBlock "Calc Con Rod FMEP" DstPort 2 } Line { SrcBlock "x4" SrcPort 1 Points [150, 0; 0, -85; 640, 0; 0, -305] DstBlock "Calc Con Rod FMEP" DstPort 3 } Line { Labels [2, 0] SrcBlock "Calc Con Rod FMEP" SrcPort 1 Points [35, 0; 0, -205; 50, 0] Branch { DstBlock "Calc Reciprocating FMEP" DstPort 3 } Branch { Points [0, 95] DstBlock "Mux" DstPort 1 } } Line { SrcBlock "Calc Reciprocating FMEP" SrcPort 1 Points [45, 0; 0, -250; 890, 0; 0, 300] DstBlock "Calc Total FMEP" DstPort 2 } Line { SrcBlock "x5" SrcPort 1 Points [165, 0; 0, -110; 1140, 0; 0, -720] DstBlock "Calc Camshaft FMEP" DstPort 2 } Line { SrcBlock "x6" SrcPort 1 Points [175, 0; 0, -135; 1145, 0; 0, -720] DstBlock "Calc Camshaft FMEP" DstPort 3 } Line { SrcBlock "ncs (# of camhafts)" SrcPort 1 Points [230, 0; 0, -145; 1150, 0; 0, -720] DstBlock "Calc Camshaft FMEP" DstPort 4 } Line { SrcBlock "ncb (# of camshaft bearings)" SrcPort 1 Points [250, 0; 0, -160; 1150, 0; 0, -720] DstBlock "Calc Camshaft FMEP" DstPort 5 } Line { SrcBlock "Calc Lube FMEP" SrcPort 2 Points [50, 0; 0, 535; 1005, 0; 0, -660] DstBlock "Calc Camshaft FMEP" DstPort 9 } Line { SrcBlock "Calc Camshaft FMEP" SrcPort 1 Points [30, 0; 0, 175; 55, 0] Branch { DstBlock "Calc Valve Train FMEP" DstPort 1 } Branch { Points [0, 385] DstBlock "Mux2" DstPort 3 } } Line { SrcBlock "CAM C1 (600 or 0)" SrcPort 1 Points [270, 0; 0, -170; 1170, 0; 0, -605] DstBlock "Calc Cam Follower FMEP" DstPort 2 } Line { SrcBlock "Cam C2 (0 or 0.0227)" SrcPort 1 Points [290, 0; 0, -205; 1170, 0; 0, -525] DstBlock "Calc Cam Follower FMEP" DstPort 6 } Line { SrcBlock "nv (# of valves/cyl)" SrcPort 1 Points [310, 0; 0, -230; 1175, 0; 0, -400] Branch { Points [0, -225] DstBlock "Calc Cam Follower FMEP" DstPort 3 } Branch { DstBlock "Calc Oscillating FMEP" DstPort 4 } } Line { SrcBlock "Calc Cam Follower FMEP" SrcPort 1 Points [95, 0] Branch { DstBlock "Calc Valve Train FMEP" DstPort 2 } Branch { Points [0, 360] DstBlock "Mux2" DstPort 2 } } Line { SrcBlock "Valve C1" SrcPort 1 Points [330, 0; 0, -255; 1180, 0; 0, -510] DstBlock "Calc Oscillating FMEP" DstPort 1 } Line { SrcBlock "Valve C2" SrcPort 1 Points [350, 0; 0, -290; 1185, 0; 0, -320] DstBlock "Calc Oscillating FMEP" DstPort 8 } Line { SrcBlock "Lx (valve lift)" SrcPort 1 Points [370, 0; 0, -310; 1190, 0; 0, -525] DstBlock "Calc Oscillating FMEP" DstPort 2 } Line { SrcBlock "Calc Oscillating FMEP" SrcPort 1 Points [25, 0; 0, -210; 85, 0] Branch { DstBlock "Calc Valve Train FMEP" DstPort 3 } Branch { Points [0, 335] DstBlock "Mux2" DstPort 1 } } Line { SrcBlock "Calc Valve Train FMEP" SrcPort 1 DstBlock "Calc Total FMEP" DstPort 3 } Line { SrcBlock "Calc T(friction)" SrcPort 1 DstBlock "T(friction)" DstPort 1 } Line { SrcBlock "Vd (displaced vol per cycle)" SrcPort 1 Points [390, 0; 0, -325; 1195, 0; 0, -295; 250, 0; 0, -165; 460, 0; 0, -215] DstBlock "Calc T(friction)" DstPort 2 } Line { SrcBlock "Calc Total FMEP" SrcPort 1 Points [60, 0] Branch { Points [0, -70] DstBlock "T" DstPort 1 } Branch { Points [10, 0] DstBlock "Clac T(friction)" DstPort 1 } } Line { SrcBlock "Db/D" SrcPort 1 DstBlock "Force" DstPort 1 } Line { SrcBlock "L/D" SrcPort 1 DstBlock "x1" DstPort 2 } Line { SrcBlock "const" SrcPort 1 Points [0, -20] DstBlock "x" DstPort 2 } Line { SrcBlock "x" SrcPort 1 Points [35, 0] Branch { Points [0, -35; 145, 0] DstBlock "Calc Seal FMEP" DstPort 3 } Branch { Labels [0, 0] Points [0, 200] Branch { DstBlock "Calc Lube FMEP" DstPort 6 } Branch { Labels [0, 0] Points [0, 300; 535, 0] Branch { Points [0, -140] DstBlock "Calc Con Rod FMEP" DstPort 5 } Branch { Labels [0, 0] Points [625, 0; 0, -50] Branch { Points [0, -260] Branch { Points [0, -180] DstBlock "Calc Camshaft FMEP" DstPort 6 } Branch { Labels [0, 0] DstBlock "Calc Cam Follower FMEP" DstPort 4 } } Branch { DstBlock "Calc Oscillating FMEP" DstPort 6 } } } } } Line { SrcBlock "half S (stroke)" SrcPort 1 Points [10, 0] Branch { Points [60, 0; 0, 10] DstBlock "x" DstPort 1 } Branch { Points [0, 465] DstBlock "x2" DstPort 2 } } Line { SrcBlock "crank pin dia" SrcPort 1 Points [15, 0; 0, 15] Branch { DstBlock "x3" DstPort 2 } Branch { Points [0, 25] Branch { DstBlock "x4" DstPort 1 } Branch { Points [0, 60] Branch { DstBlock "x5" DstPort 1 } Branch { Points [0, 45] DstBlock "x6" DstPort 1 } } } } Line { SrcBlock "crank pin length" SrcPort 1 Points [15, 0; 0, 5] DstBlock "x4" DstPort 2 } Line { SrcBlock "Cam dia" SrcPort 1 Points [0, -10] DstBlock "x5" DstPort 2 } Line { SrcBlock "Cam length" SrcPort 1 Points [0, -10] DstBlock "x6" DstPort 2 } Line { SrcBlock "Calc Aux FMEP (Pa)" SrcPort 1 Points [45, 0; 0, -90] DstBlock "Calc Total FMEP" DstPort 4 } Line { SrcBlock "Constant" SrcPort 1 DstBlock "Clac T(friction)" DstPort 2 } Line { SrcBlock "Clac T(friction)" SrcPort 1 Points [0, -30] DstBlock "Calc T(friction)" DstPort 1 } Line { SrcBlock "Mux" SrcPort 1 DstBlock "T1" DstPort 1 } Line { SrcBlock "Mux1" SrcPort 1 DstBlock "T2" DstPort 1 } Line { SrcBlock "Mux2" SrcPort 1 DstBlock "T3" DstPort 1 } } } Block { BlockType Terminator Name "Terminator1" Position [250, 85, 270, 105] } Block { BlockType Outport Name "Torque Friction" Position [530, 303, 560, 317] IconDisplay "Port number" } Line { SrcBlock "Demux1" SrcPort 1 DstBlock "Friction" DstPort 2 } Line { SrcBlock "Demux1" SrcPort 2 Points [105, 0; 0, 5] DstBlock "Friction" DstPort 3 } Line { SrcBlock "Demux1" SrcPort 3 Points [105, 0; 0, 10] DstBlock "Friction" DstPort 4 } Line { SrcBlock "Demux1" SrcPort 4 Points [105, 0; 0, 15] DstBlock "Friction" DstPort 5 } Line { SrcBlock "Demux1" SrcPort 5 Points [95, 0; 0, 20] DstBlock "Friction" DstPort 6 } Line { SrcBlock "Demux1" SrcPort 6 Points [215, 0] DstBlock "Friction" DstPort 7 } Line { SrcBlock "Demux1" SrcPort 7 Points [105, 0; 0, 30] DstBlock "Friction" DstPort 8 } Line { SrcBlock "Demux1" SrcPort 8 Points [95, 0; 0, 35] DstBlock "Friction" DstPort 9 } Line { SrcBlock "Demux1" SrcPort 9 Points [85, 0; 0, 40] DstBlock "Friction" DstPort 10 } Line { SrcBlock "Demux1" SrcPort 10 Points [75, 0; 0, 45] DstBlock "Friction" DstPort 11 } Line { SrcBlock "Demux3" SrcPort 1 Points [60, 0; 0, 65] DstBlock "Friction" DstPort 1 } Line { SrcBlock "Demux3" SrcPort 2 DstBlock "Terminator1" DstPort 1 } Line { SrcBlock "Crank Mux" SrcPort 1 DstBlock "Demux3" DstPort 1 } Line { SrcBlock "F Mux" SrcPort 1 DstBlock "Demux1" DstPort 1 } Line { SrcBlock "Friction" SrcPort 1 DstBlock "Torque Friction" DstPort 1 } Line { SrcBlock "Cyl Vol" SrcPort 1 DstBlock "Friction" DstPort 12 } } } Block { BlockType SubSystem Name "Geometry" Ports [0, 2] Position [435, 304, 495, 486] MinAlgLoopOccurrences off PropExecContextOutsideSubsystem off RTWSystemCode "Auto" FunctionWithSeparateData off Opaque off RequestExecContextInheritance off MaskHideContents off System { Name "Geometry" Location [158, 82, 684, 831] Open off ModelBrowserVisibility off ModelBrowserWidth 200 ScreenColor "white" PaperOrientation "landscape" PaperPositionMode "auto" PaperType "usletter" PaperUnits "inches" TiledPaperMargins [0.500000, 0.500000, 0.500000, 0.500000] TiledPageScale 1 ShowPageBoundaries off ZoomFactor "100" Block { BlockType Constant Name "# cylinders" Position [45, 466, 65, 484] OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "# main bearings" Position [40, 501, 70, 519] Value "2" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Atm Pressure(Pa)1" Position [25, 535, 90, 555] Value "100000" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Compression Ratio x:1" Position [40, 195, 105, 225] Value "11" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Connecting Rod Length (m)" Position [40, 81, 105, 99] Value ".11" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Crank Case Pressure (Pa)" Position [35, 160, 100, 180] Value "100000" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Crank offeset (half stroke) (m)" Position [35, 42, 95, 58] Value "0.0415" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Fuel 1 ocatane 0 H1" Position [40, 241, 85, 259] OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Mux Name "Mux" Ports [8, 1] Position [300, 20, 315, 360] ShowName off Inputs "8" DisplayOption "bar" } Block { BlockType Mux Name "Mux1" Ports [10, 1] Position [410, 318, 445, 667] ShowName off Inputs "10" DisplayOption "bar" } Block { BlockType Constant Name "Piston Diameter (m)" Position [40, 122, 100, 138] Value "0.083" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Valve Dia (m)" Position [40, 315, 70, 345] Value "0.02" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Valve Lift (m)" Position [40, 280, 80, 300] Value "0.012" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "cam bearings" Position [45, 604, 65, 626] Value "2" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "cam shafts" Position [45, 569, 65, 591] Value "2" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "valves" Position [45, 639, 65, 661] Value "4" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Outport Name "Geo Mux" Position [340, 188, 370, 202] IconDisplay "Port number" } Block { BlockType Outport Name "F Mux" Position [470, 488, 500, 502] Port "2" IconDisplay "Port number" } Line { SrcBlock "Piston Diameter (m)" SrcPort 1 Points [30, 0] Branch { Labels [0, 0] DstBlock "Mux" DstPort 3 } Branch { Points [0, 205] DstBlock "Mux1" DstPort 1 } } Line { SrcBlock "Compression Ratio x:1" SrcPort 1 Points [135, 0] Branch { DstBlock "Mux" DstPort 5 } Branch { Points [0, 195] DstBlock "Mux1" DstPort 3 } } Line { Labels [0, 0] SrcBlock "Crank offeset (half stroke) (m)" SrcPort 1 Points [25, 0] Branch { Labels [0, 0] DstBlock "Mux" DstPort 1 } Branch { Points [0, 320] DstBlock "Mux1" DstPort 2 } } Line { Labels [0, 0] SrcBlock "Connecting Rod Length (m)" SrcPort 1 DstBlock "Mux" DstPort 2 } Line { SrcBlock "Crank Case Pressure (Pa)" SrcPort 1 DstBlock "Mux" DstPort 4 } Line { SrcBlock "Fuel 1 ocatane 0 H1" SrcPort 1 DstBlock "Mux" DstPort 6 } Line { SrcBlock "Valve Lift (m)" SrcPort 1 Points [145, 0] Branch { DstBlock "Mux" DstPort 7 } Branch { Points [0, 150] DstBlock "Mux1" DstPort 4 } } Line { SrcBlock "Valve Dia (m)" SrcPort 1 DstBlock "Mux" DstPort 8 } Line { SrcBlock "# cylinders" SrcPort 1 DstBlock "Mux1" DstPort 5 } Line { SrcBlock "Atm Pressure(Pa)1" SrcPort 1 DstBlock "Mux1" DstPort 7 } Line { SrcBlock "# main bearings" SrcPort 1 DstBlock "Mux1" DstPort 6 } Line { SrcBlock "cam shafts" SrcPort 1 DstBlock "Mux1" DstPort 8 } Line { SrcBlock "cam bearings" SrcPort 1 DstBlock "Mux1" DstPort 9 } Line { SrcBlock "valves" SrcPort 1 DstBlock "Mux1" DstPort 10 } Line { SrcBlock "Mux" SrcPort 1 Points [0, 5] DstBlock "Geo Mux" DstPort 1 } Line { SrcBlock "Mux1" SrcPort 1 DstBlock "F Mux" DstPort 1 } } } Block { BlockType Constant Name "Inertia" Position [50, 75, 80, 105] OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Constant Name "Initial rad/s" Position [25, 195, 120, 225] Value "523" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Mux Name "Mux2" Ports [2, 1] Position [385, 99, 400, 166] ShowName off Inputs "2" DisplayOption "bar" } Block { BlockType Constant Name "Spark advance" Position [535, 340, 585, 380] Value "17" OutDataType "sfix(16)" OutScaling "2^0" } Block { BlockType Sum Name "Sum1" Ports [2, 1] Position [175, 140, 195, 160] ShowName off IconShape "round" Inputs "|++" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sum Name "Sum2" Ports [2, 1] Position [985, 290, 1005, 310] ShowName off IconShape "round" Inputs "|+-" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Sum Name "Sum3" Ports [2, 1] Position [125, 140, 145, 160] ShowName off IconShape "round" Inputs "|++" InputSameDT off OutDataTypeMode "Inherit via internal rule" OutDataType "sfix(16)" OutScaling "2^0" OutDataTypeStr "Inherit: Inherit via internal rule" SaturateOnIntegerOverflow off } Block { BlockType Terminator Name "Terminator2" Position [435, 70, 455, 90] } Block { BlockType Constant Name "Torque N/M" Position [45, 135, 75, 165] Value "0" OutDataType "sfix(16)" OutScaling "2^0" } Line { SrcBlock "Inertia" SrcPort 1 DstBlock "Crank Position" DstPort 1 } Line { SrcBlock "Crank Position" SrcPort 1 DstBlock "Terminator2" DstPort 1 } Line { SrcBlock "Crank Position" SrcPort 2 DstBlock "Mux2" DstPort 1 } Line { SrcBlock "Initial rad/s" SrcPort 1 DstBlock "Crank Position" DstPort 3 } Line { SrcBlock "Sum1" SrcPort 1 DstBlock "Crank Position" DstPort 2 } Line { SrcBlock "Cylinder" SrcPort 2 DstBlock "Friction Model" DstPort 1 } Line { Labels [0, 0] SrcBlock "Crank Position" SrcPort 3 DstBlock "Mux2" DstPort 2 } Line { SrcBlock "Crank Position" SrcPort 5 DstBlock "Display" DstPort 1 } Line { SrcBlock "Geometry" SrcPort 1 Points [0, -25] DstBlock "Cylinder" DstPort 2 } Line { SrcBlock "Geometry" SrcPort 2 DstBlock "Friction Model" DstPort 3 } Line { SrcBlock "Mux2" SrcPort 1 Points [20, 0; 0, 165] Branch { Points [175, 0] DstBlock "Cylinder" DstPort 1 } Branch { Points [0, 95] DstBlock "Friction Model" DstPort 2 } } Line { SrcBlock "Friction Model" SrcPort 1 Points [35, 0] DstBlock "Sum2" DstPort 2 } Line { SrcBlock "Cylinder" SrcPort 1 DstBlock "Sum2" DstPort 1 } Line { SrcBlock "Sum2" SrcPort 1 Points [60, 0; 0, 245; -885, 0] DstBlock "Sum1" DstPort 2 } Line { SrcBlock "Sum3" SrcPort 1 DstBlock "Sum1" DstPort 1 } Line { SrcBlock "Torque N/M" SrcPort 1 DstBlock "Sum3" DstPort 1 } Line { SrcBlock "Spark advance" SrcPort 1 DstBlock "Cylinder" DstPort 3 } } } # Finite State Machines # # Stateflow Version 7.1 (R2008a) dated Sep 3 2008, 03:53:58 # # Stateflow { machine { id 1 name "MarkIVRevJt" created "03-Mar-2009 10:50:39" isLibrary 0 firstTarget 86 sfVersion 71014000.000007 } chart { id 2 name "Cylinder/Subsystem/Combustion/H Chem1/Embedded\nMATLAB (Reaction Balance)" windowPosition [261.5 364.313 200.25 189.75] viewLimits [0 156.75 0 153.75] screen [1 1 1440 900 1.333333333333333] treeNode [0 3 0 0] firstTransition 5 firstJunction 4 viewObj 2 machine 1 ssIdHighWaterMark 40 decomposition CLUSTER_CHART type EML_CHART firstData 6 chartFileNumber 1 disableImplicitCasting 1 eml { name "fcn" } } state { id 3 labelString "eML_blk_kernel()" position [18 64.5 118 66] fontSize 12 chart 2 treeNode [2 0 0 0] superState SUBCHART subviewer 2 ssIdNumber 1 type FUNC_STATE decomposition CLUSTER_STATE eml { isEML 1 script "function [Xh2, Xo2, Xn2r, H2m, O2m, N2m, Xh2o, Xn2p, H2Om] = fcn ()\n\n% a*H2 + Air*b*(O2 + 3.76" "*N2)--> c*H2O + d*O2 + e*N2\n\n% Hydrogen (H)\n% 2*a - 2*c = 0\n%\n% Oxygen (O)\n% 2*Air*b - c = 0\n%\n% Nitroge" "n (N)\n% 3.76*2*Air*b - e = 0\n%\n% Auxiliary equation\n% a = 1\n\nH2m=2*1.00794;\nO2m=2*15.9994;\nN2m=2*14.0067" ";\nH2Om = H2m + O2m/2;\n\nA=[2 0 -2 0\n 0 2 -1 0\n 0 7.52 0 -2\n 1 0 0 0 ];\n\nb=[0\n 0\n 0\n " "1];\n\nx = A\\b;\n \nH2=x(1);\nO2=x(2);\nH2O=x(3);\nN2=x(4);\n\n% % Adjust for % Air\n% O2r = O2*Air;\n% O2p = " "(O2r*2-H2O)/2;\n% N2p = N2*Air;\n\nNrtot = H2 + O2*(1+3.76);\nXh2 = H2/Nrtot;\nXo2 = O2/Nrtot;\nXn2r = O2*(3.76)" "/Nrtot;\n\nNptot= H2O + N2;\nXh2o = H2O/Nptot;\nXn2p = N2/Nptot;\n\n\n\n\n\n" editorLayout "100 M4x1[262 19 774 693]" inferBkpts [109] } } junction { id 4 position [23.5747 49.5747 7] chart 2 linkNode [2 0 0] subviewer 2 ssIdNumber 3 type CONNECTIVE_JUNCTION } transition { id 5 labelString "{eML_blk_kernel();}" labelPosition [32.125 19.875 102.544 14.964] fontSize 12 src { intersection [0 0 1 0 23.5747 14.625 0 0] } dst { id 4 intersection [7 0 -1 -1 23.5747 42.5747 0 0] } midPoint [23.5747 24.9468] chart 2 linkNode [2 0 0] dataLimits [23.575 23.575 14.625 34.575] subviewer 2 drawStyle SMART executionOrder 1 ssIdNumber 2 } data { id 6 ssIdNumber 15 name "Xh2" linkNode [2 0 7] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 7 ssIdNumber 32 name "Xo2" linkNode [2 6 8] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 8 ssIdNumber 36 name "Xn2r" linkNode [2 7 9] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 9 ssIdNumber 16 name "H2m" linkNode [2 8 10] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 10 ssIdNumber 31 name "O2m" linkNode [2 9 11] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 11 ssIdNumber 18 name "N2m" linkNode [2 10 12] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 12 ssIdNumber 35 name "Xh2o" linkNode [2 11 13] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 13 ssIdNumber 33 name "Xn2p" linkNode [2 12 14] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 14 ssIdNumber 20 name "H2Om" linkNode [2 13 0] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } instance { id 15 name "Cylinder/Subsystem/Combustion/H Chem1/Embedded\nMATLAB (Reaction Balance)" machine 1 chart 2 } chart { id 16 name "Cylinder/Subsystem/Combustion/H Chem1/Embedded\nMATLAB Post Combustion" windowPosition [287.75 353.063 200.25 189.75] viewLimits [0 156.75 0 153.75] screen [1 1 1440 900 1.333333333333333] treeNode [0 17 0 0] firstTransition 19 firstJunction 18 viewObj 16 machine 1 ssIdHighWaterMark 24 decomposition CLUSTER_CHART type EML_CHART firstData 20 chartFileNumber 2 disableImplicitCasting 1 eml { name "fcn" } } state { id 17 labelString "eML_blk_kernel()" position [18 64.5 118 66] fontSize 12 chart 16 treeNode [16 0 0 0] superState SUBCHART subviewer 16 ssIdNumber 1 type FUNC_STATE decomposition CLUSTER_STATE eml { isEML 1 script "function Tp = fcn(U, R, N2m, Xh2o, Xn2p, H2Om)\n\nn=50;\nEa=1e-8; % Error (%)\nTin = 300;\n\n% E" "nthalpy K (298.15) (kJ/kmol)\nHn2 = 8670.104;\nHh2o = 9904.092;\n \nwhile n > 1 \n if Tin <= 1000 \n " " % N2 (200 - 1000)\n a1n2 = 2.210371497E+04;\n a2n2 = -3.818461820E+02;\n a3n2 = 6.082738360E+00;\n " " a4n2 = -8.530914410E-03;\n a5n2 = 1.384646189E-05;\n a6n2 = -9.625793620E-09;\n a7n2 = 2.519705809E-1" "2;\n b1n2 = 7.108460860E+02;\n \n % H2O (200 - 1000)\n a1h2o = -3.947960830E+04;\n a2h2o = 5.75" "5731020E+02;\n a3h2o = 9.317826530E-01;\n a4h2o = 7.222712860E-03;\n a5h2o = -7.342557370E-06;\n a6h" "2o = 4.955043490E-09;\n a7h2o = -1.336933246E-12;\n b1h2o = -3.303974310E+04; \n else \n % N2" " (1000 - 6000)\n a1n2 = 5.877124060E+05;\n a2n2 = -2.239249073E+03;\n a3n2 = 6.066949220E+00;\n a4n2" " = -6.139685500E-04;\n a5n2 = 1.491806679E-07;\n a6n2 = -1.923105485E-11;\n a7n2 = 1.061954386E-15;\n " " b1n2 = 1.283210415E+04; \n\n %H2O (1000 - 6000) \n a1h2o = 1.034972096E+06;\n a2h2o = -2.412698562E+0" "3;\n a3h2o = 4.646110780E+00;\n a4h2o = 2.291998307E-03;\n a5h2o = -6.836830480E-07;\n a6h2o = 9.426" "468930E-11;\n a7h2o = -4.822380530E-15;\n b1h2o = -1.384286509E+04; \n end \n \n hh2o = (-(a" "1h2o)/Tin + (a2h2o)*log(Tin) + (a3h2o)*Tin + (a4h2o)*Tin^2/2 + (a5h2o)*Tin^3/3 + (a6h2o)*Tin^4/4 + (a7h2o)*Tin^5" "/5 + (b1h2o))*R; \n hn2 = (-(a1n2)/Tin + (a2n2)*log(Tin) + (a3n2)*Tin + (a4n2)*Tin^2/2 + (a5n2)*Tin^3/3 + (" "a6n2)*Tin^4/4 + (a7n2)*Tin^5/5 + (b1n2))*R;\n \n uh2o = (hh2o - (-241826.0) + Hh2o - R*Tin)/H2Om;\n un" "2 = (hn2 + Hn2 - R*Tin)/N2m;\n \n Utot = (Xh2o*uh2o + Xn2p*un2)*1000; \n \n Dh2o = -(R-R*((a1h2o)/" "Tin^2 + (a2h2o)/Tin + (a3h2o) + (a4h2o)*Tin + (a5h2o)*Tin^2 + (a6h2o)*Tin^3 + (a7h2o)*Tin^4))/H2Om;\n % Do2 " "= -(R-R*((a1o2)/Tin^2 + (a2o2)/Tin + (a3o2) + (a4o2)*Tin + (a5o2)*Tin^2 + (a6o2)*Tin^3 + (a7o2)*Tin^4))/O2m; \n" " Dn2 = -(R-R*((a1n2)/Tin^2 + (a2n2)/Tin + (a3n2) + (a4n2)*Tin + (a5n2)*Tin^2 + (a6n2)*Tin^3 + (a7n2)*Tin^4))/" "N2m;\n \n Dtot = (Xh2o*Dh2o + Xn2p*Dn2)*1000;\n\n To = Tin - ((Utot-U)/Dtot); \n\n E = sqrt(((To - Ti" "n)/To)^2);\n \n if E < Ea\n n = 0;\n end\n\n Tin=To;\n n=n-1; \nend\nTp = Tin;\n\n" editorLayout "100 M4x1[135 2 1041 786]" inferBkpts [109] } } junction { id 18 position [23.5747 49.5747 7] chart 16 linkNode [16 0 0] subviewer 16 ssIdNumber 3 type CONNECTIVE_JUNCTION } transition { id 19 labelString "{eML_blk_kernel();}" labelPosition [32.125 19.875 102.544 14.964] fontSize 12 src { intersection [0 0 1 0 23.5747 14.625 0 0] } dst { id 18 intersection [7 0 -1 -1 23.5747 42.5747 0 0] } midPoint [23.5747 24.9468] chart 16 linkNode [16 0 0] dataLimits [23.575 23.575 14.625 34.575] subviewer 16 drawStyle SMART executionOrder 1 ssIdNumber 2 } data { id 20 ssIdNumber 19 name "U" linkNode [16 0 21] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 21 ssIdNumber 5 name "Tp" linkNode [16 20 22] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 22 ssIdNumber 14 name "R" linkNode [16 21 23] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 23 ssIdNumber 21 name "N2m" linkNode [16 22 24] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 24 ssIdNumber 16 name "Xh2o" linkNode [16 23 25] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 25 ssIdNumber 17 name "Xn2p" linkNode [16 24 26] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 26 ssIdNumber 23 name "H2Om" linkNode [16 25 0] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } instance { id 27 name "Cylinder/Subsystem/Combustion/H Chem1/Embedded\nMATLAB Post Combustion" machine 1 chart 16 } chart { id 28 name "Cylinder/Subsystem/Combustion/H Chem1/Embedded\nMATLAB Pre Combustion" windowPosition [280.25 353.063 200.25 189.75] viewLimits [0 156.75 0 153.75] screen [1 1 1440 900 1.333333333333333] treeNode [0 29 0 0] firstTransition 31 firstJunction 30 viewObj 28 machine 1 ssIdHighWaterMark 23 decomposition CLUSTER_CHART type EML_CHART firstData 32 chartFileNumber 3 disableImplicitCasting 1 eml { name "fcn" } } state { id 29 labelString "eML_blk_kernel()" position [18 64.5 118 66] fontSize 12 chart 28 treeNode [28 0 0 0] superState SUBCHART subviewer 28 ssIdNumber 1 type FUNC_STATE decomposition CLUSTER_STATE eml { isEML 1 script "function Tr = fcn(U, R, Xh2, Xo2, Xn2r, H2m, O2m, N2m)\n\nn=50;\nEa=1e-6; % Error (%)\nTin = 30;" "\n\n% Enthalpy at K=298.15 (kJ/kmol)\nHh2 = 8468.102;\nHo2 = 8680.104;\nHn2 = 8670.104;\n\n\nwhile n > 1 \n " " if Tin <= 1000 \n % O2 (200 - 1000)\n a1o2 = -3.425563420E+04;\n a2o2 = 4.847000970E+02;\n a3o" "2 = 1.119010961E+00;\n a4o2 = 4.293889240E-03;\n a5o2 = -6.836300520E-07;\n a6o2 = -2.023372700E-09;\n " " a7o2 = 1.039040018E-12;\n b1o2 = -3.391454870E+03;\n \n % N2 (200 - 1000)\n a1n2 = 2.210371497E+04" ";\n a2n2 = -3.818461820E+02;\n a3n2 = 6.082738360E+00;\n a4n2 = -8.530914410E-03;\n a5n2 = 1.3846461" "89E-05;\n a6n2 = -9.625793620E-09;\n a7n2 = 2.519705809E-12;\n b1n2 = 7.108460860E+02;\n " "\n % H2 (200 - 1000)\n a1h2 = 4.078323210E+04;\n a2h2 = -8.009186040E+02;\n a3h2 = 8.214702010E+00;\n" " a4h2 = -1.269714457E-02;\n a5h2 = 1.753605076E-05;\n a6h2 = -1.202860270E-08;\n a7h2 = 3.368093490E" "-12;\n b1h2 = 2.682484665E+03; \n else \n % O2 (1000 - 6000)\n a1o2 = -1.037939022E+06;\n " "a2o2 = 2.344830282E+03;\n a3o2 = 1.819732036E+00;\n a4o2 = 1.267847582E-03;\n a5o2 = -2.188067988E-07;" "\n a6o2 = 2.053719572E-11;\n a7o2 = -8.193467050E-16;\n b1o2 = -1.689010929E+04;\n \n % N2 (1000 " "- 6000)\n a1n2 = 5.877124060E+05;\n a2n2 = -2.239249073E+03;\n a3n2 = 6.066949220E+00;\n a4n2 = -6.1" "39685500E-04;\n a5n2 = 1.491806679E-07;\n a6n2 = -1.923105485E-11;\n a7n2 = 1.061954386E-15;\n b1n2 " "= 1.283210415E+04;\n \n %H2 (1000 - 6000) \n a1h2 = 5.608128010E+05;\n a2h2 = -8.371504740E+02;\n " " a3h2 = 2.975364532E+00;\n a4h2 = 1.252249124E-03;\n a5h2 = -3.740716190E-07;\n a6h2 = 5.936625200E-11;" "\n a7h2 = -3.606994100E-15;\n b1h2 = 5.339824410E+03; \n\n \n end\n \n hh2 = (-(a1h2)/Tin + (a2" "h2)*log(Tin) + (a3h2)*Tin + (a4h2)*Tin^2/2 + (a5h2)*Tin^3/3 + (a6h2)*Tin^4/4 + (a7h2)*Tin^5/5 + (b1h2))*R;\n " "ho2 = (-(a1o2)/Tin + (a2o2)*log(Tin) + (a3o2)*Tin + (a4o2)*Tin^2/2 + (a5o2)*Tin^3/3 + (a6o2)*Tin^4/4 + (a7o2)*Ti" "n^5/5 + (b1o2))*R; \n hn2 = (-(a1n2)/Tin + (a2n2)*log(Tin) + (a3n2)*Tin + (a4n2)*Tin^2/2 + (a5n2)*Tin^3/3 + " "(a6n2)*Tin^4/4 + (a7n2)*Tin^5/5 + (b1n2))*R;\n \n uh2 = (hh2 + Hh2 - R*Tin)/H2m;\n uo2 = (ho2 + Ho2 - " "R*Tin)/O2m;\n un2 = (hn2 + Hn2 - R*Tin)/N2m;\n \n Utot = (Xh2*uh2 + Xo2*uo2 + Xn2r*un2)*1000;\n \n " " \n% Dh2 = ((-(a1h2)/Tin^2 + (a2h2)/Tin + (a3h2) + (a4h2)*Tin + (a5h2)*Tin^2 + (a6h2)*Tin^3 + (a7h2)*Tin^4) " "- 1)*R/H2m;\n% Do2 = ((-(a1o2)/Tin^2 + (a2o2)/Tin + (a3o2) + (a4o2)*Tin + (a5o2)*Tin^2 + (a6o2)*Tin^3 + (a7o" "2)*Tin^4) - 1)*R/O2m; \n% Dn2 = ((-(a1n2)/Tin^2 + (a2n2)/Tin + (a3n2) + (a4n2)*Tin + (a5n2)*Tin^2 + (a6n2)*" "Tin^3 + (a7n2)*Tin^4) - 1)*R/N2m; \n\n Dh2 = -(R-R*((a1h2)/Tin^2 + (a2h2)/Tin + (a3h2) + (a4h2)*Tin + (a5h2)" "*Tin^2 + (a6h2)*Tin^3 + (a7h2)*Tin^4))/H2m;\n Do2 = -(R-R*((a1o2)/Tin^2 + (a2o2)/Tin + (a3o2) + (a4o2)*Tin + " "(a5o2)*Tin^2 + (a6o2)*Tin^3 + (a7o2)*Tin^4))/O2m; \n Dn2 = -(R-R*((a1n2)/Tin^2 + (a2n2)/Tin + (a3n2) + (a4n2" ")*Tin + (a5n2)*Tin^2 + (a6n2)*Tin^3 + (a7n2)*Tin^4))/N2m;\n \n Dtot = (Xh2*Dh2 + Xo2*Do2 + Xn2r*Dn2)*1000;\n\n" " To = Tin - ((Utot-U)/Dtot); \n\n E = sqrt(((To - Tin)/To)^2);\n \n if E < Ea\n n = 0;\n e" "nd\n \n Tin = To;\n \n\n% if Utot>U\n% n=0;\n% end\n% Tin=Tin +1;\n n=n-1; \n \nend\nTr =" " Tin;\n\n\n\n\n" editorLayout "100 M4x1[197 21 966 738]" inferBkpts [109] } } junction { id 30 position [23.5747 49.5747 7] chart 28 linkNode [28 0 0] subviewer 28 ssIdNumber 3 type CONNECTIVE_JUNCTION } transition { id 31 labelString "{eML_blk_kernel();}" labelPosition [32.125 19.875 102.544 14.964] fontSize 12 src { intersection [0 0 1 0 23.5747 14.625 0 0] } dst { id 30 intersection [7 0 -1 -1 23.5747 42.5747 0 0] } midPoint [23.5747 24.9468] chart 28 linkNode [28 0 0] dataLimits [23.575 23.575 14.625 34.575] subviewer 28 drawStyle SMART executionOrder 1 ssIdNumber 2 } data { id 32 ssIdNumber 4 name "U" linkNode [28 0 33] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE } complexity SF_COMPLEX_INHERITED } dataType "Inherit: Same as Simulink" } data { id 33 ssIdNumber 5 name "Tr" linkNode [28 32 34] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 34 ssIdNumber 14 name "R" linkNode [28 33 35] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 35 ssIdNumber 15 name "Xh2" linkNode [28 34 36] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 36 ssIdNumber 16 name "Xo2" linkNode [28 35 37] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 37 ssIdNumber 17 name "Xn2r" linkNode [28 36 38] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 38 ssIdNumber 20 name "H2m" linkNode [28 37 39] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 39 ssIdNumber 21 name "O2m" linkNode [28 38 40] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 40 ssIdNumber 22 name "N2m" linkNode [28 39 0] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } instance { id 41 name "Cylinder/Subsystem/Combustion/H Chem1/Embedded\nMATLAB Pre Combustion" machine 1 chart 28 } chart { id 42 name "Cylinder/Subsystem/Combustion/CxHy Chem/Embedded\nMATLAB (Reaction Balance)" windowPosition [318.667 279 200.25 189.75] viewLimits [0 156.75 0 153.75] screen [1 1 1440 900 1.333333333333333] treeNode [0 43 0 0] firstTransition 45 firstJunction 44 viewObj 42 machine 1 ssIdHighWaterMark 39 decomposition CLUSTER_CHART type EML_CHART firstData 46 chartFileNumber 5 disableImplicitCasting 1 eml { name "fcn" } } state { id 43 labelString "eML_blk_kernel()" position [18 64.5 118 66] fontSize 12 chart 42 treeNode [42 0 0 0] superState SUBCHART subviewer 42 ssIdNumber 1 type FUNC_STATE decomposition CLUSTER_STATE eml { isEML 1 script "function [Xch, Xo2, Xn2r, CHm, O2m, N2m, Xco2, Xh2o, Xn2p, CO2m, H2Om] = fcn\n\n% a*C8H18 + b*(O" "2 + 3.76*N2)--> c*CO2 + d*H2O + e*N2\n\n% Carbon (C)\n% 8*a - c = 0\n%\n% Hydrogen (H)\n% 18*a - 2*d = 0\n%\n% O" "xygen (O)\n% 2*b - 2*c -d = 0\n%\n% Nitrogen (N)\n% 3.76*2*b - e = 0\n%\n% Auxiliary equation\n% a = 1\n\nC = 8;" "\nH = 18;\n\nCm=12.0107;\nHm=1.00794;\nO2m=2*15.9994;\nN2m=2*14.0067;\nCO2m = Cm+O2m;\nH2Om = Hm*2+O2m/2;\nCHm =" " Cm*C + Hm*H;\n\nA=[C 0 -1 0 0\n H 0 0 -2 0\n 0 2 -2 -1 0\n 0 7.52 0 0 -2\n 1 0 0 0 0];\n\nb=[0\n " " 0\n 0\n 0\n 1];\n\nx = A\\b;\n \nCH=x(1);\nO2=x(2);\nCO2=x(3);\nH2O=x(4);\nN2=x(5);\n\nNrtot= CH + O2" "*(1+3.76);\nXch = CH/Nrtot;\nXo2 = O2/Nrtot;\nXn2r = O2*(3.76)/Nrtot;\n\nMWr = Xch*CHm + Xo2*O2m + Xn2r*N2m;\n\n" "Nptot= CO2 + H2O + N2;\nXco2 = CO2/Nptot;\nXh2o = H2O/Nptot;\nXn2p = N2/Nptot;\n\n% MWp = Xco2*CO2m + Xh2o*H2Om " "+ Xn2p*N2m;\n\n\n\n\n" editorLayout "100 M4x1[135 2 1041 786]" inferBkpts [109] } } junction { id 44 position [23.5747 49.5747 7] chart 42 linkNode [42 0 0] subviewer 42 ssIdNumber 3 type CONNECTIVE_JUNCTION } transition { id 45 labelString "{eML_blk_kernel();}" labelPosition [32.125 19.875 102.544 14.964] fontSize 12 src { intersection [0 0 1 0 23.5747 14.625 0 0] } dst { id 44 intersection [7 0 -1 -1 23.5747 42.5747 0 0] } midPoint [23.5747 24.9468] chart 42 linkNode [42 0 0] dataLimits [23.575 23.575 14.625 34.575] subviewer 42 drawStyle SMART executionOrder 1 ssIdNumber 2 } data { id 46 ssIdNumber 15 name "Xch" linkNode [42 0 47] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 47 ssIdNumber 32 name "Xo2" linkNode [42 46 48] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 48 ssIdNumber 36 name "Xn2r" linkNode [42 47 49] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 49 ssIdNumber 16 name "CHm" linkNode [42 48 50] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 50 ssIdNumber 31 name "O2m" linkNode [42 49 51] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 51 ssIdNumber 18 name "N2m" linkNode [42 50 52] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 52 ssIdNumber 34 name "Xco2" linkNode [42 51 53] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 53 ssIdNumber 35 name "Xh2o" linkNode [42 52 54] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 54 ssIdNumber 33 name "Xn2p" linkNode [42 53 55] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 55 ssIdNumber 19 name "CO2m" linkNode [42 54 56] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 56 ssIdNumber 20 name "H2Om" linkNode [42 55 0] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } instance { id 57 name "Cylinder/Subsystem/Combustion/CxHy Chem/Embedded\nMATLAB (Reaction Balance)" machine 1 chart 42 } chart { id 58 name "Cylinder/Subsystem/Combustion/CxHy Chem/Embedded\nMATLAB Post Combustion" windowPosition [353.667 264 200.25 189.75] viewLimits [0 156.75 0 153.75] screen [1 1 1440 900 1.333333333333333] treeNode [0 59 0 0] firstTransition 61 firstJunction 60 viewObj 58 machine 1 ssIdHighWaterMark 24 decomposition CLUSTER_CHART type EML_CHART firstData 62 chartFileNumber 7 disableImplicitCasting 1 eml { name "fcn" } } state { id 59 labelString "eML_blk_kernel()" position [18 64.5 118 66] fontSize 12 chart 58 treeNode [58 0 0 0] superState SUBCHART subviewer 58 ssIdNumber 1 type FUNC_STATE decomposition CLUSTER_STATE eml { isEML 1 script "function Tp = fcn(U, R, N2m, Xco2, Xh2o, Xn2p, CO2m, H2Om)\n\nn=50;\nEa=1e-8; % Error (%)\nTin =" " 300;\n\n% Enthalpy at K=0 (kJ/kmol)\nHco2 = 9365.469;\nHn2 = 8670.104;\nHh2o = 9904.092;\n \nwhile n > 1 \n" " if Tin <= 1000 \n % CO2 (200 - 1000)\n a1co2 = 4.943650540E+04;\n a2co2 = -6.264116010E+02;\n " " a3co2 = 5.301725240E+00;\n a4co2 = 2.503813816E-03;\n a5co2 = -2.127308728E-07;\n a6co2 = -7.68998878" "0E-10;\n a7co2 = 2.849677801E-13;\n b1co2 = -4.528198460E+04;\n \n % N2 (200 - 1000)\n a1n2 = 2.21" "0371497E+04;\n a2n2 = -3.818461820E+02;\n a3n2 = 6.082738360E+00;\n a4n2 = -8.530914410E-03;\n a5n2 " "= 1.384646189E-05;\n a6n2 = -9.625793620E-09;\n a7n2 = 2.519705809E-12;\n b1n2 = 7.108460860E+02;\n " " \n % H2O (200 - 1000)\n a1h2o = -3.947960830E+04;\n a2h2o = 5.755731020E+02;\n a3h2o = 9.317826530" "E-01;\n a4h2o = 7.222712860E-03;\n a5h2o = -7.342557370E-06;\n a6h2o = 4.955043490E-09;\n a7h2o = -1" ".336933246E-12;\n b1h2o = -3.303974310E+04; \n else \n % CO2 (1000 - 6000)\n a1co2 = 1.176962" "419E+05;\n a2co2 = -1.788791477E+03;\n a3co2 = 8.291523190E+00;\n a4co2 = -9.223156780E-05;\n a5co2" " = 4.863676880E-09;\n a6co2 = -1.891053312E-12;\n a7co2 = 6.330036590E-16;\n b1co2 = -3.908350590E+04;\n" " \n % N2 (1000 - 6000)\n a1n2 = 5.877124060E+05;\n a2n2 = -2.239249073E+03;\n a3n2 = 6.066949220E" "+00;\n a4n2 = -6.139685500E-04;\n a5n2 = 1.491806679E-07;\n a6n2 = -1.923105485E-11;\n a7n2 = 1.0619" "54386E-15;\n b1n2 = 1.283210415E+04; \n\n %H2O (1000 - 6000) \n a1h2o = 1.034972096E+06;\n a2h2o = -" "2.412698562E+03;\n a3h2o = 4.646110780E+00;\n a4h2o = 2.291998307E-03;\n a5h2o = -6.836830480E-07;\n " " a6h2o = 9.426468930E-11;\n a7h2o = -4.822380530E-15;\n b1h2o = -1.384286509E+04; \n end \n \n " " hco2 = (-(a1co2)/Tin + (a2co2)*log(Tin) + (a3co2)*Tin + (a4co2)*Tin^2/2 + (a5co2)*Tin^3/3 + (a6co2)*Tin^4/4 +" " (a7co2)*Tin^5/5 + (b1co2))*R;\n hh2o = (-(a1h2o)/Tin + (a2h2o)*log(Tin) + (a3h2o)*Tin + (a4h2o)*Tin^2/2 + (a" "5h2o)*Tin^3/3 + (a6h2o)*Tin^4/4 + (a7h2o)*Tin^5/5 + (b1h2o))*R; \n hn2 = (-(a1n2)/Tin + (a2n2)*log(Tin) + (" "a3n2)*Tin + (a4n2)*Tin^2/2 + (a5n2)*Tin^3/3 + (a6n2)*Tin^4/4 + (a7n2)*Tin^5/5 + (b1n2))*R;\n \n uco2 = (h" "co2 - (-393510.0) + Hco2 - R*Tin)/CO2m; \n uh2o = (hh2o - (-241826.0) + Hh2o - R*Tin)/H2Om;\n un2 = (hn2 +" " Hn2 - R*Tin)/N2m;\n \n Utot = (Xco2*uco2 + Xh2o*uh2o + Xn2p*un2)*1000; \n \n Dco2 = -(R-R*((a1co2" ")/Tin^2 + (a2co2)/Tin + (a3co2) + (a4co2)*Tin + (a5co2)*Tin^2 + (a6co2)*Tin^3 + (a7co2)*Tin^4))/CO2m;\n Dh2o " "= -(R-R*((a1h2o)/Tin^2 + (a2h2o)/Tin + (a3h2o) + (a4h2o)*Tin + (a5h2o)*Tin^2 + (a6h2o)*Tin^3 + (a7h2o)*Tin^4))/H" "2Om; \n Dn2 = -(R-R*((a1n2)/Tin^2 + (a2n2)/Tin + (a3n2) + (a4n2)*Tin + (a5n2)*Tin^2 + (a6n2)*Tin^3 + (a7n2)*" "Tin^4))/N2m;\n \n Dtot = (Xco2*Dco2 + Xh2o*Dh2o + Xn2p*Dn2)*1000;\n\n To = Tin - ((Utot-U)/Dtot); \n\n " " E = sqrt(((To - Tin)/To)^2);\n \n if E < Ea\n n = 0;\n end\n\n Tin=To;\n n=n-1; " "\nend\nTp = Tin;\n\n\n\n" editorLayout "100 M4x1[135 5 1041 786]" inferBkpts [109] } } junction { id 60 position [23.5747 49.5747 7] chart 58 linkNode [58 0 0] subviewer 58 ssIdNumber 3 type CONNECTIVE_JUNCTION } transition { id 61 labelString "{eML_blk_kernel();}" labelPosition [32.125 19.875 102.544 14.964] fontSize 12 src { intersection [0 0 1 0 23.5747 14.625 0 0] } dst { id 60 intersection [7 0 -1 -1 23.5747 42.5747 0 0] } midPoint [23.5747 24.9468] chart 58 linkNode [58 0 0] dataLimits [23.575 23.575 14.625 34.575] subviewer 58 drawStyle SMART executionOrder 1 ssIdNumber 2 } data { id 62 ssIdNumber 19 name "U" linkNode [58 0 63] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 63 ssIdNumber 5 name "Tp" linkNode [58 62 64] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 64 ssIdNumber 14 name "R" linkNode [58 63 65] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 65 ssIdNumber 21 name "N2m" linkNode [58 64 66] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 66 ssIdNumber 15 name "Xco2" linkNode [58 65 67] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 67 ssIdNumber 16 name "Xh2o" linkNode [58 66 68] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 68 ssIdNumber 17 name "Xn2p" linkNode [58 67 69] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 69 ssIdNumber 22 name "CO2m" linkNode [58 68 70] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 70 ssIdNumber 23 name "H2Om" linkNode [58 69 0] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } instance { id 71 name "Cylinder/Subsystem/Combustion/CxHy Chem/Embedded\nMATLAB Post Combustion" machine 1 chart 58 } chart { id 72 name "Cylinder/Subsystem/Combustion/CxHy Chem/Embedded\nMATLAB Pre Combustion" windowPosition [343.667 264 200.25 189.75] viewLimits [0 156.75 0 153.75] screen [1 1 1440 900 1.333333333333333] treeNode [0 73 0 0] firstTransition 75 firstJunction 74 viewObj 72 machine 1 ssIdHighWaterMark 23 decomposition CLUSTER_CHART type EML_CHART firstData 76 chartFileNumber 8 disableImplicitCasting 1 eml { name "fcn" } } state { id 73 labelString "eML_blk_kernel()" position [18 64.5 118 66] fontSize 12 chart 72 treeNode [72 0 0 0] superState SUBCHART subviewer 72 ssIdNumber 1 type FUNC_STATE decomposition CLUSTER_STATE eml { isEML 1 script "function Tr = fcn(U, R, Xch, Xo2, Xn2r, CHm, O2m, N2m)\n\n\nn=50;\nEa=1e-6; % Error (%)\nTin = 3" "00;\n\n% Enthalpy at K=0 (kJ/kmol)\nHo2 = 8680.104;\nHn2 = 8670.104;\nHc8h18 = 32170.000;\n \nwhile n > 1\n " "\n if Tin <= 1000 \n % O2 (200 - 1000)\n a1o2 = -3.425563420E+04;\n a2o2 = 4.847000970E+02;\n " " a3o2 = 1.119010961E+00;\n a4o2 = 4.293889240E-03;\n a5o2 = -6.836300520E-07;\n a6o2 = -2.023372700E-09" ";\n a7o2 = 1.039040018E-12;\n b1o2 = -3.391454870E+03;\n \n % N2 (200 - 1000)\n a1n2 = 2.210371497" "E+04;\n a2n2 = -3.818461820E+02;\n a3n2 = 6.082738360E+00;\n a4n2 = -8.530914410E-03;\n a5n2 = 1.384" "646189E-05;\n a6n2 = -9.625793620E-09;\n a7n2 = 2.519705809E-12;\n b1n2 = 7.108460860E+02;\n \n %" " C8H18 (200 - 1000)\n a1ch = -1.688758565E+05;\n a2ch = 3.126903227E+03;\n a3ch = -2.123502828E+01;\n " " a4ch = 1.489151508E-01;\n a5ch = -1.151180135E-04;\n a6ch = 4.473216170E-08;\n a7ch = -5.554882070E-1" "2;\n b1ch = -4.468060620E+04; \n else \n % O2 (1000 - 6000)\n a1o2 = -1.037939022E+06;\n a" "2o2 = 2.344830282E+03;\n a3o2 = 1.819732036E+00;\n a4o2 = 1.267847582E-03;\n a5o2 = -2.188067988E-07;\n" " a6o2 = 2.053719572E-11;\n a7o2 = -8.193467050E-16;\n b1o2 = -1.689010929E+04;\n \n % N2 (1000 - " "6000)\n a1n2 = 5.877124060E+05;\n a2n2 = -2.239249073E+03;\n a3n2 = 6.066949220E+00;\n a4n2 = -6.139" "685500E-04;\n a5n2 = 1.491806679E-07;\n a6n2 = -1.923105485E-11;\n a7n2 = 1.061954386E-15;\n b1n2 = " "1.283210415E+04; \n \n %C8H18 (1000 - 6000) \n a1ch = 1.352765032E+07;\n a2ch = -4.663370340E+04;\n " " a3ch = 7.795313180E+01;\n a4ch = 1.423729984E-02;\n a5ch = -5.073593910E-06;\n a6ch = 7.248232970E-1" "0;\n a7ch = -3.819190110E-14;\n b1ch = 2.541178017E+05; \n end\n \n hch = (-(a1ch)/Tin + (a2ch" ")*log(Tin) + (a3ch)*Tin + (a4ch)*Tin^2/2 + (a5ch)*Tin^3/3 + (a6ch)*Tin^4/4 + (a7ch)*Tin^5/5 + (b1ch))*R;\n ho" "2 = (-(a1o2)/Tin + (a2o2)*log(Tin) + (a3o2)*Tin + (a4o2)*Tin^2/2 + (a5o2)*Tin^3/3 + (a6o2)*Tin^4/4 + (a7o2)*Tin^" "5/5 + (b1o2))*R; \n hn2 = (-(a1n2)/Tin + (a2n2)*log(Tin) + (a3n2)*Tin + (a4n2)*Tin^2/2 + (a5n2)*Tin^3/3 + (a" "6n2)*Tin^4/4 + (a7n2)*Tin^5/5 + (b1n2))*R;\n \n uch = (hch - (-224010.0) + Hc8h18 - R*Tin)/CHm;\n uo2 " "= (ho2 + Ho2 - R*Tin)/O2m;\n un2 = (hn2 + Hn2 - R*Tin)/N2m;\n \n Utot = (Xch*uch + Xo2*uo2 + Xn2r*un2)*" "1000;\n \n Dch = -(R-R*((a1ch)/Tin^2 + (a2ch)/Tin + (a3ch) + (a4ch)*Tin + (a5ch)*Tin^2 + (a6ch)*Tin^3 + (a7" "ch)*Tin^4))/CHm;\n Do2 = -(R-R*((a1o2)/Tin^2 + (a2o2)/Tin + (a3o2) + (a4o2)*Tin + (a5o2)*Tin^2 + (a6o2)*Tin^3" " + (a7o2)*Tin^4))/O2m; \n Dn2 = -(R-R*((a1n2)/Tin^2 + (a2n2)/Tin + (a3n2) + (a4n2)*Tin + (a5n2)*Tin^2 + (a6n" "2)*Tin^3 + (a7n2)*Tin^4))/N2m;\n \n Dtot = (Xch*Dch + Xo2*Do2 + Xn2r*Dn2)*1000;\n\n To = Tin - ((Utot-U" ")/Dtot); \n\n E = sqrt(((To - Tin)/To)^2);\n \n if E < Ea\n n = 0;\n end\n\n Tin=To;\n " "n=n-1;\n \nend\nTr = Tin;\n" editorLayout "100 M4x1[135 5 1041 786]" inferBkpts [109] } } junction { id 74 position [23.5747 49.5747 7] chart 72 linkNode [72 0 0] subviewer 72 ssIdNumber 3 type CONNECTIVE_JUNCTION } transition { id 75 labelString "{eML_blk_kernel();}" labelPosition [32.125 19.875 102.544 14.964] fontSize 12 src { intersection [0 0 1 0 23.5747 14.625 0 0] } dst { id 74 intersection [7 0 -1 -1 23.5747 42.5747 0 0] } midPoint [23.5747 24.9468] chart 72 linkNode [72 0 0] dataLimits [23.575 23.575 14.625 34.575] subviewer 72 drawStyle SMART executionOrder 1 ssIdNumber 2 } data { id 76 ssIdNumber 4 name "U" linkNode [72 0 77] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE } complexity SF_COMPLEX_INHERITED } dataType "Inherit: Same as Simulink" } data { id 77 ssIdNumber 5 name "Tr" linkNode [72 76 78] scope OUTPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE } complexity SF_COMPLEX_INHERITED frame SF_FRAME_NO } dataType "Inherit: Same as Simulink" } data { id 78 ssIdNumber 14 name "R" linkNode [72 77 79] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 79 ssIdNumber 15 name "Xch" linkNode [72 78 80] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 80 ssIdNumber 16 name "Xo2" linkNode [72 79 81] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 81 ssIdNumber 17 name "Xn2r" linkNode [72 80 82] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 82 ssIdNumber 20 name "CHm" linkNode [72 81 83] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 83 ssIdNumber 21 name "O2m" linkNode [72 82 84] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } data { id 84 ssIdNumber 22 name "N2m" linkNode [72 83 0] scope INPUT_DATA machine 1 props { array { size "-1" } type { method SF_INHERITED_TYPE primitive SF_DOUBLE_TYPE isSigned 1 wordLength "16" } complexity SF_COMPLEX_INHERITED frame SF_FRAME_INHERITED } dataType "Inherit: Same as Simulink" } instance { id 85 name "Cylinder/Subsystem/Combustion/CxHy Chem/Embedded\nMATLAB Pre Combustion" machine 1 chart 72 } target { id 86 name "sfun" description "Default Simulink S-Function Target." machine 1 linkNode [1 0 0] } }