Skip to content

Commit

Permalink
Added a computation of the static pitch moment and updated the debug …
Browse files Browse the repository at this point in the history
…display.
  • Loading branch information
andgi committed Jul 16, 2016
1 parent dd04575 commit 0def4ba
Show file tree
Hide file tree
Showing 2 changed files with 159 additions and 28 deletions.
159 changes: 143 additions & 16 deletions Nordstern.xml
Expand Up @@ -31,7 +31,7 @@
<email>anders at gidenstam dot org</email>

<filecreationdate>2010-04-20</filecreationdate>
<version>$Id: Nordstern.xml,v 1.18 2016/07/10 21:35:34 anders Exp $</version>
<version>$Id: Nordstern.xml,v 1.19 2016/07/16 21:49:05 anders Exp $</version>

<description>JSBSim model of the Zeppelin LZ 121 "Nordstern".</description>

Expand Down Expand Up @@ -1640,27 +1640,154 @@
<!--
==== Initial static condition weigh-off ====================================
-->
<system name="Weigh_Off">
<channel name="Initial_Static_Weigh_Off">
<system name="Weight, lift and balance">
<channel name="static-condition">
<!-- This system ensures that the ship starts slightly heavy. -->
<!-- The weight of inertia/pointmass-weight-lbs[0] is set from Nasal. -->

<summer name="static-condition/net-lift-lbs">
<input> buoyant_forces/gas-cell[0]/buoyancy-lbs </input>
<input> buoyant_forces/gas-cell[1]/buoyancy-lbs </input>
<input> buoyant_forces/gas-cell[2]/buoyancy-lbs </input>
<input> buoyant_forces/gas-cell[3]/buoyancy-lbs </input>
<input> buoyant_forces/gas-cell[4]/buoyancy-lbs </input>
<input> buoyant_forces/gas-cell[5]/buoyancy-lbs </input>
<input> buoyant_forces/gas-cell[6]/buoyancy-lbs </input>
<input> buoyant_forces/gas-cell[7]/buoyancy-lbs </input>
<input> buoyant_forces/gas-cell[8]/buoyancy-lbs </input>
<input> buoyant_forces/gas-cell[9]/buoyancy-lbs </input>
<input> buoyant_forces/gas-cell[10]/buoyancy-lbs </input>
<input> buoyant_forces/gas-cell[11]/buoyancy-lbs </input>
<input> -inertia/weight-lbs </input>
<input>buoyant_forces/gas-cell[0]/buoyancy-lbs</input>
<input>buoyant_forces/gas-cell[1]/buoyancy-lbs</input>
<input>buoyant_forces/gas-cell[2]/buoyancy-lbs</input>
<input>buoyant_forces/gas-cell[3]/buoyancy-lbs</input>
<input>buoyant_forces/gas-cell[4]/buoyancy-lbs</input>
<input>buoyant_forces/gas-cell[5]/buoyancy-lbs</input>
<input>buoyant_forces/gas-cell[6]/buoyancy-lbs</input>
<input>buoyant_forces/gas-cell[7]/buoyancy-lbs</input>
<input>buoyant_forces/gas-cell[8]/buoyancy-lbs</input>
<input>buoyant_forces/gas-cell[9]/buoyancy-lbs</input>
<input>buoyant_forces/gas-cell[10]/buoyancy-lbs</input>
<input>buoyant_forces/gas-cell[11]/buoyancy-lbs</input>
<input>-inertia/weight-lbs</input>
</summer>

