You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
42 lines
1.7 KiB
42 lines
1.7 KiB
// CP: 65001 |
|
// SimulationX Version: 3.8.2.45319 x64 |
|
within AIDAModelica; |
|
model XAngularSpeedErrorModel "X angular speed error calculation model" |
|
Modelica.Blocks.Interfaces.RealInput RollConsign( |
|
quantity="Mechanics.Rotation.Angle", |
|
displayUnit="rad") "'input Real' as connector" annotation(Placement( |
|
transformation(extent={{-20,-20},{20,20}}), |
|
iconTransformation(extent={{-120,30},{-80,70}}))); |
|
Modelica.Blocks.Interfaces.RealInput Roll( |
|
quantity="Mechanics.Rotation.Angle", |
|
displayUnit="rad") "'input Real' as connector" annotation(Placement( |
|
transformation(extent={{-20,-20},{20,20}}), |
|
iconTransformation(extent={{-120,-20},{-80,20}}))); |
|
Modelica.Blocks.Interfaces.RealInput AngularSpeedX( |
|
quantity="Mechanics.Rotation.RotVelocity", |
|
displayUnit="rad/s") "'input Real' as connector" annotation(Placement( |
|
transformation(extent={{-20,-20},{20,20}}), |
|
iconTransformation(extent={{-120,-70},{-80,-30}}))); |
|
Modelica.Blocks.Interfaces.RealOutput AngularSpeedXError( |
|
quantity="Mechanics.Rotation.RotVelocity", |
|
displayUnit="rad/s") "'output Real' as connector" annotation(Placement( |
|
transformation(extent={{-10,-10},{10,10}}), |
|
iconTransformation(extent={{86.7,-10},{106.7,10}}))); |
|
parameter Real Kwphi=1.5 "Proportional gain Kwphi"; |
|
Real ephi( |
|
quantity="Mechanics.Rotation.Angle", |
|
displayUnit="rad") "Phi error"; |
|
Real wxd( |
|
quantity="Mechanics.Rotation.RotVelocity", |
|
displayUnit="rad/s") "Desired angular speed X"; |
|
equation |
|
// enter your equations here |
|
ephi = Roll-RollConsign; |
|
wxd = -Kwphi*ephi; |
|
AngularSpeedXError = wxd-AngularSpeedX ; |
|
annotation(Icon(graphics={ |
|
Rectangle( |
|
fillColor={255,255,255}, |
|
fillPattern=FillPattern.Solid, |
|
extent={{-100,100},{100,-100}})})); |
|
end XAngularSpeedErrorModel;
|
|
|