<?xml version="1.0" encoding="ISO-8859-1"?>

<!-- Rutan Boomerang : 2009 BARANGER Emmanuel 
             Updated : 2016 BARANGER Emmanuel

     source       : http://en.wikipedia.org/wiki/Scaled_Composites_Boomerang

     Envergure    : 11.19 m    (36.70 ft)
     Longueur     :  9.34 m    (30.60 ft)
     Hauteur      :  2.60 m    ( 8.56 ft)
     Empty weight :       kg   ( 2370 lbs)
     Speed Max    :       km/h (  264 kts)
     Speed cruise :       km/h (  210 kts)
     Moteur       : Lycoming TIO-360C1A6D, 210 hp
                  : Lycoming TIO-360A1B, 200 hp
-->
<airplane mass="2370" version="YASIM_VERSION_CURRENT">

  <approach speed="68" aoa="2" fuel="0.2">
    <control-setting axis="/controls/engines/engine[0]/throttle" value="0.2"/>
    <control-setting axis="/controls/engines/engine[0]/mixture" value="1"/>
    <control-setting axis="/controls/engines/engine[0]/propeller-pitch" value="0.5"/>
    <control-setting axis="/controls/engines/engine[1]/throttle" value="0.2"/>
    <control-setting axis="/controls/engines/engine[1]/mixture" value="1"/>
    <control-setting axis="/controls/engines/engine[1]/propeller-pitch" value="0.5"/>
    <control-setting axis="/controls/gear/gear-down" value="1"/>
  </approach>
  
  <cruise speed="210" alt="19000" fuel="0.8"> 
    <control-setting axis="/controls/engines/engine[0]/throttle" value="0.8"/>
    <control-setting axis="/controls/engines/engine[0]/mixture" value="0.9"/>
    <control-setting axis="/controls/engines/engine[0]/propeller-pitch" value="0.5"/>
    <control-setting axis="/controls/engines/engine[1]/throttle" value="0.8"/>
    <control-setting axis="/controls/engines/engine[1]/mixture" value="0.9"/>
    <control-setting axis="/controls/engines/engine[1]/propeller-pitch" value="0.5"/>
    <control-setting axis="/controls/flight/elevator-trim" value="0"/>
    <control-setting axis="/controls/gear/gear-down" value="0"/>
  </cruise>

  <cockpit x="1.8" y="0.997" z="0.234"/>

  <!-- fuselage -->
  <fuselage ax=" 3.974" ay="-0.725" az="-0.296" bx=" 2.677" by="-0.725" bz="-0.385" width="1.130" taper="0.7" midpoint="1"/>
  <fuselage ax=" 2.777" ay="-0.725" az="-0.385" bx=" 1.838" by="-0.725" bz="-0.260" width="1.339" taper="0.8" midpoint="1"/>
  <fuselage ax=" 1.920" ay="-0.725" az="-0.260" bx=" 0.289" by="-0.725" bz="-0.260" width="1.339" taper="1.0" midpoint="1"/>
  <fuselage ax=" 0.302" ay="-0.725" az="-0.260" bx="-4.658" by="-0.725" bz="-0.122" width="1.339" taper="0.2" midpoint="0"/>
  
  <!-- fuselage 2 (engine) -->
  <fuselage ax=" 2.480"  ay="1.512" az="-0.296" bx=" 2.092" by=" 1.512" bz="-0.296" width="1.000" taper="0.7" midpoint="1"/>
  <fuselage ax=" 2.092"  ay="1.512" az="-0.296" bx="-4.575" by=" 1.512" bz="-0.108" width="1.000" taper="0.2" midpoint="0"/>

  <wing x="0.892" y="0" z="-0.222"
        chord="1.102"
        length="5.636"
        taper="0.4"
        dihedral="4"
        sweep="-8"
        camber="0.005">
        <stall aoa="20" width="1" peak="1.5"/>
        <flap0 start="0.34" end="0.88" lift="1.2" drag="1.1"/>
        
        <control-input  control="FLAP0" split="true" axis="/controls/flight/aileron"/>
        <control-input  control="FLAP0" split="true" axis="/controls/flight/aileron-trim"/>

        <control-output control="FLAP0" prop="/surface-positions/left-aileron-pos-norm" side="left"/>
        <control-output control="FLAP0" prop="/surface-positions/right-aileron-pos-norm" side="right"/>
  </wing>

  <hstab x="-4.132" y="0" z="-0.123"
         chord="0.741"
         length="1.510"
         taper="1">
         <stall aoa="16" width="1" peak="1.5" />
         <flap0 start="0" end="1" lift="1.2" drag="1.1"/>

         <control-input  control="FLAP0" axis="/controls/flight/elevator"/>
         <control-input  control="FLAP0" axis="/controls/flight/elevator-trim"/>

         <control-output control="FLAP0" prop="/surface-positions/elevator-pos-norm"/>
  </hstab>

  <vstab x="-3.742" y="1.512" z="-0.085"
         chord="1.036"
         length="1.455"
         sweep="12"
         taper="0.42">
         <stall aoa="16" width="1" peak="1.5"/>
         <flap0 start="0" end="1" lift="1.2" drag="1.1"/>

         <control-input  control="FLAP0" axis="/controls/flight/rudder" invert="true"/>
         <control-input  control="FLAP0" axis="/controls/flight/rudder-trim" invert="true"/>

         <control-output control="FLAP0" prop="/surface-positions/rudder-pos-norm"/>
  </vstab>

  <vstab x="-3.742" y="-0.725" z="-0.085"
         chord="1.036"
         length="1.455"
         sweep="12"
         taper="0.42">
         <stall aoa="16" width="1" peak="1.5"/>
         <flap0 start="0" end="1" lift="1.2" drag="1.1"/>

         <control-input  control="FLAP0" axis="/controls/flight/rudder" invert="true"/>
         <control-input  control="FLAP0" axis="/controls/flight/rudder-trim" invert="true"/>

         <control-output control="FLAP0" prop="/surface-positions/rudder-pos-norm"/>
  </vstab>

  <!-- Engines   source            : http://en.wikipedia.org/wiki/Lycoming_O-360

                 name              : Lycoming O-360
                 type              : 4-cylinder air-cooled horizontally opposed aircraft piston engine
                 power cruise      : 210 hp at 2700 rpm at sea level
                 weight            : 301 lb (137 kg)
                 Displacement      : 361 in3 (5.9 L)
                 Compression       : 8.5:1
                 Propeller diameter: 1.9 m

      Lycoming TIO-360C1A6D, 210 hp
  -->
  <propeller x="3.192" y="-0.725" z="-0.181"
             mass="301"
             moment="2"
             radius="0.95"
             cruise-speed="210"
             cruise-rpm="2000"
             cruise-power="200"
             cruise-alt="5500">
             <actionpt x="4.159" y="-0.725" z="-0.296"/>
             <control-input axis="/controls/engines/engine[0]/propeller-pitch" control="ADVANCE"/>
             <piston-engine eng-power="210"
                            eng-rpm="2700"
                            alt="5000"
                            displacement="361"
                            compression="8.5">
                            <control-input axis="/controls/engines/engine[0]/throttle" control="THROTTLE"/>
                            <control-input axis="/controls/engines/engine[0]/starter" control="STARTER"/>
                            <control-input axis="/controls/engines/engine[0]/magnetos" control="MAGNETOS"/>
                            <control-input axis="/controls/engines/engine[0]/mixture" control="MIXTURE"/>
             </piston-engine>
  </propeller>

  <!-- Lycoming TIO-360A1B, 200 hp -->
  <propeller x="1.928" y="1.512" z="-0.298"
             mass="301"
             moment="2"
             radius="0.95"
             cruise-speed="210"
             cruise-rpm="2000"
             cruise-power="175"
             cruise-alt="5500">
             <actionpt x="2.701" y="1.512" z="-0.296"/>
             <control-input axis="/controls/engines/engine[1]/propeller-pitch" control="ADVANCE"/>
             <piston-engine eng-power="200"
                            eng-rpm="2700"
                            alt="5000"
                            displacement="361"
                            compression="8.5">
                            <control-input axis="/controls/engines/engine[1]/throttle" control="THROTTLE"/>
                            <control-input axis="/controls/engines/engine[1]/starter" control="STARTER"/>
                            <control-input axis="/controls/engines/engine[1]/magnetos" control="MAGNETOS"/>
                            <control-input axis="/controls/engines/engine[1]/mixture" control="MIXTURE"/>
             </piston-engine>
  </propeller>

  <!-- nose -->
  <gear x="3.11344" y="-0.495" z="-1.31916"
        compression="0.15" 
        spring="0.8"
        on-solid="1"
        sfric="1"
        dfric="1">
        <control-input  control="STEER"  axis="/controls/flight/rudder" square="true" src0="-1.0" src1="1.0" dst0="-0.8" dst1="0.8"/>
        <control-input  control="EXTEND" axis="/controls/gear/gear-down"/>

        <control-speed  control="EXTEND" transition-time="5"/>

        <control-output control="EXTEND" prop="/gear/gear[0]/position-norm"/>
  </gear>

  <!-- left main -->
  <gear x="0.84974" y="1.512" z="-1.29157"
        compression="0.2" 
        spring="1.8" 
        damp="0.03" 
        on-solid="1" >
        <control-input  control="BRAKE"  axis="/controls/gear/brake-left"/>
        <control-input  control="BRAKE"  axis="/controls/gear/brake-parking"/>
        <control-input  control="EXTEND" axis="/controls/gear/gear-down"/>
        
        <control-speed  control="EXTEND" transition-time="5"/>
        
        <control-output control="EXTEND" prop="/gear/gear[1]/position-norm"/>
  </gear>

  <!-- right main -->
  <gear x="0.79180" y="-0.725" z="-1.29157"
        compression="0.2" 
        spring="1.8" 
        damp="0.03" 
        on-solid="1" >
        <control-input  control="BRAKE"  axis="/controls/gear/brake-left"/>
        <control-input  control="BRAKE"  axis="/controls/gear/brake-parking"/>
        <control-input  control="EXTEND" axis="/controls/gear/gear-down"/>

        <control-speed  control="EXTEND" transition-time="5"/>
        
        <control-output control="EXTEND" prop="/gear/gear[2]/position-norm"/>
  </gear>

  <!-- Fuel -->
  <tank x="1.15" y=" 2.5" z="-0.2" capacity="503"/>
  <tank x="1.15" y="-2.5" z="-0.2" capacity="503"/>

  <!-- Mass displacement -->
  <ballast x="3.5" y="-0.79" z="-0.61" mass="250"/>

</airplane>
