JSBSim Buoyant forces: Difference between revisions

From FlightGear wiki
Jump to navigation Jump to search
(→‎Modelling the air system of a blimp: More information on blimp air systems.)
(Updated all links to gitorious content.)
Line 123: Line 123:
* '''Pressurized gas balloons'''. The gas pressure may exceed that of the surrounding atmosphere (e.g. when the maximum volume has been reached or due to stretching of the envelope). Example: [http://jsbsim.cvs.sourceforge.net/viewvc/jsbsim/JSBSim/aircraft/weather-balloon/ weather balloon].
* '''Pressurized gas balloons'''. The gas pressure may exceed that of the surrounding atmosphere (e.g. when the maximum volume has been reached or due to stretching of the envelope). Example: [http://jsbsim.cvs.sourceforge.net/viewvc/jsbsim/JSBSim/aircraft/weather-balloon/ weather balloon].
* '''Rigid (unpressurized) airships'''. The gas cells are kept at atmosphere pressure and vary in volume. The rigid outer shape of the hull maintains its shape regardless of the volume of the gas cells. Example: [[Zeppelin LZ 121 Nordstern]].
* '''Rigid (unpressurized) airships'''. The gas cells are kept at atmosphere pressure and vary in volume. The rigid outer shape of the hull maintains its shape regardless of the volume of the gas cells. Example: [[Zeppelin LZ 121 Nordstern]].
* '''Pressure airships'''. The gas cells are kept at a higher pressure than the surrounding atmosphere by means of ballonets (air bladders inside the gas cell) that compensate for volume changes of the lifting gas. As a result the envelope (the outer skin of the gas cells) is kept at its maximum volume and maintains its shape. Examples: [[Submarine Scout]], [[Zeppelin NT]], [http://gitorious.org/anders-hangar/znp-k US Navy ZNP-K / Goodyear K-type airship].
* '''Pressure airships'''. The gas cells are kept at a higher pressure than the surrounding atmosphere by means of ballonets (air bladders inside the gas cell) that compensate for volume changes of the lifting gas. As a result the envelope (the outer skin of the gas cells) is kept at its maximum volume and maintains its shape. Examples: [[Submarine Scout]], [[Zeppelin NT]], [http://github.com/andgi/FlightGear-ZNP-K US Navy ZNP-K / Goodyear K-type airship].


=== Modelling added mass ===
=== Modelling added mass ===
Line 129: Line 129:
When a body immersed in a fluid accelerates its inertia is not only determined by its inherent mass properties but also by some of the fluid that surrounds the body. If the density of the body is not significantly larger than that of the fluid this effect, usually called [http://en.wikipedia.org/wiki/Added_mass added or virtual mass], needs to be taken into account.
When a body immersed in a fluid accelerates its inertia is not only determined by its inherent mass properties but also by some of the fluid that surrounds the body. If the density of the body is not significantly larger than that of the fluid this effect, usually called [http://en.wikipedia.org/wiki/Added_mass added or virtual mass], needs to be taken into account.


For buoyant aircraft in JSBSim added mass can be modelled using external forces and the [http://gitorious.org/fg/fgdata/source/Aircraft/Generic/JSBSim/Systems/airship_added_mass.xml airship_added_mass.xml] system available in fgdata/Aircraft/Generic/JSBSim/Systems/.
For buoyant aircraft in JSBSim added mass can be modelled using external forces and the [http://sourceforge.net/p/flightgear/fgdata/ci/next/tree/Aircraft/Generic/JSBSim/Systems/airship_added_mass.xml airship_added_mass.xml] system available in fgdata/Aircraft/Generic/JSBSim/Systems/.
This model is based on NACA report 184 [http://naca.central.cranfield.ac.uk/reports/1924/naca-report-184.pdf (Max M. Munk, "Aerodynamic forces on airship hulls", 1924)].
This model is based on NACA report 184 [http://naca.central.cranfield.ac.uk/reports/1924/naca-report-184.pdf (Max M. Munk, "Aerodynamic forces on airship hulls", 1924)].


Line 223: Line 223:
'''Note that the coefficients entered for the airship_added_mass.xml system should have reversed sign compared to those in the report (i.e. be negative) and that k-transverse is misspelled. These defects in the system may be addressed eventually.'''
'''Note that the coefficients entered for the airship_added_mass.xml system should have reversed sign compared to those in the report (i.e. be negative) and that k-transverse is misspelled. These defects in the system may be addressed eventually.'''


A typical setup of the added mass system looks like this (from [http://gitorious.org/anders-hangar/znp-k US Navy ZNP-K / Goodyear K-type airship]):
A typical setup of the added mass system looks like this (from [http://github.com/andgi/FlightGear-ZNP-K US Navy ZNP-K / Goodyear K-type airship]):
<syntaxhighlight lang="xml">
<syntaxhighlight lang="xml">
  <system name="constants">
  <system name="constants">
Line 248: Line 248:
* Heat transfer through black body radiation. The heat transferred per time unit is the product of Stefan-Boltzmann's constant, the emissivity of the envelope material, the surface area between the gas and the atmosphere and the difference between atmosphere temperature to the power of 4 and the the gas temperature to the power of 4.
* Heat transfer through black body radiation. The heat transferred per time unit is the product of Stefan-Boltzmann's constant, the emissivity of the envelope material, the surface area between the gas and the atmosphere and the difference between atmosphere temperature to the power of 4 and the the gas temperature to the power of 4.


For an airship with a single ellipsoid gas cell (like most pressure airships) this could be expressed as follows (from [http://gitorious.org/anders-hangar/znp-k US Navy ZNP-K / Goodyear K-type airship]):
For an airship with a single ellipsoid gas cell (like most pressure airships) this could be expressed as follows (from [http://github.com/andgi/FlightGear-ZNP-K US Navy ZNP-K / Goodyear K-type airship]):
<syntaxhighlight lang="xml">
<syntaxhighlight lang="xml">
  <heat>
  <heat>
Line 296: Line 296:
When creating a detailed air system the max_overpressure elements should be set well over the maximum expected pressure and all release of air or gas should be done through the controllable valves.
When creating a detailed air system the max_overpressure elements should be set well over the maximum expected pressure and all release of air or gas should be done through the controllable valves.


The examples here are from the [http://gitorious.org/anders-hangar/znp-k US Navy ZNP-K / Goodyear K-type airship]. This blimp has one gas filled envelope with two ballonets. Each ballonet has one outflow valve that can be opened by the pressure (if it goes high enough) or the pilot. To fill the ballonets air under some pressure is taken in by air scoops in the propeller slip streams and propagated via controllable non-return valves (called dampers) to the ballonets. There is one damper valve for each ballonet.
The examples here are from the [http://github.com/andgi/FlightGear-ZNP-K US Navy ZNP-K / Goodyear K-type airship]. This blimp has one gas filled envelope with two ballonets. Each ballonet has one outflow valve that can be opened by the pressure (if it goes high enough) or the pilot. To fill the ballonets air under some pressure is taken in by air scoops in the propeller slip streams and propagated via controllable non-return valves (called dampers) to the ballonets. There is one damper valve for each ballonet.


It is convenient to structure the implementation of the air system as a separate system. To do that a property for the inflow needs to be
It is convenient to structure the implementation of the air system as a separate system. To do that a property for the inflow needs to be
Line 309: Line 309:
</syntaxhighlight>
</syntaxhighlight>


See also [http://gitorious.org/anders-hangar/znp-k/source/ZNP-K.xml#L718 the main file of the ZNP-K FDM configuration].
See also [http://github.com/andgi/FlightGear-ZNP-K/blob/master/ZNP-K.xml#L718 the main file of the ZNP-K FDM configuration].


The full air system of the US Navy ZNP-K is available [http://gitorious.org/anders-hangar/znp-k/source/Systems/air-system-jsbsim.xml here] and some of its parts will be discussed below.
The full air system of the US Navy ZNP-K is available [http://github.com/andgi/FlightGear-ZNP-K/blob/master/Systems/air-system-jsbsim.xml here] and some of its parts will be discussed below.


The air system takes the following command properties as input from the pilot:
The air system takes the following command properties as input from the pilot:

Revision as of 21:02, 4 May 2015

JSBSim has support for buoyant gas cells. This page will attempt to explain how to configure them for a JSBSim aircraft (e.g. blimp, rigid airship or gas balloon).

FGGasCell and FGBallonet

A gas cell models one container (cell) of buoyant gas. It may contain zero or more ballonets (i.e. containers of air). All gas cells in a FDM configuration are declared in the <buoyant_forces> section.

The physical model for FGGasCell and FGBallonet is based on the general gas law.

Configuration File Format

<buoyant_forces>
  <gas_cell type="{HYDROGEN | HELIUM | AIR}">
    <location unit="{M | IN | ...}">
      <x> {number} </x>
      <y> {number} </y>
      <z> {number} </z>
    </location>
    <x_width unit="{M | IN | ...}"> {number} </x_width>
    <y_width unit="{M | IN | ...}"> {number} </y_width>
    <z_width unit="{M | IN | ...}"> {number} </z_width>
    <x_radius unit="{M | IN | ...}"> {number} </x_radius>
    <y_radius unit="{M | IN | ...}"> {number} </y_radius>
    <z_radius unit="{M | IN | ...}"> {number} </z_radius>
    <max_overpressure unit="{PA | PSI | ...}"> {number} </max_overpressure>
    <valve_coefficient unit="{M4*SEC/KG | FT4*SEC/SLUG}"> {number} </valve_coefficient>
    <fullness> {number} </fullness>  
    <heat>
      {heat transfer coefficient functions} [lbs ft / sec]
    </heat>
    <ballonet>
      <location unit="{M | IN | ...}">
        <x> {number} </x>
        <y> {number} </y>
        <z> {number} </z>
      </location>
      <x_width unit="{M | IN | ...}"> {number} </x_width>
      <y_width unit="{M | IN | ...}"> {number} </y_width>
      <z_width unit="{M | IN | ...}"> {number} </z_width>
      <x_radius unit="{M | IN | ...}"> {number} </x_radius>
      <y_radius unit="{M | IN | ...}"> {number} </y_radius>
      <z_radius unit="{M | IN | ...}"> {number} </z_radius>
      <max_overpressure unit="{PA | PSI | ...}"> {number} </max_overpressure>
      <valve_coefficient unit="{M4*SEC/KG | FT4*SEC/SLUG}"> {number} </valve_coefficient>
      <fullness> {number} </fullness>  
      <heat>
       {heat transfer coefficient functions} [lb ft / (sec Rankine)]
      </heat>
      <blower_input>
       {input air flow function} [ft^3 / sec]
      </blower_input>
    </ballonet>
  </gas_cell>
</buoyant_forces>

Parameter definitions

Gas cell element
type type of gas in the cell. One of HYDROGEN, HELIUM or AIR.
location location of the centre of the cell in the structural frame of the aircraft. This is were the forces and mass of the cell are applied.
{x/y/z}_radius radius of both ends of the cell in the respective direction.
{x/y/z}_width width (excluding the radius) of the cell in the respective direction.
fullness initial fullness of the cell, normally between 0 and 1. Values above 1 initialize the cell at pressure.
max_overpressure maximum pressure in the cell. In case of excessive pressure gas is automatically valved off.
valve_coefficient the capacity of the manual gas valve. The valve is considered to be located at the top of the cell. The valve coefficient determine the flow out of the cell according to dVolume/dt = ValveCoefficient * DeltaPressure.
heat zero or more FGFunction:s describing the heat flow from the atmosphere into the gas cell. Unit: [lb ft / (sec Rankine)]. If there are no heat transfer functions at all the cell temperature will always be equal that of the surrounding atmosphere. A constant function returning 0 results in adiabatic behaviour, i.e. no heat transfer at all.
Ballonet element
There can be zero or more ballonets in a gas cell.
location location of the centre of the ballonet in the structural frame of the aircraft. This is were the forces and mass of the ballonet are applied.
{x/y/z}_radius radius of both ends of the ballonet in the respective direction.
{x/y/z}_width width (excluding any radius) of the ballonet in the respective direction.
max_overpressure maximum pressure in the ballonet. In case of excessive pressure air is automatically valved off to the atmosphere.
valve_coefficient the capacity of the exit valve between the ballonet and the atmosphere. The valve coefficient determine the flow out of the ballonet according to dVolume/dt = ValveCoefficient * DeltaPressure.
heat zero or more FGFunction:s describing the heat flow from the enclosing gas cell into the ballonet. Unit: [lb ft / (sec Rankine)]. The heat flowing to the ballonet will be deducted from the enclosing gas cell.
blower_input one FGFunction describing the air flow into the ballonet. Unit: [ft3 / sec] at the temperature and pressure of the ballonet.

Notes

  • Gas cell and ballonet shape
    • The shape of a cell or ballonet must be specified. It determines the maximum volume of the cell or ballonet and its inertia properties.
    • The supported cell and ballonet shapes are ellipsoid (3 radii given) and cylindrical (2 equal radii and one width given). For other combinations the inertia reverts to that of a point mass.

Examples

There are several different types of buoyant aircraft that can be simulated, among them unpressurized and pressurized gas balloons, rigid (unpressurized) airships and pressure airships (blimps and semi-rigid airships).

  • Unpressurized gas balloons. The pressure in the gas cell is kept at that of the atmosphere and the cell's volume will vary with the surrounding air pressure. If the maximum volume of the gas cell is exceeded gas will be lost to the atmosphere. Example: ZF Navy free balloon.
  • Pressurized gas balloons. The gas pressure may exceed that of the surrounding atmosphere (e.g. when the maximum volume has been reached or due to stretching of the envelope). Example: weather balloon.
  • Rigid (unpressurized) airships. The gas cells are kept at atmosphere pressure and vary in volume. The rigid outer shape of the hull maintains its shape regardless of the volume of the gas cells. Example: Zeppelin LZ 121 Nordstern.
  • Pressure airships. The gas cells are kept at a higher pressure than the surrounding atmosphere by means of ballonets (air bladders inside the gas cell) that compensate for volume changes of the lifting gas. As a result the envelope (the outer skin of the gas cells) is kept at its maximum volume and maintains its shape. Examples: Submarine Scout, Zeppelin NT, US Navy ZNP-K / Goodyear K-type airship.

Modelling added mass

When a body immersed in a fluid accelerates its inertia is not only determined by its inherent mass properties but also by some of the fluid that surrounds the body. If the density of the body is not significantly larger than that of the fluid this effect, usually called added or virtual mass, needs to be taken into account.

For buoyant aircraft in JSBSim added mass can be modelled using external forces and the airship_added_mass.xml system available in fgdata/Aircraft/Generic/JSBSim/Systems/. This model is based on NACA report 184 (Max M. Munk, "Aerodynamic forces on airship hulls", 1924).

To use this system a set of external forces need to be defined which will be used to transmit forces and moments due to added mass. A template for the forces needed follows below:

 <external_reactions>
   <force name="added-mass-bx" frame="BODY">
     <location unit="">
       { AERORP }
     </location>
     <direction>
       <x> 1.0 </x>
       <y> 0.0 </y>
       <z> 0.0 </z>
     </direction>
   </force>
   <force name="added-mass-by" frame="BODY">
     <location unit="">
       { AERORP }
     </location>
     <direction>
       <x> 0.0 </x>
       <y> 1.0 </y>
       <z> 0.0 </z>
     </direction>
   </force>
   <force name="added-mass-bz" frame="BODY">
     <location unit="">
       { AERORP }
     </location>
     <direction>
       <x> 0.0 </x>
       <y> 0.0 </y>
       <z> 1.0 </z>
     </direction>
   </force>
   <force name="added-mass-pitch[0]" frame="BODY">
     <location unit="">
       <x> AERORP X </x>
       <y> AERORP Y </y>
       <z> AERORP Z - 0.3048 </z>
     </location>
     <direction>
       <x> 1.0 </x>
       <y> 0.0 </y>
       <z> 0.0 </z>
     </direction>
   </force>
   <force name="added-mass-pitch[1]" frame="BODY">
     <location unit="M">
       <x> AERORP X </x>
       <y> AERORP Y </y>
       <z> AERORP Z + 0.3048 </z>
     </location>
     <direction>
       <x> 1.0 </x>
       <y> 0.0 </y>
       <z> 0.0 </z>
     </direction>
   </force>
   <force name="added-mass-yaw[0]" frame="BODY">
     <location unit="M">
       <x> AERORP X </x>
       <y> AERORP Y - 0.3048 </y>
       <z> 0.0 </z>
     </location>
     <direction>
       <x> 1.0 </x>
       <y> 0.0 </y>
       <z> 0.0 </z>
     </direction>
   </force>
   <force name="added-mass-yaw[1]" frame="BODY">
     <location unit="M">
       <x> AERORP X </x>
       <y> AERORP Y + 0.3048 </y>
       <z> 0.0 </z>
     </location>
     <direction>
       <x> 1.0 </x>
       <y> 0.0 </y>
       <z> 0.0 </z>
     </direction>
   </force>
 </external_reactions>

The added mass system is configured with the total volume of the hull (aero/constants/volume-ft3), the sum of the squares of the length and maximum diameter of the hull (aero/constants/length-diameter-ft2) and three coefficients (aero/constants/added-mass/k-axial, aero/constants/added-mass/k-traverse and aero/constants/added-mass/k-rotational). The coefficients are set based on the fitness ratio of the hull (length over diameter) and can be interpolated from the table last in (Max M. Munk, "Aerodynamic forces on airship hulls", NACA report 184, 1924) or taken from the plot of that table below.

Added mass coefficients based on a table in (M. Munk, 1924).

Note that the coefficients entered for the airship_added_mass.xml system should have reversed sign compared to those in the report (i.e. be negative) and that k-transverse is misspelled. These defects in the system may be addressed eventually.

A typical setup of the added mass system looks like this (from US Navy ZNP-K / Goodyear K-type airship):

 <system name="constants">
  <!-- Aerodynamic constants. -->
  <property value="249.20"> aero/constants/length-ft </property>
  <property value="57.85"> aero/constants/diameter-ft </property>
  <property value="65447.3"> aero/constants/length-diameter-ft2 </property>
  <property value="425000.0"> aero/constants/volume-ft3 </property>
  <!-- Added mass coefficients. -->
  <property value="-0.08"> aero/constants/added-mass/k-axial </property>
  <property value="-0.88"> aero/constants/added-mass/k-traverse </property>
  <property value="-0.65"> aero/constants/added-mass/k-rotational </property>
 </system>
 <system file="airship_added_mass"/>


Modelling heat transfer

As seen in the list of parameters above, buoyant forces puts the burden of modelling heat the transfer between the gas cell and the environment and between the gas cell and any ballonets on the user. This is due to various configurations having different properties and leaving the possibilities open is JSBSim's approach.

One general but somewhat simplified view of heat transfer would divide it into the following parts:

  • Heat transfer through conduction. The heat transferred per time unit is the product of the conductivity of the envelope material, the surface area between the gas and the atmosphere and the difference in temperature between the gas and the atmosphere.
  • Heat transfer through black body radiation. The heat transferred per time unit is the product of Stefan-Boltzmann's constant, the emissivity of the envelope material, the surface area between the gas and the atmosphere and the difference between atmosphere temperature to the power of 4 and the the gas temperature to the power of 4.

For an airship with a single ellipsoid gas cell (like most pressure airships) this could be expressed as follows (from US Navy ZNP-K / Goodyear K-type airship):

 <heat>
   <function name="buoyant_forces/gas-cell/dU_conduction">
     <product>
       <value> 35685.00 </value> <!-- Surface area [ft2] -->
       <value>     0.05 </value> <!-- Conductivity [lb / (K ft sec)] (Guess) -->
       <difference>
         <property> atmosphere/T-R </property>
         <property> buoyant_forces/gas-cell/temp-R </property>
       </difference>
     </product>
   </function>
   <function name="buoyant_forces/gas-cell/dU_radiation">
     <product>
       <value> 0.1714e-8 </value> <!-- Stefan-Boltzmann's constant
                                       [Btu / (h ft^2 R^4)] -->
       <value>       0.2 </value> <!-- Emissivity [0,1] (Guess) -->
       <value>   35685.0 </value> <!-- Surface area [ft2] -->
       <difference>
         <pow>
           <property> atmosphere/T-R </property>
           <value> 4.0 </value>
         </pow>
         <pow>
           <property> buoyant_forces/gas-cell/temp-R </property>
           <value> 4.0 </value>
         </pow>
       </difference>
     </product>
   </function>
 </heat>

For the ballonets a similar formulation can be used, but with the gas cell temperature instead of the atmosphere temperature.

For a traditional rigid airship with several cylindrical gas cells a first approximation would be to only use the surface area towards the atmosphere in the formulation above and ignore heat exchange with the neighbouring gas cells.

The formulation above does not take the following important phenomena into account: the slipstream's effect on heat conduction and heating by direct solar radiation.


Modelling the air system of a blimp

Non-rigid (blimps) and semi-rigid airships need to maintain the lifting gas at a pressure somewhat higher than that of the surrounding atmosphere to keep the shape and rigidity of the gas cell/envelope for aerodynamic and structural reasons. The ballonets (air filled bladders inside the envelope) are what makes this possible. When the airship ascends the gas inside the envelope and the air in the ballonets expand (as the pressure from the atmosphere decreases) and air is expelled from the ballonets (if non empty) to make space for the gas. The envelope can only sustain a limited pressure differential. When the airship descends the gas and air inside the envelope will contract due to the increasing pressure from the atmosphere so air must be forced into the ballonets to keep the envelope filled and at a positive pressure compared to the atmosphere. Hence, both the flow of air into and out of the ballonets need to be controlled.

JSBSim buoyant forces provide three configuration elements related to the air system. First the max_overpressure element for both the gas cell and the ballonets which define the maximum pressure (over the current atmosphere pressure) the gas cell or ballonet can contain. If exceeded the offending part of the content is lost from the gas cell or ballonet. The second and third elements are the valve_coefficient and blower_input elements of the ballonets which determine the controllable in and out flow of air from the ballonets. When creating a detailed air system the max_overpressure elements should be set well over the maximum expected pressure and all release of air or gas should be done through the controllable valves.

The examples here are from the US Navy ZNP-K / Goodyear K-type airship. This blimp has one gas filled envelope with two ballonets. Each ballonet has one outflow valve that can be opened by the pressure (if it goes high enough) or the pilot. To fill the ballonets air under some pressure is taken in by air scoops in the propeller slip streams and propagated via controllable non-return valves (called dampers) to the ballonets. There is one damper valve for each ballonet.

It is convenient to structure the implementation of the air system as a separate system. To do that a property for the inflow needs to be created and connected to the (respective) ballonet:

  <blower_input>
    <function name="buoyant_forces/gas-cell/ballonet[0]/in-flow-ft3ps">
      <property>ballonets/in-flow-ft3ps[0]</property>
    </function>
  </blower_input>

See also the main file of the ZNP-K FDM configuration.

The full air system of the US Navy ZNP-K is available here and some of its parts will be discussed below.

The air system takes the following command properties as input from the pilot:

 <!-- Pilot inputs. -->
 <property value="1.0">fcs/ballonet-scoop-cmd-norm[0]</property>
 <property value="1.0">fcs/ballonet-scoop-cmd-norm[1]</property>

 <property value="0.0">fcs/ballonet-damper-cmd-norm[0]</property>
 <property value="0.0">fcs/ballonet-damper-cmd-norm[1]</property>

 <property>fcs/ballonet-valve-cmd-norm[0]</property>
 <property>fcs/ballonet-valve-cmd-norm[1]</property>

The presentation here will focus on the forward ballonet (number [0]).

Outflow

We will start with the outflow valve which is both automatic and manual. The position of the valve will be the maximum of its automatic opening to relief overpressure and the manual opening commanded by the pilot. The amount the valve opens due to overpressure is taken as linear in the overpressure. Note how the final valve position is written back into the ballonet's valve_open property.

  <fcs_function name="ballonets/relief-cmd-norm[0]">
   <function>
    <difference>
     <difference>
      <property>buoyant_forces/gas-cell/ballonet[0]/pressure-psf</property>
      <property>atmosphere/P-psf</property>
     </difference>
     <property>ballonets/automatic-valve-threshold-psf[0]</property>
    </difference>
   </function>   
   <clipto>
    <min>0</min>
    <max>1</max>
   </clipto>
  </fcs_function>

  <fcs_function name="ballonets/valve-pos-norm[0]">
   <function>
    <max>
     <property>fcs/ballonet-valve-cmd-norm[0]</property>
     <property>ballonets/relief-cmd-norm[0]</property>
    </max>
   </function>
   <clipto>
    <min>0</min>
    <max>1</max>
   </clipto>
   <output>buoyant_forces/gas-cell/ballonet[0]/valve_open</output>
  </fcs_function>

Sources