Model {
  Name			  "SM"
  Version		  5.0
  SaveDefaultBlockParams  on
  SampleTimeColors	  off
  LibraryLinkDisplay	  "none"
  WideLines		  off
  ShowLineDimensions	  off
  ShowPortDataTypes	  off
  ShowLoopsOnError	  on
  IgnoreBidirectionalLines off
  ShowStorageClass	  off
  ExecutionOrder	  off
  RecordCoverage	  off
  CovPath		  "/"
  CovSaveName		  "covdata"
  CovMetricSettings	  "dw"
  CovNameIncrementing	  off
  CovHtmlReporting	  on
  covSaveCumulativeToWorkspaceVar on
  CovSaveSingleToWorkspaceVar on
  CovCumulativeVarName	  "covCumulativeData"
  CovCumulativeReport	  off
  DataTypeOverride	  "UseLocalSettings"
  MinMaxOverflowLogging	  "UseLocalSettings"
  MinMaxOverflowArchiveMode "Overwrite"
  BlockNameDataTip	  off
  BlockParametersDataTip  on
  BlockDescriptionStringDataTip	off
  ToolBar		  on
  StatusBar		  on
  BrowserShowLibraryLinks off
  BrowserLookUnderMasks	  off
  Created		  "Sun Apr 16 18:43:48 2006"
  UpdateHistory		  "UpdateHistoryNever"
  ModifiedByFormat	  "%<Auto>"
  LastModifiedBy	  "Tutelea Lucian"
  ModifiedDateFormat	  "%<Auto>"
  LastModifiedDate	  "Fri Oct 17 12:01:46 2008"
  ModelVersionFormat	  "1.%<AutoIncrement:20>"
  ConfigurationManager	  "none"
  SimParamPage		  "Solver"
  LinearizationMsg	  "none"
  Profile		  off
  ParamWorkspaceSource	  "MATLABWorkspace"
  AccelSystemTargetFile	  "accel.tlc"
  AccelTemplateMakefile	  "accel_default_tmf"
  AccelMakeCommand	  "make_rtw"
  TryForcingSFcnDF	  off
  ExtModeMexFile	  "ext_comm"
  ExtModeBatchMode	  off
  ExtModeTrigType	  "manual"
  ExtModeTrigMode	  "oneshot"
  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	  off
  ExtModeSkipDownloadWhenConnect off
  ExtModeLogAll		  on
  ExtModeAutoUpdateStatusClock on
  BufferReuse		  on
  RTWExpressionDepthLimit 5
  SimulationMode	  "normal"
  Solver		  "ode45"
  SolverMode		  "Auto"
  StartTime		  "0.0"
  StopTime		  "5"
  MaxOrder		  5
  MaxStep		  "0.001"
  MinStep		  "auto"
  MaxNumMinSteps	  "-1"
  InitialStep		  "auto"
  FixedStep		  "auto"
  RelTol		  "1e-3"
  AbsTol		  "auto"
  OutputOption		  "RefineOutputTimes"
  OutputTimes		  "[]"
  Refine		  "1"
  LoadExternalInput	  off
  ExternalInput		  "[t, u]"
  LoadInitialState	  off
  InitialState		  "xInitial"
  SaveTime		  on
  TimeSaveName		  "tout"
  SaveState		  off
  StateSaveName		  "xout"
  SaveOutput		  on
  OutputSaveName	  "yout"
  SaveFinalState	  off
  FinalStateName	  "xFinal"
  SaveFormat		  "Array"
  Decimation		  "1"
  LimitDataPoints	  off
  MaxDataPoints		  "1000"
  SignalLoggingName	  "sigsOut"
  ConsistencyChecking	  "none"
  ArrayBoundsChecking	  "none"
  AlgebraicLoopMsg	  "warning"
  BlockPriorityViolationMsg "warning"
  MinStepSizeMsg	  "warning"
  InheritedTsInSrcMsg	  "warning"
  DiscreteInheritContinuousMsg "warning"
  MultiTaskRateTransMsg	  "error"
  SingleTaskRateTransMsg  "none"
  CheckForMatrixSingularity "none"
  IntegerOverflowMsg	  "warning"
  Int32ToFloatConvMsg	  "warning"
  ParameterDowncastMsg	  "error"
  ParameterOverflowMsg	  "error"
  ParameterPrecisionLossMsg "warning"
  UnderSpecifiedDataTypeMsg "none"
  UnnecessaryDatatypeConvMsg "none"
  VectorMatrixConversionMsg "none"
  InvalidFcnCallConnMsg	  "error"
  SignalLabelMismatchMsg  "none"
  UnconnectedInputMsg	  "warning"
  UnconnectedOutputMsg	  "warning"
  UnconnectedLineMsg	  "warning"
  SfunCompatibilityCheckMsg "none"
  RTWInlineParameters	  off
  BlockReductionOpt	  on
  BooleanDataType	  off
  ConditionallyExecuteInputs on
  ParameterPooling	  on
  OptimizeBlockIOStorage  on
  ZeroCross		  on
  AssertionControl	  "UseLocalSettings"
  ProdHWDeviceType	  "Microprocessor"
  ProdHWWordLengths	  "8,16,32,32"
  RTWSystemTargetFile	  "grt.tlc"
  RTWTemplateMakefile	  "grt_default_tmf"
  RTWMakeCommand	  "make_rtw"
  RTWGenerateCodeOnly	  off
  RTWRetainRTWFile	  off
  TLCProfiler		  off
  TLCDebug		  off
  TLCCoverage		  off
  TLCAssertion		  off
  BlockDefaults {
    Orientation		    "right"
    ForegroundColor	    "black"
    BackgroundColor	    "white"
    DropShadow		    off
    NamePlacement	    "normal"
    FontName		    "Helvetica"
    FontSize		    10
    FontWeight		    "normal"
    FontAngle		    "normal"
    ShowName		    on
  }
  BlockParameterDefaults {
    Block {
      BlockType		      Fcn
      Expr		      "sin(u[1])"
    }
    Block {
      BlockType		      Gain
      Gain		      "1"
      Multiplication	      "Element-wise(K.*u)"
      ShowAdditionalParam     off
      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
    }
    Block {
      BlockType		      Inport
      Port		      "1"
      PortDimensions	      "-1"
      SampleTime	      "-1"
      ShowAdditionalParam     off
      LatchInput	      off
      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"
      ZeroCross		      on
    }
    Block {
      BlockType		      Mux
      Inputs		      "4"
      DisplayOption	      "none"
    }
    Block {
      BlockType		      Outport
      Port		      "1"
      OutputWhenDisabled      "held"
      InitialOutput	      "[]"
    }
    Block {
      BlockType		      Scope
      Floating		      off
      ModelBased	      off
      TickLabels	      "OneTimeTick"
      ZoomMode		      "on"
      Grid		      "on"
      TimeRange		      "auto"
      YMin		      "-5"
      YMax		      "5"
      SaveToWorkspace	      off
      SaveName		      "ScopeData"
      LimitDataPoints	      on
      MaxDataPoints	      "5000"
      Decimation	      "1"
      SampleInput	      off
      SampleTime	      "0"
    }
    Block {
      BlockType		      Sin
      SineType		      "Time based"
      Amplitude		      "1"
      Bias		      "0"
      Frequency		      "1"
      Phase		      "0"
      Samples		      "10"
      Offset		      "0"
      SampleTime	      "-1"
      VectorParams1D	      on
    }
    Block {
      BlockType		      Step
      Time		      "1"
      Before		      "0"
      After		      "1"
      SampleTime	      "-1"
      VectorParams1D	      on
      ZeroCross		      on
    }
    Block {
      BlockType		      SubSystem
      ShowPortLabels	      on
      Permissions	      "ReadWrite"
      RTWSystemCode	      "Auto"
      RTWFcnNameOpts	      "Auto"
      RTWFileNameOpts	      "Auto"
      SimViewingDevice	      off
      DataTypeOverride	      "UseLocalSettings"
      MinMaxOverflowLogging   "UseLocalSettings"
    }
    Block {
      BlockType		      Trigonometry
      Operator		      "sin"
      OutputSignalType	      "auto"
    }
  }
  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		    "SM"
    Location		    [2, 82, 1014, 744]
    Open		    on
    ModelBrowserVisibility  off
    ModelBrowserWidth	    200
    ScreenColor		    "white"
    PaperOrientation	    "landscape"
    PaperPositionMode	    "auto"
    PaperType		    "usletter"
    PaperUnits		    "inches"
    ZoomFactor		    "156"
    ReportName		    "simulink-default.rpt"
    Block {
      BlockType		      SubSystem
      Name		      "Excitation control"
      Ports		      [0, 1]
      Position		      [35, 168, 95, 222]
      TreatAsAtomicUnit	      off
      MaskPromptString	      "Ven|Rex|Rex0|tsinc|ke"
      MaskStyleString	      "edit,edit,edit,edit,edit"
      MaskTunableValueString  "on,on,on,on,on"
      MaskCallbackString      "||||"
      MaskEnableString	      "on,on,on,on,on"
      MaskVisibilityString    "on,on,on,on,on"
      MaskToolTipString	      "on,on,on,on,on"
      MaskVarAliasString      ",,,,"
      MaskVariables	      "Ven=@1;Rex=@2;Rex0=@3;tsinc=@4;ke=@5;"
      MaskIconFrame	      on
      MaskIconOpaque	      on
      MaskIconRotate	      "none"
      MaskIconUnits	      "autoscale"
      MaskValueString	      "63.5|0.4233|4.2|1.1|2.294"
      System {
	Name			"Excitation control"
	Location		[389, 286, 614, 433]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Block {
	  BlockType		  Mux
	  Name			  "Mux"
	  Ports			  [2, 1]
	  Position		  [105, 48, 110, 117]
	  ShowName		  off
	  Inputs		  "2"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Step
	  Name			  "Rex"
	  Position		  [25, 95, 55, 125]
	  Time			  "tsinc"
	  Before		  "Rex0/ke^2"
	  After			  "Rex/ke^2"
	  SampleTime		  "0"
	}
	Block {
	  BlockType		  Step
	  Name			  "Vex"
	  Position		  [25, 25, 55, 55]
	  Time			  "tsinc"
	  After			  "Ven/ke"
	  SampleTime		  "0"
	}
	Block {
	  BlockType		  Outport
	  Name			  "VexRex"
	  Position		  [170, 78, 200, 92]
	}
	Line {
	  SrcBlock		  "Rex"
	  SrcPort		  1
	  Points		  [30, 0]
	  DstBlock		  "Mux"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "Vex"
	  SrcPort		  1
	  Points		  [30, 0]
	  DstBlock		  "Mux"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Mux"
	  SrcPort		  1
	  DstBlock		  "VexRex"
	  DstPort		  1
	}
      }
    }
    Block {
      BlockType		      Scope
      Name		      "Iabc (A)"
      Ports		      [1]
      Position		      [425, 114, 455, 146]
      Location		      [6, 60, 857, 582]
      Open		      on
      NumInputPorts	      "1"
      ZoomMode		      "xonly"
      List {
	ListType		AxesTitles
	axes1			"%<SignalLabel>"
      }
      List {
	ListType		SelectedSignals
	axes1			""
      }
      DataFormat	      "StructureWithTime"
    }
    Block {
      BlockType		      Scope
      Name		      "Ie (A)"
      Ports		      [1]
      Position		      [430, 179, 460, 211]
      Location		      [135, 313, 988, 755]
      Open		      on
      NumInputPorts	      "1"
      ZoomMode		      "yonly"
      List {
	ListType		AxesTitles
	axes1			"%<SignalLabel>"
      }
      List {
	ListType		SelectedSignals
	axes1			""
      }
      SaveName		      "ScopeData1"
      DataFormat	      "StructureWithTime"
    }
    Block {
      BlockType		      Step
      Name		      "Load"
      Position		      [50, 245, 80, 275]
      Time		      "4"
      Before		      "1000"
      After		      "20000"
      SampleTime	      "0"
    }
    Block {
      BlockType		      SubSystem
      Name		      "MS"
      Ports		      [3, 3]
      Position		      [200, 95, 335, 295]
      TreatAsAtomicUnit	      off
      MaskPromptString	      "Poles pairs|Rs|Ldm|Lqm|Lssig|LD|LQ|LEsig|LED|RD"
"|RQ|Jr|ke"
      MaskStyleString	      "edit,edit,edit,edit,edit,edit,edit,edit,edit,ed"
"it,edit,edit,edit"
      MaskTunableValueString  "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"
      MaskVisibilityString    "on,on,on,on,on,on,on,on,on,on,on,on,on"
      MaskToolTipString	      "on,on,on,on,on,on,on,on,on,on,on,on,on"
      MaskVarAliasString      ",,,,,,,,,,,,"
      MaskVariables	      "p=@1;Rs=@2;Ldm=@3;Lqm=@4;Lssig=@5;LD=@6;LQ=@7;L"
"Esig=@8;LED=@9;RD=@10;RQ=@11;Jr=@12;ke=@13;"
      MaskInitialization      "LEDr=LED/ke; LEsigr=LEsig/(ke^2);\nLd=Ldm+[Lssi"
"g 0 0; 0 LD+LEDr LEDr; 0 LEDr LEDr+LEsigr]; kd=inv(Ld);\nLq=Lqm+[Lssig 0; 0 L"
"Q]; kq=inv(Lq);\nk=zeros(8,6); k(1,1)=1; k(2,4)=1; k(3,6)=p; k(4:6,1:3)=kd; k"
"(7:8,4:5)=kq;\nkp1=sqrt(2/3); kp2=1/sqrt(6); kp3=1/sqrt(2);"
      MaskIconFrame	      on
      MaskIconOpaque	      on
      MaskIconRotate	      "none"
      MaskIconUnits	      "autoscale"
      MaskValueString	      "8|0.5|0.09|0.09|0.011|0.011|0.011|0.05|0.002|1|"
"1|56.095|2.294"
      System {
	Name			"MS"
	Location		[-1, 104, 1011, 766]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Block {
	  BlockType		  Inport
	  Name			  "Vabc"
	  Position		  [25, 58, 55, 72]
	}
	Block {
	  BlockType		  Inport
	  Name			  "Ex"
	  Position		  [25, 343, 55, 357]
	  Port			  "2"
	}
	Block {
	  BlockType		  Inport
	  Name			  "Tload"
	  Position		  [25, 398, 55, 412]
	  Port			  "3"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn"
	  Position		  [190, 195, 355, 225]
	  Expr			  "u(1)-Rs*u(9)+u(8)*u(7)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn1"
	  Position		  [190, 250, 355, 280]
	  Expr			  "-RD*u(10)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn10"
	  Position		  [285, 85, 380, 115]
	  Expr			  "u(2)*u(3)-u(1)*u(4)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn11"
	  Position		  [655, 467, 745, 493]
	  Expr			  "u(4)*u(9)-u(7)*u(10)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn12"
	  Position		  [655, 527, 750, 553]
	  Expr			  "u(4)*u(10)+u(7)*u(9)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn13"
	  Position		  [805, 451, 890, 479]
	  Expr			  "kp1*u(1)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn14"
	  Position		  [805, 496, 890, 524]
	  Expr			  "kp3*u(2)-kp2*u(1)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn15"
	  Position		  [805, 541, 890, 569]
	  Expr			  "-kp2*u(1)-kp3*u(2)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn16"
	  Position		  [660, 271, 745, 299]
	  Expr			  "u(6)/ke"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn17"
	  Position		  [660, 336, 745, 364]
	  Expr			  "30*u(3)/(p*pi)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn2"
	  Position		  [195, 305, 330, 335]
	  Expr			  "u(3)-u(4)*u(11)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn3"
	  Position		  [195, 360, 360, 390]
	  Expr			  "u(2)-Rs*u(12)-u(8)*u(6)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn4"
	  Position		  [195, 415, 345, 445]
	  Expr			  "-RQ*u(13)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn5"
	  Position		  [195, 470, 360, 500]
	  Expr			  "(p*(u(6)*u(12)-u(7)*u(9))-u(5))/Jr"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn6"
	  Position		  [195, 524, 360, 556]
	  Expr			  "u(8)"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn7"
	  Position		  [90, 19, 205, 51]
	  Expr			  "kp1*u(1)-kp2*(u(2)+u(3))"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn8"
	  Position		  [90, 64, 205, 96]
	  Expr			  "kp3*(u(2)-u(3))"
	}
	Block {
	  BlockType		  Fcn
	  Name			  "Fcn9"
	  Position		  [285, 40, 380, 70]
	  Expr			  "u(1)*u(3)+u(2)*u(4)"
	}
	Block {
	  BlockType		  Integrator
	  Name			  "Integrator"
	  Ports			  [1, 1]
	  Position		  [425, 335, 455, 365]
	}
	Block {
	  BlockType		  Integrator
	  Name			  "Integrator1"
	  Ports			  [1, 1]
	  Position		  [425, 525, 455, 555]
	}
	Block {
	  BlockType		  Gain
	  Name			  "Matrix\nGain"
	  Position		  [490, 335, 520, 365]
	  Gain			  "k"
	  Multiplication	  "Matrix(K*u)"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux"
	  Ports			  [5, 1]
	  Position		  [135, 216, 140, 484]
	  ShowName		  off
	  Inputs		  "5"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux1"
	  Ports			  [6, 1]
	  Position		  [395, 181, 400, 514]
	  ShowName		  off
	  Inputs		  "6"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux2"
	  Ports			  [2, 1]
	  Position		  [550, 473, 555, 597]
	  ShowName		  off
	  Inputs		  "2"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux3"
	  Ports			  [3, 1]
	  Position		  [240, 25, 245, 135]
	  ShowName		  off
	  Inputs		  "3"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux4"
	  Ports			  [2, 1]
	  Position		  [610, 443, 615, 567]
	  ShowName		  off
	  Inputs		  "2"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux5"
	  Ports			  [2, 1]
	  Position		  [765, 448, 770, 572]
	  ShowName		  off
	  Inputs		  "2"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Mux
	  Name			  "Mux6"
	  Ports			  [3, 1]
	  Position		  [915, 440, 920, 580]
	  ShowName		  off
	  Inputs		  "3"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Trigonometry
	  Name			  "Trigonometric\nFunction"
	  Ports			  [1, 1]
	  Position		  [495, 550, 525, 580]
	}
	Block {
	  BlockType		  Trigonometry
	  Name			  "Trigonometric\nFunction1"
	  Ports			  [1, 1]
	  Position		  [495, 490, 525, 520]
	  Operator		  "cos"
	}
	Block {
	  BlockType		  Scope
	  Name			  "Vd"
	  Ports			  [1]
	  Position		  [470, 59, 500, 91]
	  Location		  [518, 207, 842, 446]
	  Open			  off
	  NumInputPorts		  "1"
	  ZoomMode		  "xonly"
	  List {
	    ListType		    AxesTitles
	    axes1		    "%<SignalLabel>"
	  }
	  List {
	    ListType		    SelectedSignals
	    axes1		    ""
	  }
	  DataFormat		  "StructureWithTime"
	}
	Block {
	  BlockType		  Scope
	  Name			  "Vq"
	  Ports			  [1]
	  Position		  [480, 124, 510, 156]
	  Location		  [188, 365, 512, 604]
	  Open			  off
	  NumInputPorts		  "1"
	  ZoomMode		  "xonly"
	  List {
	    ListType		    AxesTitles
	    axes1		    "%<SignalLabel>"
	  }
	  List {
	    ListType		    SelectedSignals
	    axes1		    ""
	  }
	  DataFormat		  "StructureWithTime"
	}
	Block {
	  BlockType		  Outport
	  Name			  "Iabc"
	  Position		  [950, 503, 980, 517]
	}
	Block {
	  BlockType		  Outport
	  Name			  "Ie"
	  Position		  [775, 278, 805, 292]
	  Port			  "2"
	}
	Block {
	  BlockType		  Outport
	  Name			  "wmec"
	  Position		  [780, 343, 810, 357]
	  Port			  "3"
	}
	Line {
	  SrcBlock		  "Mux"
	  SrcPort		  1
	  Points		  [10, 0]
	  Branch {
	    Points		    [0, 25]
	    Branch {
	      Points		      [0, 55]
	      Branch {
		DstBlock		"Fcn4"
		DstPort			1
	      }
	      Branch {
		Points			[0, 55]
		Branch {
		  DstBlock		  "Fcn5"
		  DstPort		  1
		}
		Branch {
		  Points		  [0, 55]
		  DstBlock		  "Fcn6"
		  DstPort		  1
		}
	      }
	    }
	    Branch {
	      DstBlock		      "Fcn3"
	      DstPort		      1
	    }
	  }
	  Branch {
	    Points		    [0, -30]
	    Branch {
	      Points		      [0, -55]
	      Branch {
		Points			[0, -55]
		DstBlock		"Fcn"
		DstPort			1
	      }
	      Branch {
		DstBlock		"Fcn1"
		DstPort			1
	      }
	    }
	    Branch {
	      DstBlock		      "Fcn2"
	      DstPort		      1
	    }
	  }
	}
	Line {
	  SrcBlock		  "Ex"
	  SrcPort		  1
	  DstBlock		  "Mux"
	  DstPort		  3
	}
	Line {
	  SrcBlock		  "Fcn"
	  SrcPort		  1
	  DstBlock		  "Mux1"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Fcn1"
	  SrcPort		  1
	  DstBlock		  "Mux1"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "Fcn2"
	  SrcPort		  1
	  DstBlock		  "Mux1"
	  DstPort		  3
	}
	Line {
	  SrcBlock		  "Fcn3"
	  SrcPort		  1
	  DstBlock		  "Mux1"
	  DstPort		  4
	}
	Line {
	  SrcBlock		  "Fcn4"
	  SrcPort		  1
	  DstBlock		  "Mux1"
	  DstPort		  5
	}
	Line {
	  SrcBlock		  "Mux1"
	  SrcPort		  1
	  DstBlock		  "Integrator"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Integrator1"
	  SrcPort		  1
	  Points		  [10, 0]
	  Branch {
	    Points		    [0, 25]
	    DstBlock		    "Trigonometric\nFunction"
	    DstPort		    1
	  }
	  Branch {
	    Points		    [0, -35]
	    DstBlock		    "Trigonometric\nFunction1"
	    DstPort		    1
	  }
	}
	Line {
	  SrcBlock		  "Trigonometric\nFunction1"
	  SrcPort		  1
	  DstBlock		  "Mux2"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Trigonometric\nFunction"
	  SrcPort		  1
	  DstBlock		  "Mux2"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "Mux2"
	  SrcPort		  1
	  Points		  [25, 0]
	  Branch {
	    DstBlock		    "Mux4"
	    DstPort		    2
	  }
	  Branch {
	    Points		    [0, 115; -505, 0; 0, -535]
	    DstBlock		    "Mux3"
	    DstPort		    3
	  }
	}
	Line {
	  SrcBlock		  "Fcn11"
	  SrcPort		  1
	  DstBlock		  "Mux5"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Fcn12"
	  SrcPort		  1
	  DstBlock		  "Mux5"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "Mux5"
	  SrcPort		  1
	  Points		  [5, 0]
	  Branch {
	    DstBlock		    "Fcn14"
	    DstPort		    1
	  }
	  Branch {
	    Points		    [0, 45]
	    DstBlock		    "Fcn15"
	    DstPort		    1
	  }
	  Branch {
	    Points		    [0, -45]
	    DstBlock		    "Fcn13"
	    DstPort		    1
	  }
	}
	Line {
	  SrcBlock		  "Fcn13"
	  SrcPort		  1
	  DstBlock		  "Mux6"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Fcn14"
	  SrcPort		  1
	  DstBlock		  "Mux6"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "Fcn15"
	  SrcPort		  1
	  DstBlock		  "Mux6"
	  DstPort		  3
	}
	Line {
	  SrcBlock		  "Mux6"
	  SrcPort		  1
	  DstBlock		  "Iabc"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Tload"
	  SrcPort		  1
	  DstBlock		  "Mux"
	  DstPort		  4
	}
	Line {
	  SrcBlock		  "Vabc"
	  SrcPort		  1
	  Points		  [5, 0]
	  Branch {
	    Points		    [0, -30]
	    DstBlock		    "Fcn7"
	    DstPort		    1
	  }
	  Branch {
	    Points		    [0, 15]
	    DstBlock		    "Fcn8"
	    DstPort		    1
	  }
	}
	Line {
	  SrcBlock		  "Fcn7"
	  SrcPort		  1
	  Points		  [15, 0]
	  DstBlock		  "Mux3"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Fcn8"
	  SrcPort		  1
	  DstBlock		  "Mux3"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "Fcn10"
	  SrcPort		  1
	  Points		  [5, 0; 0, 40]
	  Branch {
	    Points		    [0, 15; -285, 0; 0, 140]
	    DstBlock		    "Mux"
	    DstPort		    2
	  }
	  Branch {
	    DstBlock		    "Vq"
	    DstPort		    1
	  }
	}
	Line {
	  SrcBlock		  "Fcn9"
	  SrcPort		  1
	  Points		  [25, 0; 0, 20]
	  Branch {
	    DstBlock		    "Vd"
	    DstPort		    1
	  }
	  Branch {
	    Points		    [0, 95; -290, 0]
	    DstBlock		    "Mux"
	    DstPort		    1
	  }
	}
	Line {
	  SrcBlock		  "Fcn6"
	  SrcPort		  1
	  DstBlock		  "Integrator1"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Fcn5"
	  SrcPort		  1
	  DstBlock		  "Mux1"
	  DstPort		  6
	}
	Line {
	  SrcBlock		  "Mux4"
	  SrcPort		  1
	  Points		  [15, 0]
	  Branch {
	    Points		    [0, -25]
	    DstBlock		    "Fcn11"
	    DstPort		    1
	  }
	  Branch {
	    Points		    [0, 35]
	    DstBlock		    "Fcn12"
	    DstPort		    1
	  }
	}
	Line {
	  SrcBlock		  "Mux3"
	  SrcPort		  1
	  Points		  [20, 0]
	  Branch {
	    DstBlock		    "Fcn9"
	    DstPort		    1
	  }
	  Branch {
	    DstBlock		    "Fcn10"
	    DstPort		    1
	  }
	}
	Line {
	  SrcBlock		  "Integrator"
	  SrcPort		  1
	  DstBlock		  "Matrix\nGain"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Matrix\nGain"
	  SrcPort		  1
	  Points		  [45, 0]
	  Branch {
	    Points		    [0, 125]
	    Branch {
	      DstBlock		      "Mux4"
	      DstPort		      1
	    }
	    Branch {
	      Points		      [0, 135; -460, 0; 0, -150]
	      DstBlock		      "Mux"
	      DstPort		      5
	    }
	  }
	  Branch {
	    Points		    [0, -65]
	    DstBlock		    "Fcn16"
	    DstPort		    1
	  }
	  Branch {
	    DstBlock		    "Fcn17"
	    DstPort		    1
	  }
	}
	Line {
	  SrcBlock		  "Fcn16"
	  SrcPort		  1
	  DstBlock		  "Ie"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Fcn17"
	  SrcPort		  1
	  DstBlock		  "wmec"
	  DstPort		  1
	}
	Annotation {
	  Name			  "Inverse Park "
	  Position		  [772, 624]
	}
	Annotation {
	  Name			  "Direct Park"
	  Position		  [229, 143]
	}
	Annotation {
	  Name			  "dq model of MS"
	  Position		  [274, 587]
	}
      }
    }
    Block {
      BlockType		      SubSystem
      Name		      "Stator voltage"
      Ports		      [0, 1]
      Position		      [35, 51, 95, 109]
      TreatAsAtomicUnit	      off
      MaskPromptString	      "V1 (V) -line rms voltage|f1 (Hz)|Winding conexi"
"on ('y' or 'd')"
      MaskStyleString	      "edit,edit,edit"
      MaskTunableValueString  "on,on,on"
      MaskCallbackString      "||"
      MaskEnableString	      "on,on,on"
      MaskVisibilityString    "on,on,on"
      MaskToolTipString	      "on,on,on"
      MaskVarAliasString      ",,"
      MaskVariables	      "Vn=@1;fn=@2;conex=@3;"
      MaskInitialization      "if strcmp(lower(conex),'y')\nVm=Vn*sqrt(2/3);\n"
"else\nVm=Vn*sqrt(2);\nend\nwn=2*pi*fn;"
      MaskIconFrame	      on
      MaskIconOpaque	      on
      MaskIconRotate	      "none"
      MaskIconUnits	      "autoscale"
      MaskValueString	      "6000|50|'y'"
      System {
	Name			"Stator voltage"
	Location		[361, 122, 610, 364]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Block {
	  BlockType		  Mux
	  Name			  "Mux"
	  Ports			  [3, 1]
	  Position		  [100, 59, 105, 151]
	  ShowName		  off
	  Inputs		  "3"
	  DisplayOption		  "bar"
	}
	Block {
	  BlockType		  Sin
	  Name			  "Sine Wave"
	  Position		  [25, 25, 55, 55]
	  SineType		  "Time based"
	  Amplitude		  "Vm"
	  Frequency		  "wn"
	  SampleTime		  "0"
	}
	Block {
	  BlockType		  Sin
	  Name			  "Sine Wave1"
	  Position		  [25, 90, 55, 120]
	  SineType		  "Time based"
	  Amplitude		  "Vm"
	  Frequency		  "wn"
	  Phase			  "-2*pi/3"
	  SampleTime		  "0"
	}
	Block {
	  BlockType		  Sin
	  Name			  "Sine Wave2"
	  Position		  [25, 160, 55, 190]
	  SineType		  "Time based"
	  Amplitude		  "Vm"
	  Frequency		  "wn"
	  Phase			  "2*pi/3"
	  SampleTime		  "0"
	}
	Block {
	  BlockType		  Outport
	  Name			  "Vabc"
	  Position		  [130, 98, 160, 112]
	}
	Line {
	  SrcBlock		  "Sine Wave1"
	  SrcPort		  1
	  DstBlock		  "Mux"
	  DstPort		  2
	}
	Line {
	  SrcBlock		  "Sine Wave2"
	  SrcPort		  1
	  Points		  [15, -40]
	  DstBlock		  "Mux"
	  DstPort		  3
	}
	Line {
	  SrcBlock		  "Sine Wave"
	  SrcPort		  1
	  Points		  [25, 0]
	  DstBlock		  "Mux"
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "Mux"
	  SrcPort		  1
	  DstBlock		  "Vabc"
	  DstPort		  1
	}
      }
    }
    Block {
      BlockType		      Scope
      Name		      "Vabc"
      Ports		      [1]
      Position		      [215, 24, 245, 56]
      Location		      [188, 365, 512, 604]
      Open		      on
      NumInputPorts	      "1"
      ZoomMode		      "xonly"
      List {
	ListType		AxesTitles
	axes1			"%<SignalLabel>"
      }
      List {
	ListType		SelectedSignals
	axes1			""
      }
      TimeRange		      "4"
      DataFormat	      "StructureWithTime"
    }
    Block {
      BlockType		      Scope
      Name		      "w_mec (rpm)"
      Ports		      [1]
      Position		      [430, 244, 460, 276]
      Location		      [65, 109, 920, 631]
      Open		      off
      NumInputPorts	      "1"
      ZoomMode		      "yonly"
      List {
	ListType		AxesTitles
	axes1			"%<SignalLabel>"
      }
      List {
	ListType		SelectedSignals
	axes1			""
      }
      SaveName		      "ScopeData2"
      DataFormat	      "StructureWithTime"
    }
    Line {
      SrcBlock		      "MS"
      SrcPort		      1
      DstBlock		      "Iabc (A)"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Excitation control"
      SrcPort		      1
      DstBlock		      "MS"
      DstPort		      2
    }
    Line {
      SrcBlock		      "Load"
      SrcPort		      1
      DstBlock		      "MS"
      DstPort		      3
    }
    Line {
      SrcBlock		      "Stator voltage"
      SrcPort		      1
      Points		      [0, 0; 55, 0]
      Branch {
	Points			[0, 50]
	DstBlock		"MS"
	DstPort			1
      }
      Branch {
	Points			[0, -40]
	DstBlock		"Vabc"
	DstPort			1
      }
    }
    Line {
      SrcBlock		      "MS"
      SrcPort		      2
      DstBlock		      "Ie (A)"
      DstPort		      1
    }
    Line {
      SrcBlock		      "MS"
      SrcPort		      3
      DstBlock		      "w_mec (rpm)"
      DstPort		      1
    }
  }
}
