Model {
  Name			  "freqsyn_sim"
  Version		  4.00
  SampleTimeColors	  off
  LibraryLinkDisplay	  "none"
  WideLines		  on
  ShowLineDimensions	  on
  ShowPortDataTypes	  off
  RecordCoverage	  off
  CovPath		  "/"
  CovSaveName		  "covdata"
  CovNameIncrementing	  off
  CovHtmlReporting	  on
  BlockNameDataTip	  off
  BlockParametersDataTip  off
  BlockDescriptionStringDataTip	off
  ToolBar		  on
  StatusBar		  on
  BrowserShowLibraryLinks off
  BrowserLookUnderMasks	  off
  PostLoadFcn		  "M=3;N=10;fr=30e6;fq=fr;sen=40e6;"
  Created		  "Wed Aug 09 10:22:45 2000"
  UpdateHistory		  "UpdateHistoryNever"
  ModifiedByFormat	  "%<Auto>"
  LastModifiedBy	  "ysong"
  ModifiedDateFormat	  "%<Auto>"
  LastModifiedDate	  "Thu Sep 07 14:44:27 2000"
  ModelVersionFormat	  "1.%<AutoIncrement:61>"
  ConfigurationManager	  "none"
  SimParamPage		  "Solver"
  StartTime		  "0.0"
  StopTime		  "500*M/fr"
  SolverMode		  "Auto"
  Solver		  "ode45"
  RelTol		  "1e-3"
  AbsTol		  "auto"
  Refine		  "1"
  MaxStep		  ".5/(fr*N/M)"
  MinStep		  "auto"
  MaxNumMinSteps	  "-1"
  InitialStep		  "auto"
  FixedStep		  ".1/(fr*N/M)"
  MaxOrder		  5
  OutputOption		  "RefineOutputTimes"
  OutputTimes		  "[]"
  LoadExternalInput	  off
  ExternalInput		  "[t, u]"
  SaveTime		  on
  TimeSaveName		  "tout"
  SaveState		  off
  StateSaveName		  "xout"
  SaveOutput		  on
  OutputSaveName	  "yout"
  LoadInitialState	  off
  InitialState		  "xInitial"
  SaveFinalState	  off
  FinalStateName	  "xFinal"
  SaveFormat		  "Array"
  LimitDataPoints	  on
  MaxDataPoints		  "1000"
  Decimation		  "1"
  AlgebraicLoopMsg	  "warning"
  MinStepSizeMsg	  "warning"
  UnconnectedInputMsg	  "warning"
  UnconnectedOutputMsg	  "warning"
  UnconnectedLineMsg	  "warning"
  InheritedTsInSrcMsg	  "warning"
  SingleTaskRateTransMsg  "none"
  MultiTaskRateTransMsg	  "error"
  IntegerOverflowMsg	  "warning"
  CheckForMatrixSingularity "none"
  UnnecessaryDatatypeConvMsg "none"
  Int32ToFloatConvMsg	  "warning"
  SignalLabelMismatchMsg  "none"
  LinearizationMsg	  "none"
  VectorMatrixConversionMsg "none"
  SfunCompatibilityCheckMsg "none"
  BlockPriorityViolationMsg "warning"
  ArrayBoundsChecking	  "none"
  ConsistencyChecking	  "none"
  ZeroCross		  on
  Profile		  off
  SimulationMode	  "normal"
  RTWSystemTargetFile	  "grt.tlc"
  RTWInlineParameters	  off
  RTWRetainRTWFile	  off
  RTWTemplateMakefile	  "grt_default_tmf"
  RTWMakeCommand	  "make_rtw"
  RTWGenerateCodeOnly	  off
  TLCProfiler		  off
  TLCDebug		  off
  TLCCoverage		  off
  AccelSystemTargetFile	  "accel.tlc"
  AccelTemplateMakefile	  "accel_default_tmf"
  AccelMakeCommand	  "make_rtw"
  ExtModeMexFile	  "ext_comm"
  ExtModeBatchMode	  off
  ExtModeTrigType	  "manual"
  ExtModeTrigMode	  "normal"
  ExtModeTrigPort	  "1"
  ExtModeTrigElement	  "any"
  ExtModeTrigDuration	  1000
  ExtModeTrigHoldOff	  0
  ExtModeTrigDelay	  0
  ExtModeTrigDirection	  "rising"
  ExtModeTrigLevel	  0
  ExtModeArchiveMode	  "off"
  ExtModeAutoIncOneShot	  off
  ExtModeIncDirWhenArm	  off
  ExtModeAddSuffixToVar	  off
  ExtModeWriteAllDataToWs off
  ExtModeArmWhenConnect	  on
  ExtModeLogAll		  on
  OptimizeBlockIOStorage  on
  BufferReuse		  on
  ParameterPooling	  on
  BlockReductionOpt	  off
  BooleanDataType	  off
  BlockDefaults {
    Orientation		    "right"
    ForegroundColor	    "black"
    BackgroundColor	    "white"
    DropShadow		    off
    NamePlacement	    "normal"
    FontName		    "MS Sans Serif"
    FontSize		    10
    FontWeight		    "normal"
    FontAngle		    "normal"
    ShowName		    on
  }
  AnnotationDefaults {
    HorizontalAlignment	    "center"
    VerticalAlignment	    "middle"
    ForegroundColor	    "black"
    BackgroundColor	    "white"
    DropShadow		    off
    FontName		    "MS Sans Serif"
    FontSize		    10
    FontWeight		    "normal"
    FontAngle		    "normal"
  }
  LineDefaults {
    FontName		    "MS Sans Serif"
    FontSize		    9
    FontWeight		    "normal"
    FontAngle		    "normal"
  }
  System {
    Name		    "freqsyn_sim"
    Location		    [138, 281, 939, 686]
    Open		    on
    ModelBrowserVisibility  off
    ModelBrowserWidth	    200
    ScreenColor		    "automatic"
    PaperOrientation	    "landscape"
    PaperPositionMode	    "auto"
    PaperType		    "usletter"
    PaperUnits		    "inches"
    ZoomFactor		    "100"
    AutoZoom		    off
    ReportName		    "simulink-default.rpt"
    Block {
      BlockType		      Reference
      Name		      "Analog\nFilter Design"
      Ports		      [1, 1]
      Position		      [375, 212, 440, 258]
      FontName		      "Helvetica"
      SourceBlock	      "dsparch3/Analog\nFilter Design"
      SourceType	      "Analog Filter Design"
      method		      "Butterworth"
      filttype		      "Lowpass"
      N			      "1"
      Wlo		      "fr/M/10"
      Whi		      "80"
      Rp		      "2"
      Rs		      "40"
    }
    Block {
      BlockType		      Scope
      Name		      "Control\nSignal"
      Ports		      [1]
      Position		      [540, 144, 570, 176]
      FontName		      "Helvetica"
      Floating		      off
      Location		      [17, 59, 341, 300]
      Open		      on
      NumInputPorts	      "1"
      TickLabels	      "OneTimeTick"
      ZoomMode		      "xonly"
      List {
	ListType		AxesTitles
	axes1			"%<SignalLabel>"
      }
      Grid		      "on"
      TimeRange		      "5e-005"
      YMin		      "0"
      YMax		      "2.5"
      SaveToWorkspace	      off
      SaveName		      "ScopeData1"
      DataFormat	      "StructureWithTime"
      LimitDataPoints	      off
      MaxDataPoints	      "5000"
      Decimation	      "1"
      SampleInput	      off
      SampleTime	      "0"
    }
    Block {
      BlockType		      SubSystem
      Name		      "Convert to\nSquare Wave"
      Ports		      [1, 1]
      Position		      [630, 214, 680, 256]
      FontName		      "Helvetica"
      ShowPortLabels	      on
      TreatAsAtomicUnit	      off
      RTWSystemCode	      "Auto"
      RTWFcnNameOpts	      "Auto"
      RTWFileNameOpts	      "Auto"
      System {
	Name			"Convert to\nSquare Wave"
	Location		[438, 264, 670, 389]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"automatic"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	AutoZoom		on
	Block {
	  BlockType		  Inport
	  Name			  "In1"
	  Position		  [30, 28, 60, 42]
	  FontName		  "Helvetica"
	  Port			  "1"
	  Interpolate		  on
	}
	Block {
	  BlockType		  Constant
	  Name			  "Constant4"
	  Position		  [30, 65, 50, 85]
	  ShowName		  off
	  FontName		  "Helvetica"
	  Value			  "0"
	  VectorParams1D	  on
	}
	Block {
	  BlockType		  RelationalOperator
	  Name			  "Relational\nOperator"
	  Position		  [85, 28, 115, 52]
	  ShowName		  off
	  FontName		  "Helvetica"
	  Operator		  ">"
	}
	Block {
	  BlockType		  Outport
	  Name			  "Out1"
	  Position		  [140, 33, 170, 47]
	  FontName		  "Helvetica"
	  Port			  "1"
	  OutputWhenDisabled	  "held"
	  InitialOutput		  "[]"
	}
	Line {
	  SrcBlock		  "Relational\nOperator"
	  SrcPort		  1
	  DstBlock		  "Out1"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "In1"
	  SrcPort		  1
	  DstBlock		  "Relational\nOperator"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Constant4"
	  SrcPort		  1
	  Points		  [15, 0]
	  DstBlock		  "Relational\nOperator"
	  DstPort		  2
	}
      }
    }
    Block {
      BlockType		      Reference
      Name		      "Frequency Divider"
      Ports		      [1, 1]
      Position		      [120, 201, 210, 249]
      ShowName		      off
      AncestorBlock	      "freqdiv/Frequency Divider"
      FontName		      "Arial"
      SourceBlock	      "commblksprivate/Frequency Divider"
      SourceType	      "Frequency Divider"
      n			      "M"
    }
    Block {
      BlockType		      Reference
      Name		      "Frequency Divider1"
      Ports		      [1, 1]
      Position		      [430, 326, 520, 374]
      Orientation	      "left"
      ShowName		      off
      AncestorBlock	      "freqdiv/Frequency Divider"
      FontName		      "Arial"
      SourceBlock	      "commblksprivate/Frequency Divider"
      SourceType	      "Frequency Divider"
      n			      "N"
    }
    Block {
      BlockType		      Scope
      Name		      "Frequency-Divided\nReference Signal"
      Ports		      [1]
      Position		      [275, 144, 305, 176]
      FontName		      "Helvetica"
      Floating		      off
      Location		      [686, 384, 1010, 623]
      Open		      off
      NumInputPorts	      "1"
      TickLabels	      "OneTimeTick"
      ZoomMode		      "on"
      List {
	ListType		AxesTitles
	axes1			"%<SignalLabel>"
      }
      Grid		      "on"
      TimeRange		      "2e-007"
      YMin		      "-1"
      YMax		      "2"
      SaveToWorkspace	      off
      SaveName		      "ScopeData5"
      DataFormat	      "StructureWithTime"
      LimitDataPoints	      on
      MaxDataPoints	      "5000"
      Decimation	      "1"
      SampleInput	      off
      SampleTime	      "0"
    }
    Block {
      BlockType		      Scope
      Name		      "Frequency-Divided\nSynthesized Signal"
      Ports		      [1]
      Position		      [310, 284, 340, 316]
      FontName		      "Helvetica"
      Floating		      off
      Location		      [352, 385, 676, 624]
      Open		      off
      NumInputPorts	      "1"
      TickLabels	      "OneTimeTick"
      ZoomMode		      "on"
      List {
	ListType		AxesTitles
	axes1			"%<SignalLabel>"
      }
      Grid		      "on"
      TimeRange		      "2e-007"
      YMin		      "-1"
      YMax		      "2"
      SaveToWorkspace	      off
      SaveName		      "ScopeData4"
      DataFormat	      "StructureWithTime"
      LimitDataPoints	      on
      MaxDataPoints	      "5000"
      Decimation	      "1"
      SampleInput	      off
      SampleTime	      "0"
    }
    Block {
      BlockType		      Gain
      Name		      "Gain"
      Position		      [465, 220, 495, 250]
      FontName		      "Helvetica"
      Gain		      "(fr*N/M-fq)*2/sen"
      Multiplication	      "Element-wise(K.*u)"
      SaturateOnIntegerOverflow	on
    }
    Block {
      BlockType		      SubSystem
      Name		      "Model Info"
      Ports		      []
      Position		      [710, 54, 761, 94]
      BackgroundColor	      "lightBlue"
      ShowName		      off
      CopyFcn		      "slcm CopyBlock;"
      DeleteFcn		      "slcm Cancel;"
      LoadFcn		      "slcm LoadBlock;"
      PostSaveFcn	      "slcm('UpdateAllCMBlocksInThisModel')"
      InitFcn		      "slcm('UpdateAllCMBlocksInThisModelInit')"
      NameChangeFcn	      "slcm Rename;"
      OpenFcn		      "commdemohelp;"
      FontName		      "Arial"
      FontSize		      12
      ShowPortLabels	      on
      TreatAsAtomicUnit	      off
      RTWSystemCode	      "Auto"
      RTWFcnNameOpts	      "Auto"
      RTWFileNameOpts	      "Auto"
      MaskType		      "CMBlock"
      MaskDescription	      "This block allows revision control information "
"to be displayed within the model."
      MaskPromptString	      "InitialSaveTempField|InitialBlockCM|BlockCM|Fra"
"me|SaveTempField|DisplayStringWithTags|MaskDisplayString|HorizontalTextAlignm"
"ent|LeftAlignmentValue|SourceBlockDiagram|TagMaxNumber|CMTag1|CMTag2|CMTag3|C"
"MTag4|CMTag5|CMTag6|CMTag7|CMTag8|CMTag9|CMTag10|CMTag11|CMTag12|CMTag13|CMTa"
"g14|CMTag15|CMTag16|CMTag17|CMTag18|CMTag19|CMTag20"
      MaskStyleString	      "edit,edit,edit,edit,edit,edit,edit,edit,edit,ed"
"it,edit,edit,edit,edit,edit,edit,edit,edit,edit,edit,edit,edit,edit,edit,edit"
",edit,edit,edit,edit,edit,edit"
      MaskTunableValueString  "on,on,on,on,on,on,on,on,on,on,on,on,on,on,on,on"
",on,on,on,on,on,on,on,on,on,on,on,on,on,on,on"
      MaskCallbackString      "||||||||||||||||||||||||||||||"
      MaskEnableString	      "on,on,on,on,on,on,on,on,on,on,on,on,on,on,on,on"
",on,on,on,on,on,on,on,on,on,on,on,on,on,on,on"
      MaskVisibilityString    "off,off,off,off,off,off,off,off,off,off,off,off"
",off,off,off,off,off,off,off,off,off,off,off,off,off,off,off,off,off,off,off"
      MaskToolTipString	      "on,on,on,on,on,on,on,on,on,on,on,on,on,on,on,on"
",on,on,on,on,on,on,on,on,on,on,on,on,on,on,on"
      MaskVariables	      "InitialSaveTempField=&1;InitialBlockCM=&2;Block"
"CM=&3;Frame=&4;SaveTempField=&5;DisplayStringWithTags=&6;MaskDisplayString=&7"
";HorizontalTextAlignment=&8;LeftAlignmentValue=&9;SourceBlockDiagram=&10;TagM"
"axNumber=@11;CMTag1=&12;CMTag2=&13;CMTag3=&14;CMTag4=&15;CMTag5=&16;CMTag6=&1"
"7;CMTag7=&18;CMTag8=&19;CMTag9=&20;CMTag10=&21;CMTag11=&22;CMTag12=&23;CMTag1"
"3=&24;CMTag14=&25;CMTag15=&26;CMTag16=&27;CMTag17=&28;CMTag18=&29;CMTag19=&30"
";CMTag20=&31;"
      MaskDisplay	      "text(str2num(LeftAlignmentValue), 0.5, MaskDisp"
"layString, 'HorizontalAlignment', HorizontalTextAlignment)\n"
      MaskSelfModifiable      on
      MaskIconFrame	      on
      MaskIconOpaque	      on
      MaskIconRotate	      "none"
      MaskIconUnits	      "normalized"
      MaskValueString	      "|none|none|on||Info|Info|Center|0.5|freqsyn_sim"
"|20||||||||||||||||||||"
      MaskVariableAliases     ",,,,,,,,,,,,,,,,,,,,,,,,,,,,,,"
      System {
	Name			"Model Info"
	Location		[154, 467, 416, 618]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	AutoZoom		on
	Block {
	  BlockType		  SubSystem
	  Name			  "EmptySubsystem"
	  Ports			  []
	  Position		  [115, 50, 145, 80]
	  FontName		  "Helvetica"
	  ShowPortLabels	  on
	  TreatAsAtomicUnit	  off
	  RTWSystemCode		  "Auto"
	  RTWFcnNameOpts	  "Auto"
	  RTWFileNameOpts	  "Auto"
	  System {
	    Name		    "EmptySubsystem"
	    Location		    [146, 180, 902, 673]
	    Open		    off
	    ModelBrowserVisibility  off
	    ModelBrowserWidth	    200
	    ScreenColor		    "white"
	    PaperOrientation	    "landscape"
	    PaperPositionMode	    "auto"
	    PaperType		    "usletter"
	    PaperUnits		    "inches"
	    ZoomFactor		    "100"
	    AutoZoom		    on
	  }
	}
      }
    }
    Block {
      BlockType		      Logic
      Name		      "Phase\nDetector"
      Ports		      [2, 1]
      Position		      [275, 217, 305, 248]
      FontName		      "Helvetica"
      Operator		      "XOR"
      Inputs		      "2"
    }
    Block {
      BlockType		      Scope
      Name		      "Phase Detector\nOutput"
      Ports		      [1]
      Position		      [375, 144, 405, 176]
      FontName		      "Helvetica"
      Floating		      off
      Location		      [18, 385, 342, 625]
      Open		      off
      NumInputPorts	      "1"
      TickLabels	      "OneTimeTick"
      ZoomMode		      "on"
      List {
	ListType		AxesTitles
	axes1			"%<SignalLabel>"
      }
      Grid		      "on"
      TimeRange		      "2e-007"
      YMin		      "-1"
      YMax		      "2"
      SaveToWorkspace	      off
      SaveName		      "ScopeData6"
      DataFormat	      "StructureWithTime"
      LimitDataPoints	      on
      MaxDataPoints	      "5000"
      Decimation	      "1"
      SampleInput	      off
      SampleTime	      "0"
    }
    Block {
      BlockType		      Reference
      Name		      "Pulse\nGenerator"
      Ports		      [0, 1]
      Position		      [40, 210, 70, 240]
      FontName		      "Helvetica"
      SourceBlock	      "simulink3/Sources/Pulse\nGenerator"
      SourceType	      "Pulse Generator"
      period		      "1/fr"
      duty		      "50"
      amplitude		      "1"
      start		      "0"
      VectorParams1D	      on
    }
    Block {
      BlockType		      Scope
      Name		      "Reference\nSignal"
      Ports		      [1]
      Position		      [125, 284, 155, 316]
      FontName		      "Helvetica"
      Floating		      off
      Location		      [681, 60, 1005, 300]
      Open		      on
      NumInputPorts	      "1"
      TickLabels	      "OneTimeTick"
      ZoomMode		      "on"
      List {
	ListType		AxesTitles
	axes1			"%<SignalLabel>"
      }
      Grid		      "on"
      TimeRange		      "1e-007"
      YMin		      "-1"
      YMax		      "2"
      SaveToWorkspace	      off
      SaveName		      "ScopeData"
      DataFormat	      "StructureWithTime"
      LimitDataPoints	      on
      MaxDataPoints	      "5000"
      Decimation	      "1"
      SampleInput	      off
      SampleTime	      "0"
    }
    Block {
      BlockType		      Scope
      Name		      "Synthesized\nSignal"
      Ports		      [1]
      Position		      [730, 219, 760, 251]
      FontName		      "Helvetica"
      Floating		      off
      Location		      [349, 59, 673, 300]
      Open		      on
      NumInputPorts	      "1"
      TickLabels	      "OneTimeTick"
      ZoomMode		      "xonly"
      List {
	ListType		AxesTitles
	axes1			"%<SignalLabel>"
      }
      Grid		      "on"
      TimeRange		      "5e-008"
      YMin		      "-1"
      YMax		      "2"
      SaveToWorkspace	      off
      SaveName		      "ScopeData2"
      DataFormat	      "StructureWithTime"
      LimitDataPoints	      on
      MaxDataPoints	      "50000"
      Decimation	      "1"
      SampleInput	      off
      SampleTime	      "0"
    }
    Block {
      BlockType		      Reference
      Name		      "Voltage-Controlled\nOscillator"
      Ports		      [1, 1]
      Position		      [535, 213, 600, 257]
      ShowName		      off
      FontName		      "Helvetica"
      SourceBlock	      "commsource2/Voltage-Controlled\nOscillator"
      SourceType	      "Voltage-Controlled Oscillator"
      Ac		      "1"
      Fc		      "fq"
      Kc		      "sen"
      Ph		      "0"
    }
    Line {
      SrcBlock		      "Pulse\nGenerator"
      SrcPort		      1
      Points		      [0, 0; 20, 0]
      Branch {
	Points			[0, 75]
	DstBlock		"Reference\nSignal"
	DstPort			1
      }
      Branch {
	DstBlock		"Frequency Divider"
	DstPort			1
      }
    }
    Line {
      SrcBlock		      "Phase\nDetector"
      SrcPort		      1
      Points		      [0, 0; 40, 0]
      Branch {
	DstBlock		"Analog\nFilter Design"
	DstPort			1
      }
      Branch {
	Points			[0, -75]
	DstBlock		"Phase Detector\nOutput"
	DstPort			1
      }
    }
    Line {
      SrcBlock		      "Gain"
      SrcPort		      1
      Points		      [15, 0]
      Branch {
	DstBlock		"Voltage-Controlled\nOscillator"
	DstPort			1
      }
      Branch {
	Points			[0, -75]
	DstBlock		"Control\nSignal"
	DstPort			1
      }
    }
    Line {
      SrcBlock		      "Voltage-Controlled\nOscillator"
      SrcPort		      1
      DstBlock		      "Convert to\nSquare Wave"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Convert to\nSquare Wave"
      SrcPort		      1
      Points		      [0, 0; 15, 0]
      Branch {
	DstBlock		"Synthesized\nSignal"
	DstPort			1
      }
      Branch {
	Points			[0, 115]
	DstBlock		"Frequency Divider1"
	DstPort			1
      }
    }
    Line {
      SrcBlock		      "Frequency Divider"
      SrcPort		      1
      Points		      [20, 0]
      Branch {
	DstBlock		"Phase\nDetector"
	DstPort			1
      }
      Branch {
	Points			[0, -65]
	DstBlock		"Frequency-Divided\nReference Signal"
	DstPort			1
      }
    }
    Line {
      SrcBlock		      "Frequency Divider1"
      SrcPort		      1
      Points		      [-165, 0; 0, -50]
      Branch {
	DstBlock		"Phase\nDetector"
	DstPort			2
      }
      Branch {
	DstBlock		"Frequency-Divided\nSynthesized Signal"
	DstPort			1
      }
    }
    Line {
      SrcBlock		      "Analog\nFilter Design"
      SrcPort		      1
      DstBlock		      "Gain"
      DstPort		      1
    }
    Annotation {
      Position		      [406, 31]
      Text		      "Phase-Locked Frequency Synthesis"
      FontName		      "Arial"
      FontSize		      14
      FontWeight	      "bold"
    }
    Annotation {
      Position		      [390, 70]
      Text		      "fr -- reference frequency,  fq -- VCO quiescent"
" frequency,  sen -- VCO sensitivity\nSynthesized frequency = fr*N/M"
      FontName		      "Arial"
      FontSize		      12
    }
  }
}
