# $Revision: 1.1.6.1 $
Model {
  Name			  "sldemo_radar"
  Version		  6.2
  MdlSubVersion		  0
  GraphicalInterface {
    NumRootInports	    0
    NumRootOutports	    2
    Outport {
      BusObject		      ""
      BusOutputAsStruct	      "off"
      SignalName	      "residual"
      Name		      "Residuals"
    }
    Outport {
      BusObject		      ""
      BusOutputAsStruct	      "off"
      SignalName	      "X_hat"
      Name		      "Est. Position [x, xdot, y, ydot]"
    }
    ParameterArgumentNames  ""
    ComputedModelVersion    "1.116"
    NumModelReferences	    0
    NumTestPointedSignals   5
    TestPointedSignal {
      SignalName	      "Measurement_noise"
      FullBlockPath	      "sldemo_radar/Meas. noise intensity"
      LogSignal		      1
    }
    TestPointedSignal {
      SignalName	      "residual"
      FullBlockPath	      "sldemo_radar/Radar Kalman Filter"
      LogSignal		      1
    }
    TestPointedSignal {
      SignalName	      "X_hat"
      FullBlockPath	      "sldemo_radar/Radar Kalman Filter"
      PortIndex		      2
      LogSignal		      1
    }
    TestPointedSignal {
      SignalName	      "PolarCoords"
      FullBlockPath	      "sldemo_radar/Sum"
      LogSignal		      1
    }
    TestPointedSignal {
      SignalName	      "XYCoords"
      FullBlockPath	      "sldemo_radar/XYPosition"
      LogSignal		      1
    }
  }
  Description		  "Radar tracking Demonstration \n\nThis demonstration"
" shows how to use an extended Kalman filter to estimate an\naircraft's positi"
"on from radar measurements. The filter implementation is found \nin the M-fil"
"e aero_extkalman.m.  The vehicle model is vectorized so that all\n3 degrees o"
"f freedom are computed using one set of blocks.\n\nAt the end of the simulati"
"on, three figures display the following information. The \nactual trajectory "
"compared to the estimated trajectory The estimation residual \nfor range The "
"actual, measured, and estimated position\n\n"
  SavedCharacterEncoding  "US-ASCII"
  SaveDefaultBlockParams  on
  SampleTimeColors	  on
  LibraryLinkDisplay	  "none"
  WideLines		  on
  ShowLineDimensions	  on
  ShowPortDataTypes	  off
  ShowLoopsOnError	  on
  IgnoreBidirectionalLines off
  ShowStorageClass	  off
  ShowTestPointIcons	  on
  ShowViewerIcons	  on
  SortedOrder		  off
  ExecutionContextIcon	  off
  ShowLinearizationAnnotations on
  RecordCoverage	  off
  CovPath		  "/"
  CovSaveName		  "covdata"
  CovMetricSettings	  "d"
  CovNameIncrementing	  off
  CovHtmlReporting	  on
  covSaveCumulativeToWorkspaceVar on
  CovSaveSingleToWorkspaceVar on
  CovCumulativeVarName	  "covCumulativeData"
  CovCumulativeReport	  off
  CovReportOnPause	  on
  ScopeRefreshTime	  0.035000
  OverrideScopeRefreshTime on
  DisableAllScopes	  off
  DataTypeOverride	  "UseLocalSettings"
  MinMaxOverflowLogging	  "UseLocalSettings"
  MinMaxOverflowArchiveMode "Overwrite"
  BlockNameDataTip	  off
  BlockParametersDataTip  on
  BlockDescriptionStringDataTip	off
  ToolBar		  on
  StatusBar		  on
  BrowserShowLibraryLinks off
  BrowserLookUnderMasks	  off
  CloseFcn		  "h=findobj('type','figure');if ~isempty(h);close(h);"
"end\nclear radarLogsOut"
  StartFcn		  "clear radarLogsOut"
  StopFcn		  "aero_radplot;"
  Created		  "Tue May 18 14:42:29 1999"
  Creator		  "The MathWorks Inc."
  UpdateHistory		  "UpdateHistoryNever"
  ModifiedByFormat	  "%<Auto>"
  LastModifiedBy	  "batserve"
  ModifiedDateFormat	  "%<Auto>"
  LastModifiedDate	  "Sat Jan 22 19:08:18 2005"
  ModelVersionFormat	  "1.%<AutoIncrement:116>"
  ConfigurationManager	  "none"
  LinearizationMsg	  "none"
  Profile		  off
  ParamWorkspaceSource	  "MATLABWorkspace"
  AccelSystemTargetFile	  "accel.tlc"
  AccelTemplateMakefile	  "accel_default_tmf"
  AccelMakeCommand	  "make_rtw"
  TryForcingSFcnDF	  off
  ExtModeBatchMode	  off
  ExtModeEnableFloating	  on
  ExtModeTrigType	  "manual"
  ExtModeTrigMode	  "oneshot"
  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	  off
  ExtModeSkipDownloadWhenConnect off
  ExtModeLogAll		  on
  ExtModeAutoUpdateStatusClock off
  BufferReuse		  on
  StrictBusMsg		  "None"
  ProdHWDeviceType	  "32-bit Generic"
  ShowModelReferenceBlockVersion off
  ShowModelReferenceBlockIO off
  Array {
    Type		    "Handle"
    Dimension		    1
    Simulink.ConfigSet {
      $ObjectID		      1
      Version		      "1.1.0"
      Array {
	Type			"Handle"
	Dimension		7
	Simulink.SolverCC {
	  $ObjectID		  2
	  Version		  "1.1.0"
	  StartTime		  "0.0"
	  StopTime		  "100"
	  AbsTol		  "1e-6"
	  FixedStep		  "0.1"
	  InitialStep		  "auto"
	  MaxNumMinSteps	  "-1"
	  MaxOrder		  5
	  ExtrapolationOrder	  4
	  NumberNewtonIterations  1
	  MaxStep		  "0.1"
	  MinStep		  "auto"
	  RelTol		  "1e-3"
	  SolverMode		  "SingleTasking"
	  Solver		  "ode5"
	  SolverName		  "ode5"
	  ZeroCrossControl	  "UseLocalSettings"
	  AlgebraicLoopSolver	  "TrustRegion"
	  SolverResetMethod	  "Fast"
	  PositivePriorityOrder	  off
	  AutoInsertRateTranBlk	  off
	  SampleTimeConstraint	  "Unconstrained"
	  RateTranMode		  "Deterministic"
	}
	Simulink.DataIOCC {
	  $ObjectID		  3
	  Version		  "1.1.0"
	  Decimation		  "1"
	  ExternalInput		  "[t, u]"
	  FinalStateName	  "xFinal"
	  InitialState		  "xInitial"
	  LimitDataPoints	  off
	  MaxDataPoints		  "1000"
	  LoadExternalInput	  off
	  LoadInitialState	  off
	  SaveFinalState	  off
	  SaveFormat		  "Array"
	  SaveOutput		  off
	  SaveState		  off
	  SignalLogging		  on
	  SaveTime		  off
	  StateSaveName		  "xout"
	  TimeSaveName		  "t_sim"
	  OutputSaveName	  "yout"
	  SignalLoggingName	  "radarLogsOut"
	  OutputOption		  "RefineOutputTimes"
	  OutputTimes		  "[]"
	  Refine		  "1"
	}
	Simulink.OptimizationCC {
	  $ObjectID		  4
	  Version		  "1.1.0"
	  BlockReduction	  on
	  BooleanDataType	  on
	  ConditionallyExecuteInputs on
	  InlineParams		  on
	  InlineInvariantSignals  on
	  OptimizeBlockIOStorage  on
	  BufferReuse		  on
	  EnforceIntegerDowncast  off
	  ExpressionFolding	  on
	  FoldNonRolledExpr	  on
	  LocalBlockOutputs	  on
	  ParameterPooling	  on
	  RollThreshold		  5
	  SystemCodeInlineAuto	  off
	  StateBitsets		  on
	  DataBitsets		  on
	  UseTempVars		  on
	  ZeroExternalMemoryAtStartup off
	  ZeroInternalMemoryAtStartup off
	  InitFltsAndDblsToZero	  off
	  NoFixptDivByZeroProtection on
	  EfficientFloat2IntCast  off
	  OptimizeModelRefInitCode on
	  LifeSpan		  "1"
	  BufferReusableBoundary  off
	}
	Simulink.DebuggingCC {
	  $ObjectID		  5
	  Version		  "1.1.0"
	  RTPrefix		  "error"
	  ConsistencyChecking	  "none"
	  ArrayBoundsChecking	  "none"
	  SignalInfNanChecking	  "none"
	  AlgebraicLoopMsg	  "warning"
	  ArtificialAlgebraicLoopMsg "warning"
	  CheckSSInitialOutputMsg on
	  CheckExecutionContextPreStartOutputMsg on
	  CheckExecutionContextRuntimeOutputMsg	on
	  SignalResolutionControl "TryResolveAllWithWarning"
	  BlockPriorityViolationMsg "warning"
	  MinStepSizeMsg	  "warning"
	  SolverPrmCheckMsg	  "none"
	  InheritedTsInSrcMsg	  "warning"
	  DiscreteInheritContinuousMsg "warning"
	  MultiTaskDSMMsg	  "warning"
	  MultiTaskRateTransMsg	  "error"
	  SingleTaskRateTransMsg  "none"
	  TasksWithSamePriorityMsg "warning"
	  CheckMatrixSingularityMsg "none"
	  IntegerOverflowMsg	  "warning"
	  Int32ToFloatConvMsg	  "warning"
	  ParameterDowncastMsg	  "error"
	  ParameterOverflowMsg	  "error"
	  ParameterPrecisionLossMsg "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"
	  ModelReferenceSimTargetVerbose off
	  UnknownTsInhSupMsg	  "warning"
	  ModelReferenceDataLoggingMessage "warning"
	  ModelReferenceSymbolNameMessage "warning"
	  ModelReferenceExtraNoncontSigs "error"
	}
	Simulink.HardwareCC {
	  $ObjectID		  6
	  Version		  "1.1.0"
	  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.1.0"
	  UpdateModelReferenceTargets "IfOutOfDateOrStructuralChange"
	  CheckModelReferenceTargetMessage "error"
	  ModelReferenceNumInstancesAllowed "Multi"
	  ModelReferencePassRootInputsByReference on
	  ModelReferenceMinAlgLoopOccurrences off
	}
	Simulink.RTWCC {
	  $BackupClass		  "Simulink.RTWCC"
	  $ObjectID		  8
	  Version		  "1.1.0"
	  SystemTargetFile	  "ert.tlc"
	  TLCOptions		  "-p0 -aWarnNonSaturatedBlocks=0"
	  GenCodeOnly		  off
	  MakeCommand		  "make_rtw"
	  TemplateMakefile	  "ert_default_tmf"
	  Description		  "RTW Embedded Coder (no auto configuration)"
	  GenerateReport	  on
	  SaveLog		  off
	  RTWVerbose		  off
	  RetainRTWFile		  off
	  ProfileTLC		  off
	  TLCDebug		  off
	  TLCCoverage		  off
	  TLCAssert		  off
	  ProcessScriptMode	  "Default"
	  ConfigurationMode	  "Optimized"
	  ProcessScript		  "ert_make_rtw_hook"
	  ConfigAtBuild		  off
	  IncludeHyperlinkInReport on
	  LaunchReport		  on
	  TargetLang		  "C"
	  Array {
	    Type		    "Handle"
	    Dimension		    2
	    Simulink.CodeAppCC {
	      $ObjectID		      9
	      Version		      "1.1.0"
	      ForceParamTrailComments on
	      GenerateComments	      on
	      IgnoreCustomStorageClasses off
	      IncHierarchyInIds	      off
	      MaxIdLength	      31
	      PreserveName	      off
	      PreserveNameWithParent  off
	      ShowEliminatedStatement off
	      IncAutoGenComments      off
	      SimulinkDataObjDesc     on
	      SFDataObjDesc	      off
	      IncDataTypeInIds	      off
	      PrefixModelToSubsysFcnNames on
	      CustomSymbolStr	      "$N$M"
	      MangleLength	      1
	      DefineNamingRule	      "None"
	      ParamNamingRule	      "None"
	      SignalNamingRule	      "None"
	      InsertBlockDesc	      on
	      SimulinkBlockComments   on
	      EnableCustomComments    off
	      InlinedPrmAccess	      "Literals"
	      ReqsInCode	      off
	    }
	    Simulink.ERTTargetCC {
	      $BackupClass	      "Simulink.TargetCC"
	      $ObjectID		      10
	      Version		      "1.1.0"
	      TargetFcnLib	      "ansi_tfl_tmw.mat"
	      TargetLibSuffix	      ""
	      TargetPreCompLibLocation ""
	      GenFloatMathFcnCalls    "ANSI_C"
	      UtilityFuncGeneration   "Auto"
	      GenerateFullHeader      on
	      GenerateSampleERTMain   on
	      IsPILTarget	      off
	      ModelReferenceCompliant on
	      IncludeMdlTerminateFcn  off
	      CombineOutputUpdateFcns on
	      SuppressErrorStatus     off
	      IncludeFileDelimiter    "Auto"
	      ERTCustomFileBanners    on
	      SupportAbsoluteTime     on
	      LogVarNameModifier      "rt_"
	      MatFileLogging	      off
	      MultiInstanceERTCode    off
	      SupportNonFinite	      on
	      SupportComplex	      off
	      PurelyIntegerCode	      off
	      SupportContinuousTime   on
	      SupportNonInlinedSFcns  on
	      GenerateErtSFunction    off
	      GenerateASAP2	      off
	      ExtMode		      off
	      ExtModeTransport	      0
	      ExtModeStaticAlloc      off
	      ExtModeStaticAllocSize  1000000
	      ExtModeTesting	      off
	      ExtModeMexFile	      "ext_comm"
	      InlinedParameterPlacement	"NonHierarchical"
	      TargetOS		      "BareBoardExample"
	      MultiInstanceErrorCode  "Error"
	      RateGroupingCode	      on
	      RootIOFormat	      "Individual arguments"
	      RTWCAPISignals	      off
	      RTWCAPIParams	      off
	      RTWCAPIStates	      off
	      ERTSrcFileBannerTemplate "ert_code_template.cgt"
	      ERTHdrFileBannerTemplate "ert_code_template.cgt"
	      ERTDataSrcFileTemplate  "ert_code_template.cgt"
	      ERTDataHdrFileTemplate  "ert_code_template.cgt"
	      ERTCustomFileTemplate   "example_file_process.tlc"
	      InitialValueSource      "Model"
	      ModuleNamingRule	      "Unspecified"
	      SignalDisplayLevel      10
	      ParamTuneLevel	      10
	      GlobalDataDefinition    "Auto"
	      GlobalDataReference     "Auto"
	      GRTInterface	      off
	    }
	    PropName		    "Components"
	  }
	}
	PropName		"Components"
      }
      Name		      "Configuration"
      SimulationMode	      "normal"
      ExtraOptions	      "-aInitFltsAndDblsToZero=0 -p0 -aWarnNonSaturate"
"dBlocks=0"
      CurrentDlgPage	      "Solver"
    }
    PropName		    "ConfigurationSets"
  }
  Simulink.ConfigSet {
    $PropName		    "ActiveConfigurationSet"
    $ObjectID		    1
  }
  WSDataSource		  "M-Code"
  WSMCode		  "g = 32.2;    % Acceleration due to gravity (ft/sec^"
"2)\ntauc = 5;    % Correlation time of aircraft cross axis acceleration\ntauT"
" = 4;    % Correlation time of aircraft thrust axis acceleration\nSpeed = 400"
"; % Initial speed of aircraft in y direction feet/sec\ndeltat = 1;  % Radar u"
"pdate rate (also hard-coded in extkalman.m)\n"
  BlockDefaults {
    Orientation		    "right"
    ForegroundColor	    "black"
    BackgroundColor	    "white"
    DropShadow		    off
    NamePlacement	    "normal"
    FontName		    "Helvetica"
    FontSize		    10
    FontWeight		    "normal"
    FontAngle		    "normal"
    ShowName		    on
  }
  BlockParameterDefaults {
    Block {
      BlockType		      Constant
      Value		      "1"
      VectorParams1D	      on
      OutDataTypeMode	      "Inherit from 'Constant value'"
      OutDataType	      "sfix(16)"
      ConRadixGroup	      "Use specified scaling"
      OutScaling	      "2^0"
      SampleTime	      "inf"
    }
    Block {
      BlockType		      Demux
      Outputs		      "4"
      DisplayOption	      "none"
      BusSelectionMode	      off
    }
    Block {
      BlockType		      Gain
      Gain		      "1"
      Multiplication	      "Element-wise(K.*u)"
      ParameterDataTypeMode   "Same as input"
      ParameterDataType	      "sfix(16)"
      ParameterScalingMode    "Best Precision: Matrix-wise"
      ParameterScaling	      "2^0"
      OutDataTypeMode	      "Same as input"
      OutDataType	      "sfix(16)"
      OutScaling	      "2^0"
      LockScale		      off
      RndMeth		      "Floor"
      SaturateOnIntegerOverflow	on
      SampleTime	      "-1"
    }
    Block {
      BlockType		      SignalConversion
      OverrideOpt	      off
    }
    Block {
      BlockType		      Inport
      UseBusObject	      off
      BusObject		      "BusObject"
      BusOutputAsStruct	      off
      PortDimensions	      "-1"
      SampleTime	      "-1"
      DataType		      "auto"
      OutDataType	      "sfix(16)"
      OutScaling	      "2^0"
      SignalType	      "auto"
      SamplingMode	      "auto"
      Interpolate	      on
    }
    Block {
      BlockType		      InportShadow
      UseBusObject	      off
      BusObject		      "BusObject"
      BusOutputAsStruct	      off
      PortDimensions	      "-1"
      SampleTime	      "-1"
      DataType		      "auto"
      OutDataType	      "sfix(16)"
      OutScaling	      "2^0"
      SignalType	      "auto"
      SamplingMode	      "auto"
      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
    }
    Block {
      BlockType		      Math
      Operator		      "exp"
      OutputSignalType	      "auto"
      SampleTime	      "-1"
      OutDataTypeMode	      "Same as first input"
      OutDataType	      "sfix(16)"
      OutScaling	      "2^0"
      LockScale		      off
      RndMeth		      "Floor"
      SaturateOnIntegerOverflow	on
    }
    Block {
      BlockType		      MATLABFcn
      MATLABFcn		      "sin"
      OutputDimensions	      "-1"
      OutputSignalType	      "auto"
      Output1D		      on
      SampleTime	      "-1"
    }
    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"
      DataType		      "auto"
      OutDataType	      "sfix(16)"
      OutScaling	      "2^0"
      SignalType	      "auto"
      SamplingMode	      "auto"
      OutputWhenDisabled      "held"
      InitialOutput	      "[]"
    }
    Block {
      BlockType		      RandomNumber
      Mean		      "0"
      Variance		      "1"
      Seed		      "0"
      SampleTime	      "-1"
      VectorParams1D	      on
    }
    Block {
      BlockType		      Reference
    }
    Block {
      BlockType		      Selector
      InputType		      "Vector"
      IndexMode		      "One-based"
      ElementSrc	      "Internal"
      Elements		      "1"
      RowSrc		      "Internal"
      Rows		      "1"
      ColumnSrc		      "Internal"
      Columns		      "1"
      InputPortWidth	      "-1"
      IndexIsStartValue	      off
      OutputPortSize	      "1"
    }
    Block {
      BlockType		      SubSystem
      ShowPortLabels	      on
      Permissions	      "ReadWrite"
      PermitHierarchicalResolution "All"
      SystemSampleTime	      "-1"
      RTWFcnNameOpts	      "Auto"
      RTWFileNameOpts	      "Auto"
      SimViewingDevice	      off
      DataTypeOverride	      "UseLocalSettings"
      MinMaxOverflowLogging   "UseLocalSettings"
    }
    Block {
      BlockType		      Sum
      IconShape		      "rectangular"
      Inputs		      "++"
      InputSameDT	      on
      OutDataTypeMode	      "Same as first input"
      OutDataType	      "sfix(16)"
      OutScaling	      "2^0"
      LockScale		      off
      RndMeth		      "Floor"
      SaturateOnIntegerOverflow	on
      SampleTime	      "-1"
    }
    Block {
      BlockType		      Trigonometry
      Operator		      "sin"
      OutputSignalType	      "auto"
      SampleTime	      "-1"
    }
    Block {
      BlockType		      UnitDelay
      X0		      "0"
      SampleTime	      "1"
      StateMustResolveToSignalObject off
      RTWStateStorageClass    "Auto"
    }
    Block {
      BlockType		      ZeroOrderHold
      SampleTime	      "1"
    }
  }
  AnnotationDefaults {
    HorizontalAlignment	    "center"
    VerticalAlignment	    "middle"
    ForegroundColor	    "black"
    BackgroundColor	    "white"
    DropShadow		    off
    FontName		    "Helvetica"
    FontSize		    10
    FontWeight		    "normal"
    FontAngle		    "normal"
  }
  LineDefaults {
    FontName		    "Helvetica"
    FontSize		    9
    FontWeight		    "normal"
    FontAngle		    "normal"
  }
  System {
    Name		    "sldemo_radar"
    Location		    [54, 115, 917, 505]
    Open		    on
    ModelBrowserVisibility  off
    ModelBrowserWidth	    200
    ScreenColor		    "white"
    PaperOrientation	    "landscape"
    PaperPositionMode	    "auto"
    PaperType		    "usletter"
    PaperUnits		    "inches"
    ZoomFactor		    "100"
    ReportName		    "simulink-default.rpt"
    Block {
      BlockType		      Gain
      Name		      "Meas. noise\nintensity"
      Position		      [240, 196, 300, 254]
      Gain		      "[300 0; 0 .01]"
      Multiplication	      "Matrix(K*u) (u vector)"
      ParameterDataTypeMode   "Inherit via internal rule"
      OutDataTypeMode	      "Inherit via internal rule"
      SaturateOnIntegerOverflow	off
      Port {
	PortNumber		1
	Name			"Measurement_noise"
	TestPoint		on
	RTWStorageClass		"Auto"
	DataLogging		on
	DataLoggingNameMode	"SignalName"
	ShowSigGenPortName	on
      }
    }
    Block {
      BlockType		      SubSystem
      Name		      "More Info"
      Ports		      []
      Position		      [825, 15, 849, 38]
      DropShadow	      on
      ShowName		      off
      TreatAsAtomicUnit	      off
      MinAlgLoopOccurrences   off
      RTWSystemCode	      "Auto"
      MaskDisplay	      "disp('?')"
      MaskIconFrame	      on
      MaskIconOpaque	      on
      MaskIconRotate	      "none"
      MaskIconUnits	      "autoscale"
      System {
	Name			"More Info"
	Location		[90, 227, 736, 651]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Block {
	  BlockType		  Reference
	  Name			  "Model Info"
	  Ports			  []
	  Position		  [15, 22, 630, 408]
	  ShowName		  off
	  FontName		  "Arial"
	  SourceBlock		  "simulink/Model-Wide\nUtilities/Model Info"
	  SourceType		  "CMBlock"
	  ShowPortLabels	  "on"
	  InitialBlockCM	  "none"
	  BlockCM		  "none"
	  Frame			  "on"
	  DisplayStringWithTags	  "Model Description:\n-------------------\n\n"
"%<Description>"
	  MaskDisplayString	  "Model Description:\\n-------------------\\n"
"\\nRadar tracking Demonstration \\n\\nThis demonstration shows how to use an "
"extended Kalman filter to estimate an\\naircraft's position from radar measur"
"ements. The filter implementation is found \\nin the M-file aero_extkalman.m."
"  The vehicle model is vectorized so that all\\n3 degrees of freedom are comp"
"uted using one set of blocks.\\n\\nAt the end of the simulation, three figure"
"s display the following information. The \\nactual trajectory compared to the"
" estimated trajectory The estimation residual \\nfor range The actual, measur"
"ed, and estimated position\\n\\n"
	  HorizontalTextAlignment "Left"
	  LeftAlignmentValue	  "0.02"
	  SourceBlockDiagram	  "sldemo_radar"
	  TagMaxNumber		  "20"
	}
      }
    }
    Block {
      BlockType		      SubSystem
      Name		      "Radar\nKalman Filter"
      Ports		      [1, 2]
      Position		      [605, 112, 720, 203]
      ForegroundColor	      "green"
      TreatAsAtomicUnit	      on
      MinAlgLoopOccurrences   off
      RTWSystemCode	      "Auto"
      Port {
	PortNumber		1
	Name			"residual"
	TestPoint		on
	RTWStorageClass		"Auto"
	DataLogging		on
	DataLoggingNameMode	"SignalName"
	ShowSigGenPortName	on
      }
      Port {
	PortNumber		2
	Name			"X_hat"
	TestPoint		on
	RTWStorageClass		"Auto"
	DataLogging		on
	DataLoggingNameMode	"SignalName"
	ShowSigGenPortName	on
      }
      System {
	Name			"Radar\nKalman Filter"
	Location		[376, 86, 1239, 476]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Block {
	  BlockType		  Inport
	  Name			  "meas"
	  Position		  [40, 48, 70, 62]
	  Port			  "1"
	  IconDisplay		  "Port number"
	  LatchInput		  off
	}
	Block {
	  BlockType		  Constant
	  Name			  "\n"
	  Position		  [160, 120, 200, 140]
	  Orientation		  "up"
	  ForegroundColor	  "green"
	  Value			  "deltat"
	}
	Block {
	  BlockType		  MATLABFcn
	  Name			  "Extended\nKalman Filter"
	  Position		  [280, 34, 370, 96]
	  ForegroundColor	  "green"
	  MATLABFcn		  "aero_extkalman"
	  OutputDimensions	  "23"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux2"
	  Ports			  [3, 1]
	  Position		  [235, 47, 240, 83]
	  ForegroundColor	  "green"
	  ShowName		  off
	  Inputs		  "3"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  UnitDelay
	  Name			  "Previous\nxhat and \nCovariance Matrix"
	  Position		  [305, 154, 345, 196]
	  Orientation		  "left"
	  ForegroundColor	  "green"
	  X0			  "[0.001; 0.01; 0.001; 400; zeros(16,1)]"
	  SampleTime		  "deltat"
	}
	Block {
	  BlockType		  SignalConversion
	  Name			  "Signal\nConversion1"
	  Position		  [610, 44, 650, 86]
	  ConversionOutput	  "Contiguous copy"
	  OverrideOpt		  on
	}
	Block {
	  BlockType		  SignalConversion
	  Name			  "Signal\nConversion2"
	  Position		  [610, 154, 650, 196]
	  ConversionOutput	  "Contiguous copy"
	  OverrideOpt		  on
	}
	Block {
	  BlockType		  Selector
	  Name			  "Vector\nSelection1"
	  Ports			  [1, 1]
	  Position		  [525, 45, 570, 85]
	  ForegroundColor	  "green"
	  AttributesFormatString  "elts = %<Elements>"
	  Elements		  "[1,2]"
	  InputPortWidth	  "23"
	}
	Block {
	  BlockType		  Selector
	  Name			  "Vector\nSelection2"
	  Ports			  [1, 1]
	  Position		  [395, 155, 440, 195]
	  Orientation		  "left"
	  ForegroundColor	  "green"
	  AttributesFormatString  "elts = %<Elements>"
	  Elements		  "[3:22]"
	  InputPortWidth	  "23"
	}
	Block {
	  BlockType		  Selector
	  Name			  "Vector\nSelection3"
	  Ports			  [1, 1]
	  Position		  [525, 155, 570, 195]
	  ForegroundColor	  "green"
	  AttributesFormatString  "elts = %<Elements>"
	  Elements		  "[3,4,5,6]"
	  InputPortWidth	  "23"
	}
	Block {
	  BlockType		  Outport
	  Name			  "residual"
	  Position		  [690, 58, 720, 72]
	  ForegroundColor	  "green"
	  IconDisplay		  "Port number"
	  BusOutputAsStruct	  off
	  InitialOutput		  "0"
	}
	Block {
	  BlockType		  Outport
	  Name			  "xhat Out"
	  Position		  [690, 168, 720, 182]
	  ForegroundColor	  "green"
	  Port			  "2"
	  IconDisplay		  "Port number"
	  BusOutputAsStruct	  off
	  InitialOutput		  "0"
	}
	Line {
	  SrcBlock		  "Vector\nSelection1"
	  SrcPort		  1
	  DstBlock		  "Signal\nConversion1"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Mux2"
	  SrcPort		  1
	  DstBlock		  "Extended\nKalman Filter"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Previous\nxhat and \nCovariance Matrix"
	  SrcPort		  1
	  Points		  [-155, 0; 0, -110]
	  DstBlock		  "Mux2"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "\n"
	  SrcPort		  1
	  Points		  [0, -40]
	  DstBlock		  "Mux2"
	  DstPort		  3
	}
	Line {
	  SrcBlock		  "Vector\nSelection3"
	  SrcPort		  1
	  DstBlock		  "Signal\nConversion2"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Extended\nKalman Filter"
	  SrcPort		  1
	  Points		  [0, 0; 105, 0]
	  Branch {
	    Points		    [0, 110]
	    Branch {
	      DstBlock		      "Vector\nSelection3"
	      DstPort		      1
	    }
	    Branch {
	      DstBlock		      "Vector\nSelection2"
	      DstPort		      1
	    }
	  }
	  Branch {
	    DstBlock		    "Vector\nSelection1"
	    DstPort		    1
	  }
	}
	Line {
	  SrcBlock		  "meas"
	  SrcPort		  1
	  DstBlock		  "Mux2"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Vector\nSelection2"
	  SrcPort		  1
	  DstBlock		  "Previous\nxhat and \nCovariance Matrix"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Signal\nConversion1"
	  SrcPort		  1
	  DstBlock		  "residual"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Signal\nConversion2"
	  SrcPort		  1
	  DstBlock		  "xhat Out"
	  DstPort		  1
	}
      }
    }
    Block {
      BlockType		      Reference
      Name		      "Radar \nMeasurment\nNoise"
      Ports		      [0, 1]
      Position		      [40, 209, 80, 241]
      SourceBlock	      "simulink/Sources/Band-Limited\nWhite Noise"
      SourceType	      "Band-Limited White Noise."
      ShowPortLabels	      on
      Cov		      "[1 1]"
      Ts		      "0.1"
      seed		      "[52341 62341]"
      VectorParams1D	      on
    }
    Block {
      BlockType		      Reference
      Name		      "Random\naircraft\nmotion"
      Ports		      [0, 1]
      Position		      [40, 77, 80, 113]
      SourceBlock	      "simulink/Sources/Band-Limited\nWhite Noise"
      SourceType	      "Band-Limited White Noise."
      ShowPortLabels	      on
      Cov		      "[0.001 .001]"
      Ts		      "0.1"
      seed		      "[58413 74925]"
      VectorParams1D	      on
    }
    Block {
      BlockType		      Sum
      Name		      "Sum"
      Ports		      [2, 1]
      Position		      [435, 145, 465, 175]
      ShowName		      off
      IconShape		      "round"
      Inputs		      "2"
      Port {
	PortNumber		1
	Name			"PolarCoords"
	TestPoint		on
	RTWStorageClass		"Auto"
	DataLogging		on
	DataLoggingNameMode	"SignalName"
	ShowSigGenPortName	on
      }
    }
    Block {
      BlockType		      SubSystem
      Name		      "XY\nAccleration\nModel"
      Ports		      [1, 1]
      Position		      [115, 76, 155, 114]
      BackgroundColor	      "[0.956863, 1.000000, 0.666667]"
      DropShadow	      on
      TreatAsAtomicUnit	      off
      MinAlgLoopOccurrences   off
      RTWSystemCode	      "Auto"
      System {
	Name			"XY\nAccleration\nModel"
	Location		[96, 385, 537, 564]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Block {
	  BlockType		  Inport
	  Name			  "F"
	  Position		  [55, 62, 85, 78]
	  ForegroundColor	  "red"
	  Port			  "1"
	  IconDisplay		  "Port number"
	  LatchInput		  off
	}
	Block {
	  BlockType		  Gain
	  Name			  "Gain2"
	  Position		  [150, 120, 275, 180]
	  Orientation		  "left"
	  Gain			  "[ 1/tauc, 1/tauT ]"
	}
	Block {
	  BlockType		  Gain
	  Name			  "Gravity"
	  Position		  [335, 64, 370, 96]
	  Gain			  "g"
	}
	Block {
	  BlockType		  Integrator
	  Name			  "Integrator1"
	  Ports			  [1, 1]
	  Position		  [245, 66, 275, 94]
	  IgnoreLimit		  off
	}
	Block {
	  BlockType		  Sum
	  Name			  "Sum1"
	  Ports			  [2, 1]
	  Position		  [145, 62, 165, 93]
	  Inputs		  "+-"
	}
	Block {
	  BlockType		  Outport
	  Name			  "a"
	  Position		  [400, 72, 430, 88]
	  IconDisplay		  "Port number"
	  BusOutputAsStruct	  off
	  InitialOutput		  "0"
	}
	Line {
	  SrcBlock		  "F"
	  SrcPort		  1
	  DstBlock		  "Sum1"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Gain2"
	  SrcPort		  1
	  Points		  [-42, 0; 0, -65]
	  DstBlock		  "Sum1"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "Integrator1"
	  SrcPort		  1
	  Points		  [0, 0; 23, 0]
	  Branch {
	    DstBlock		    "Gravity"
	    DstPort		    1
	  }
	  Branch {
	    Points		    [0, 70]
	    DstBlock		    "Gain2"
	    DstPort		    1
	  }
	}
	Line {
	  SrcBlock		  "Sum1"
	  SrcPort		  1
	  DstBlock		  "Integrator1"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Gravity"
	  SrcPort		  1
	  DstBlock		  "a"
	  DstPort		  1
	}
      }
    }
    Block {
      BlockType		      SubSystem
      Name		      "XY to\nRange-Bearing"
      Ports		      [1, 1]
      Position		      [365, 70, 415, 120]
      BackgroundColor	      "[0.956863, 1.000000, 0.666667]"
      TreatAsAtomicUnit	      off
      MinAlgLoopOccurrences   off
      RTWSystemCode	      "Auto"
      MaskType		      "xy2rtheta"
      MaskDescription	      "Vector transformation from cartesian to polar c"
"oordinates.\ninput:   [x, y]\noutput: [r, theta]\n\nr = hypot(x,y));\ntheta ="
" atan2(y,x);"
      MaskHelp		      "Use \"Look under mask\" to see the implementati"
"on, done in Simulink blocks."
      MaskDisplay	      "plot(0,0,100,100,[24,20,15,20,20],[85,95,85,95,"
"20],[80,20,95,85,95,85],[70,20,20,15,20,24],[56,56,55,52,50,46],[20,26,31,35,"
"38,42])"
      MaskIconFrame	      on
      MaskIconOpaque	      on
      MaskIconRotate	      "none"
      MaskIconUnits	      "autoscale"
      System {
	Name			"XY to\nRange-Bearing"
	Location		[136, 183, 495, 389]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Block {
	  BlockType		  Inport
	  Name			  "XY"
	  Position		  [25, 77, 60, 93]
	  Port			  "1"
	  IconDisplay		  "Port number"
	  LatchInput		  off
	}
	Block {
	  BlockType		  Demux
	  Name			  "Demux"
	  Ports			  [1, 2]
	  Position		  [100, 58, 110, 107]
	  BackgroundColor	  "black"
	  ShowName		  off
	  Outputs		  "2"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Demux
	  Name			  "Demux1"
	  Ports			  [1, 2]
	  Position		  [100, 128, 110, 177]
	  BackgroundColor	  "black"
	  ShowName		  off
	  Outputs		  "2"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux"
	  Ports			  [2, 1]
	  Position		  [355, 52, 365, 188]
	  ShowName		  off
	  Inputs		  "2"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  InportShadow
	  Name			  "XY1"
	  Position		  [25, 147, 60, 163]
	  Port			  "1"
	  IconDisplay		  "Port number"
	  LatchInput		  off
	}
	Block {
	  BlockType		  Trigonometry
	  Name			  "bearing"
	  Ports			  [2, 1]
	  Position		  [220, 128, 270, 177]
	  Operator		  "atan2"
	}
	Block {
	  BlockType		  Math
	  Name			  "range"
	  Ports			  [2, 1]
	  Position		  [220, 58, 270, 107]
	  Operator		  "hypot"
	}
	Block {
	  BlockType		  Outport
	  Name			  "Rth"
	  Position		  [415, 112, 450, 128]
	  IconDisplay		  "Port number"
	  BusOutputAsStruct	  off
	  InitialOutput		  "0"
	}
	Line {
	  SrcBlock		  "Mux"
	  SrcPort		  1
	  DstBlock		  "Rth"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "range"
	  SrcPort		  1
	  DstBlock		  "Mux"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "XY"
	  SrcPort		  1
	  DstBlock		  "Demux"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Demux"
	  SrcPort		  1
	  DstBlock		  "range"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Demux"
	  SrcPort		  2
	  DstBlock		  "range"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "XY1"
	  SrcPort		  1
	  DstBlock		  "Demux1"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "bearing"
	  SrcPort		  1
	  DstBlock		  "Mux"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "Demux1"
	  SrcPort		  1
	  Points		  [30, 0; 35, 25]
	  DstBlock		  "bearing"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "Demux1"
	  SrcPort		  2
	  Points		  [30, 0; 35, -25]
	  DstBlock		  "bearing"
	  DstPort		  1
	}
      }
    }
    Block {
      BlockType		      Integrator
      Name		      "XYPosition"
      Ports		      [1, 1]
      Position		      [270, 76, 305, 114]
      BackgroundColor	      "[0.956863, 1.000000, 0.666667]"
      IgnoreLimit	      off
      Port {
	PortNumber		1
	Name			"XYCoords"
	TestPoint		on
	RTWStorageClass		"Auto"
	DataLogging		on
	DataLoggingNameMode	"SignalName"
	ShowSigGenPortName	on
      }
    }
    Block {
      BlockType		      Integrator
      Name		      "XYVelocity"
      Ports		      [1, 1]
      Position		      [190, 76, 225, 114]
      BackgroundColor	      "[0.956863, 1.000000, 0.666667]"
      InitialCondition	      "[0, Speed]"
      IgnoreLimit	      off
      Port {
	PortNumber		1
	Name			"xydot"
	RTWStorageClass		"Auto"
	DataLoggingNameMode	"SignalName"
	ShowSigGenPortName	on
      }
    }
    Block {
      BlockType		      ZeroOrderHold
      Name		      "ZOH"
      Position		      [540, 145, 570, 175]
      ForegroundColor	      "green"
      SampleTime	      "deltat"
    }
    Block {
      BlockType		      Outport
      Name		      "Residuals"
      Position		      [780, 128, 810, 142]
      IconDisplay	      "Port number"
      BusOutputAsStruct	      off
    }
    Block {
      BlockType		      Outport
      Name		      "Est. Position\n[x, xdot, y, ydot]"
      Position		      [780, 173, 810, 187]
      Port		      "2"
      IconDisplay	      "Port number"
      BusOutputAsStruct	      off
    }
    Line {
      Name		      "XYCoords"
      Labels		      [0, 0; 0, 0; 0, 0; 0, 0; 0, 0]
      SrcBlock		      "XYPosition"
      SrcPort		      1
      DstBlock		      "XY to\nRange-Bearing"
      DstPort		      1
    }
    Line {
      SrcBlock		      "XY to\nRange-Bearing"
      SrcPort		      1
      Points		      [30, 0]
      DstBlock		      "Sum"
      DstPort		      1
    }
    Line {
      Name		      "PolarCoords"
      Labels		      [0, 0]
      SrcBlock		      "Sum"
      SrcPort		      1
      DstBlock		      "ZOH"
      DstPort		      1
    }
    Line {
      Name		      "xydot"
      Labels		      [0, 0; 0, 0; 0, 0; 0, 0; 0, 0; 0, 0]
      SrcBlock		      "XYVelocity"
      SrcPort		      1
      DstBlock		      "XYPosition"
      DstPort		      1
    }
    Line {
      SrcBlock		      "XY\nAccleration\nModel"
      SrcPort		      1
      DstBlock		      "XYVelocity"
      DstPort		      1
    }
    Line {
      Name		      "residual"
      Labels		      [0, 0]
      SrcBlock		      "Radar\nKalman Filter"
      SrcPort		      1
      DstBlock		      "Residuals"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Random\naircraft\nmotion"
      SrcPort		      1
      DstBlock		      "XY\nAccleration\nModel"
      DstPort		      1
    }
    Line {
      Name		      "X_hat"
      Labels		      [0, 0]
      SrcBlock		      "Radar\nKalman Filter"
      SrcPort		      2
      DstBlock		      "Est. Position\n[x, xdot, y, ydot]"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Radar \nMeasurment\nNoise"
      SrcPort		      1
      DstBlock		      "Meas. noise\nintensity"
      DstPort		      1
    }
    Line {
      Name		      "Measurement_noise"
      Labels		      [0, 0]
      SrcBlock		      "Meas. noise\nintensity"
      SrcPort		      1
      Points		      [145, 0]
      DstBlock		      "Sum"
      DstPort		      2
    }
    Line {
      SrcBlock		      "ZOH"
      SrcPort		      1
      DstBlock		      "Radar\nKalman Filter"
      DstPort		      1
    }
    Annotation {
      Name		      "Radar Tracking Demonstration"
      Position		      [409, 25]
      FontName		      "Arial"
      FontSize		      18
      FontWeight	      "bold"
    }
  }
}

# Finite State Machines
#
#    Stateflow Version 6.2 (R14SP2) dated Jan 21 2005, 03:46:19
#
#

Stateflow {

	machine {
		id                   		1
		name                 		"sldemo_radar"
		created              		"05-Mar-2003 11:55:40"
		isLibrary            		0
		firstTarget          		2
		sfVersion            		62014000
		sfDemoChecksum       		[3608240946 1782078800 2518399552 826293299]
	}

	target {
		id                        		2
		name                      		"sfun"
		description               		"Default Simulink S-Function Target."
		codeFlags                 		" debug=1 overflow=1 echo=1"
		machine                   		1
		linkNode                  		[1 0 3]
	}

	target {
		id                        		3
		name                      		"rtw"
		codeFlags                 		" comments=1 statebitsets=1 databitsets=1 emitlogicalops=1 el"
						"seifdetection=1 constantfolding=1 redundantloadelimination=0"
						" preserveconstantnames=0 preservenames=0 preservenameswithpa"
						"rent=0 exportcharts=0"
		machine                   		1
		linkNode                  		[1 2 0]
	}
}
