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

<!-- Ryan Navion - 2010 Emmanuel BARANGER
                 - Updated    2013   January Helijah
                 - Updated    2014 September Helijah
                 - Updated    2019 September Helijah
                 - Updated 08/2020 September Helijah
                 - Updated 08/2024 September Helijah

     sources          : http://en.wikipedia.org/wiki/Ryan_Navion

     wingspan         :  10.17 m     ( 33.38 ft )
     length           :   8.30 m     ( 27.25 ft )
     height           :   2.60 m     (  8.53 ft )
     empty weight     :   875 kg     (  1930 lb )
     Gross weight     :  1358 kg     (  2995 lb )
     engine           : Lycoming GO-435-C2 air-cooled flat-six engine ( 260 hp take-off power)
     Max speed        :   280 km/h   (   151 kn )
     Cruise speed     :   270 km/h   (   145 kn )
     Fuel capacity    :    40 US gal (   150 L  )
-->
<airplane mass="1930" version="YASIM_VERSION_CURRENT" mtow-lbs="2995">

  <!-- Approach configuration -->
  <approach speed="50" 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/flight/flaps"               value="1"/>
    <control-setting axis="/controls/flight/elevator"            value="0"/>
    <solve-weight    idx="0" weight="240"/>
    <solve-weight    idx="1" weight="240"/>
    <solve-weight    idx="2" weight="120"/>
    <solve-weight    idx="3" weight="0"/>
  </approach>

  <!-- Cruise configuration -->
  <cruise speed="145" alt="6000" fuel="0.7">
    <control-setting axis="/controls/engines/engine[0]/throttle" value="0.7"/>
    <control-setting axis="/controls/engines/engine[0]/mixture"  value="1.0"/>
    <control-setting axis="/controls/flight/flaps"               value="0"/>
    <control-setting axis="/controls/flight/elevator-trim"       value="-0.05"/>
    <solve-weight    idx="0" weight="240"/>
    <solve-weight    idx="1" weight="240"/>
    <solve-weight    idx="2" weight="120"/>
    <solve-weight    idx="3" weight="0"/>
  </cruise>

  <cockpit x="1.432" y="0.272" z="0.5567"/>

  <fuselage ax=" 4.378" ay=" 0.000" az="-0.056" bx=" 4.272" by=" 0.000" bz="-0.056" width="0.172" taper="0.00" midpoint="1"/>
  <fuselage ax=" 4.272" ay=" 0.000" az="-0.056" bx=" 4.124" by=" 0.000" bz="-0.056" width="0.299" taper="0.58" midpoint="1"/>
  <fuselage ax=" 4.124" ay=" 0.000" az="-0.056" bx=" 3.960" by=" 0.000" bz="-0.056" width="0.332" taper="0.90" midpoint="1"/>

  <fuselage ax=" 3.960" ay=" 0.077" az="-0.209" bx=" 3.574" by=" 0.078" bz="-0.209" width="0.790" taper="0.70" midpoint="1"/>
  <fuselage ax=" 3.574" ay=" 0.078" az="-0.209" bx=" 2.007" by=" 0.078" bz="-0.209" width="1.022" taper="0.77" midpoint="1"/>
  <fuselage ax=" 2.007" ay=" 0.078" az="-0.209" bx=" 0.571" by=" 0.078" bz="-0.209" width="1.022" taper="1.00" midpoint="1"/>
  <fuselage ax=" 0.571" ay=" 0.078" az="-0.209" bx="-4.137" by=" 0.000" bz="-0.039" width="1.022" taper="0.20" midpoint="0"/>

  <fuselage ax=" 3.960" ay="-0.077" az="-0.209" bx=" 3.574" by="-0.078" bz="-0.209" width="0.790" taper="0.70" midpoint="1"/>
  <fuselage ax=" 3.574" ay="-0.078" az="-0.209" bx=" 2.007" by="-0.078" bz="-0.209" width="1.022" taper="0.77" midpoint="1"/>
  <fuselage ax=" 2.007" ay="-0.078" az="-0.209" bx=" 0.571" by="-0.078" bz="-0.209" width="1.022" taper="1.00" midpoint="1"/>
  <fuselage ax=" 0.571" ay="-0.078" az="-0.209" bx="-4.137" by=" 0.000" bz="-0.039" width="1.022" taper="0.20" midpoint="0"/>

  <fuselage ax=" 3.960" ay=" 0.000" az="-0.209" bx=" 2.007" by=" 0.000" bz="-0.043" width="1.022" taper="0.60" midpoint="1"/>
  <fuselage ax=" 2.007" ay=" 0.000" az="-0.043" bx=" 0.571" by=" 0.000" bz="-0.043" width="1.022" taper="1.00" midpoint="1"/>
  <fuselage ax=" 0.571" ay=" 0.000" az="-0.043" bx="-4.137" by=" 0.000" bz="-0.039" width="1.022" taper="0.20" midpoint="0"/>

  <fuselage ax=" 2.207" ay=" 0.000" az="-0.012" bx=" 1.578" by=" 0.000" bz=" 0.206" width="1.147" taper="0.70" midpoint="1"/>
  <fuselage ax=" 1.762" ay=" 0.000" az=" 0.168" bx=" 0.531" by=" 0.000" bz=" 0.168" width="1.147" taper="1.00" midpoint="1"/>
  <fuselage ax=" 0.531" ay=" 0.000" az=" 0.168" bx="-0.236" by=" 0.000" bz=" 0.168" width="1.147" taper="0.40" midpoint="0"/>


  <wing x="1.145" y="0" z="-0.540"
        chord="2.094"
        length="5.037"
        taper="0.58"
        sweep="-2.7"
        dihedral="7"
        camber="0.05">
        <stall   aoa="20" width="1"    peak="1.5"/>
        <flap0 start="0.12" end="0.66" lift="1.2" drag="1.6"/>
        <flap1 start="0.66" end="0.97" lift="1.2" drag="1.2"/>

        <control-input  control="FLAP0" axis="/controls/flight/flaps"/>
        <control-input  control="FLAP1" axis="/controls/flight/aileron"      split="true"/>
        <control-input  control="FLAP1" axis="/controls/flight/aileron-trim" split="true"/>

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

        <control-speed  control="FLAP0" transition-time="4"/>
  </wing>

  <hstab x="-3" y="0" z="0.183"
         chord="1.184"
         length="1.826"
         taper="0.7"
         sweep="1">
         <stall   aoa="18" width="1" peak="1.5"/>
         <flap0 start="0"    end="1" lift="1.4" drag="1.2"/>

         <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.396" y="0" z="-0.149"
         chord="1.441"
         length="1.534"
         taper="0.4"
         sweep="6">
         <stall   aoa="16" width="1" peak="1.5"/>
         <flap0 start="0"    end="1" lift="1.4" drag="1.2"/>

         <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" min="1" max="-1"/>
  </vstab>

  <!-- Engines   source            : https://en.wikipedia.org/wiki/Lycoming_O-435

                 name              : Lycoming O-435
                 type              : Six-cylinder horizontally-opposed gasoline piston engine
                 power cruise      : 260 hp at 3000 rpm
                 weight            : 433 lb ( 196.6 kg )
                 displacement      : 434 cu in ( 7.1 L )
                 compression       : 7.5:1
       Propeller
                 name              : Hartzell HC-12X20-7
                 blades            : Hartzell L 8428 CR-2
                 type              : hyrdro-selective propeller
                 measurement       : 84 inches long / 8 inches wide
                 low pitch         : 10.0 deg
                 high pitch        : 14.0 deg
  -->