<fcs_function name="static-condition/static-pitch-moment-lbsft">
<function>
<sum>
<product>
<property>buoyant_forces/gas-cell[0]/buoyancy-lbs</property>
<sum>
<value>-377.29659</value>
<product>
<value>0.083333333</value>
<property>inertia/cg-x-in</property>
</product>
</sum>
</product>
<product>
<property>buoyant_forces/gas-cell[1]/buoyancy-lbs</property>
<sum>
<value>-344.48819</value>
<product>
<value>0.083333333</value>
<property>inertia/cg-x-in</property>
</product>
</sum>
</product>
<product>
<property>buoyant_forces/gas-cell[2]/buoyancy-lbs</property>
<sum>
<value>-311.67979</value>
<product>
<value>0.083333333</value>
<property>inertia/cg-x-in</property>
</product>
</sum>
</product>
<product>
<property>buoyant_forces/gas-cell[3]/buoyancy-lbs</property>
<sum>
<value>-278.87139</value>
<product>
<value>0.083333333</value>
<property>inertia/cg-x-in</property>
</product>
</sum>
</product>
<product>
<property>buoyant_forces/gas-cell[4]/buoyancy-lbs</property>
<sum>
<value>-246.06299</value>
<product>
<value>0.083333333</value>
<property>inertia/cg-x-in</property>
</product>
</sum>
</product>
<product>
<property>buoyant_forces/gas-cell[5]/buoyancy-lbs</property>
<sum>
<value>-213.25459</value>
<product>
<value>0.083333333</value>
<property>inertia/cg-x-in</property>
</product>
</sum>
</product>
<product>
<property>buoyant_forces/gas-cell[6]/buoyancy-lbs</property>
<sum>
<value>-180.44619</value>
<product>
<value>0.083333333</value>
<property>inertia/cg-x-in</property>
</product>
</sum>
</product>
<product>
<property>buoyant_forces/gas-cell[7]/buoyancy-lbs</property>
<sum>
<value>-147.6378</value>
<product>
<value>0.083333333</value>
<property>inertia/cg-x-in</property>
</product>
</sum>
</product>
<product>
<property>buoyant_forces/gas-cell[8]/buoyancy-lbs</property>
<sum>
<value>-114.8294</value>
<product>
<value>0.083333333</value>
<property>inertia/cg-x-in</property>
</product>
</sum>
</product>
<product>
<property>buoyant_forces/gas-cell[9]/buoyancy-lbs</property>
<sum>
<value>-82.020997</value>
<product>
<value>0.083333333</value>
<property>inertia/cg-x-in</property>
</product>
</sum>
</product>
<product>
<property>buoyant_forces/gas-cell[10]/buoyancy-lbs</property>
<sum>
<value>-49.212598</value>
<product>
<value>0.083333333</value>
<property>inertia/cg-x-in</property>
</product>
</sum>
</product>
<product>
<property>buoyant_forces/gas-cell[11]/buoyancy-lbs</property>
<sum>
<value>-16.404199</value>
<product>
<value>0.083333333</value>
<property>inertia/cg-x-in</property>
</product>
</sum>
</product>
</sum>
</function>
</fcs_function>

</channel>
</system>

Expand Down
28 changes: 16 additions & 12 deletions Systems/Nordstern.nas
Expand Up @@ -355,26 +355,30 @@ var debug_display_view_handler = {
me.right = screen.display.new(-250, 20);
# Static condition
me.left.add("/fdm/jsbsim/static-condition/net-lift-lbs");
me.left.add("/fdm/jsbsim/atmosphere/T-R");
me.left.add("/fdm/jsbsim/buoyant_forces/gas-cell[1]/temp-R",
"/fdm/jsbsim/buoyant_forces/gas-cell[10]/temp-R");
me.left.add("/fdm/jsbsim/static-condition/static-pitch-moment-lbsft");
# C.G.
me.left.add("/fdm/jsbsim/inertia/cg-x-in");
# Atmosphere and gas temperatures
me.left.add("/fdm/jsbsim/atmosphere/T-R");
me.left.add("/fdm/jsbsim/buoyant_forces/gas-cell[0]/temp-R",
"/fdm/jsbsim/buoyant_forces/gas-cell[1]/temp-R",
"/fdm/jsbsim/buoyant_forces/gas-cell[10]/temp-R",
"/fdm/jsbsim/buoyant_forces/gas-cell[11]/temp-R");
# Pitch moments
me.left.add("/fdm/jsbsim/moments/m-buoyancy-lbsft",
"/fdm/jsbsim/moments/m-aero-lbsft",
"/fdm/jsbsim/moments/m-total-lbsft");
#me.left.add("/fdm/jsbsim/moments/m-buoyancy-lbsft",
# "/fdm/jsbsim/moments/m-aero-lbsft",
# "/fdm/jsbsim/moments/m-total-lbsft");
# Mooring related
me.left.add("/fdm/jsbsim/mooring/total-distance-ft",
"/fdm/jsbsim/mooring/latitude-diff-ft",
"/fdm/jsbsim/mooring/longitude-diff-ft",
"/fdm/jsbsim/mooring/altitude-diff-ft");
me.left.add("/fdm/jsbsim/velocities/vrp-v-north-fps",
"/velocities/speed-north-fps");
me.left.add("/fdm/jsbsim/velocities/vrp-v-east-fps",
"/velocities/speed-east-fps");
me.left.add("/fdm/jsbsim/velocities/vrp-v-down-fps",
"/velocities/speed-down-fps");
#me.left.add("/fdm/jsbsim/velocities/vrp-v-north-fps",
# "/velocities/speed-north-fps");
#me.left.add("/fdm/jsbsim/velocities/vrp-v-east-fps",
# "/velocities/speed-east-fps");
#me.left.add("/fdm/jsbsim/velocities/vrp-v-down-fps",
# "/velocities/speed-down-fps");

# Flight information
me.right.add("orientation/pitch-deg");
Expand Down

0 comments on commit 0def4ba

Please sign in to comment.