<propeller x="3.483" y="0" z="-0.057"
           mass="433"
           moment="6"
           radius="1.01"
           cruise-speed="145"
           cruise-alt="6000"
           cruise-rpm="2500"
           cruise-power="212"
           takeoff-rpm="3000"
           takeoff-power="260"
           manual-pitch="1">
           <actionpt x="4.045" y="0" z="-0.057"/>
           <control-input control="PROPPITCH" axis="/controls/engines/engine[0]/propeller-pitch" src0="0.0" src1="1.0" dst0="0.42" dst1="0.50"/>
           <piston-engine eng-rpm="3000"
                          eng-power="212"
                          displacement="434"
                          compression="7.5"
                          turbo-mul="1.65">
                          <control-input control="MAGNETOS" axis="/controls/engines/engine[0]/magnetos"/>
                          <control-input control="STARTER"  axis="/controls/engines/engine[0]/starter"/>
                          <control-input control="THROTTLE" axis="/controls/engines/engine[0]/throttle"/>
                          <control-input control="MIXTURE"  axis="/controls/engines/engine[0]/mixture"/>
                          <control-input control="BOOST"    axis="/engines/engine[0]/running"/>
           </piston-engine>
  </propeller>

  <!-- Noze wheel -->
  <gear x="3.093" y="0" z="-1.399"
        compression="0.0889"
        spring="0.3"
        damp="0.6"
        sfric="1"
        dfric="1"
        stiction="1">
        <control-input  control="STEER"  axis="/controls/flight/rudder" square="false" src0="-1" src1="1" dst0="-0.7" dst1="0.7"/>
        <control-input  control="EXTEND" axis="/controls/gear/gear-down"/>

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

        <control-speed  control="EXTEND" transition-time="7"/>
  </gear>

  <!-- Left wheel -->
  <gear x="1.487" y="1.336" z="-1.400"
        upx="-0.15643" upy="0.0" upz="0.98769"
        compression="0.1778"
        spring="1.0"
        damp="0.4"
        stiction="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-output control="EXTEND" prop="gear/gear[1]/position-norm"/>

        <control-speed  control="EXTEND" transition-time="7"/>
  </gear>

  <!-- Right wheel -->
  <gear x="1.487" y="-1.336" z="-1.400"
        upx="-0.15643" upy="0.0" upz="0.98769"
        compression="0.1778"
        spring="1.0"
        damp="0.4"
        stiction="1">
        <control-input  control="BRAKE"  axis="/controls/gear/brake-right"/>
        <control-input  control="BRAKE"  axis="/controls/gear/brake-parking"/>
        <control-input  control="EXTEND" axis="/controls/gear/gear-down"/>

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

        <control-speed  control="EXTEND" transition-time="7"/>
  </gear>

  <!-- Tail contact point -->
  <gear x="-4.03913" y="0" z="-0.13849"
        ignored-by-solver="1"
        compression="0.001"
        spring="0"
        damp="0">
  </gear>

  <tank x="1.78" y=" 1.8" z="-0.36" capacity="120"/>
  <tank x="0.46" y=" 0.0" z="-0.31" capacity="4.5"/>
  <tank x="1.78" y="-1.8" z="-0.36" capacity="120"/>

  <weight x=" 1.42" y=" 0.272" z=" 0.0" mass-prop="/sim/weight[0]/weight-lb"/> <!-- Pilot -->
  <weight x=" 1.42" y="-0.272" z=" 0.0" mass-prop="/sim/weight[1]/weight-lb"/> <!-- FO -->
  <weight x=" 0.80" y=" 0.000" z=" 0.0" mass-prop="/sim/weight[2]/weight-lb"/> <!-- Passengers -->
  <weight x=" 0.05" y=" 0.000" z="-0.2" mass-prop="/sim/weight[3]/weight-lb"/> <!-- Baggage -->

  <!-- Mass distribution
       Dilbert : The cg should be about 1/6 chord ahead of the chord center.
                 2.094 / 6     = 0.349
                 1.145 + 0.349 = 1.494     2.000 for Navion
  -->
  <ballast x="3.600" y="0.000" z="-0.500" mass="638"/>

</airplane>
