Debian Codegraph @

Aircraft/Generic/JSBSim/Systems/airship_added_mass.xml

raw symbols SCIP
1 <!--
2
3 Airship added/virtual mass model for JSBSim.
4
5 Copyright (C) 2008 - 2018 Anders Gidenstam (anders(at)gidenstam.org)
6
7 This program is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2 of the License, or
10 (at your option) any later version.
11
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20
21 -->
22 <system name="added-mass">
23
24 <documentation>
25 This system computes forces and moments due to added/virtual mass.
26 The model is based on
27 [Max M. Munk, "Aerodynamic forces on airship hulls", NACA report 184, 1924]
28 and the introduction in
29 [Christopher J. Atkinson, Robert G. Urso, "Modeling of Apparent Mass Effects
30 for the Real-Time Simulation of a Hybrid Airship", AIAA Modeling and
31 Simulation Technologies Conference, Aug 2006].
32
33 Usage:
34
35 Define the following properties:
36 aero/constants/volume-ft3
37 aero/constants/length-diameter-ft2 (length^2 + diameter^2)
38 aero/constants/added-mass/k-axial (all three are positive but
39 aero/constants/added-mass/k-transverse can be entered as negative
40 aero/constants/added-mass/k-rotational for backwards compatibility)
41 aero/constants/added-mass/tweak-factor (1.0 is the standard value)
42
43 aero/constants/added-mass/k-traverse (old misspelling, can be given
44 to work with older FlightGear)
45
46 Define the following external forces and moments:
47
48 <force name="added-mass-bx" frame="BODY">
49 <location unit="">
50 { AERORP }
51 </location>
52 <direction>
53 <x> 1.0 </x>
54 <y> 0.0 </y>
55 <z> 0.0 </z>
56 </direction>
57 </force>
58 <force name="added-mass-by" frame="BODY">
59 <location unit="">
60 { AERORP }
61 </location>
62 <direction>
63 <x> 0.0 </x>
64 <y> 1.0 </y>
65 <z> 0.0 </z>
66 </direction>
67 </force>
68 <force name="added-mass-bz" frame="BODY">
69 <location unit="">
70 { AERORP }
71 </location>
72 <direction>
73 <x> 0.0 </x>
74 <y> 0.0 </y>
75 <z> 1.0 </z>
76 </direction>
77 </force>
78
79 <moment name="added-mass-pitch" frame="BODY" unit="LBSFT">
80 <direction>
81 <x> 0.0 </x>
82 <y> 1.0 </y>
83 <z> 0.0 </z>
84 </direction>
85 </moment>
86 <moment name="added-mass-roll" frame="BODY" unit="LBSFT">
87 <direction>
88 <x> 1.0 </x>
89 <y> 0.0 </y>
90 <z> 0.0 </z>
91 </direction>
92 </moment>
93 <moment name="added-mass-yaw" frame="BODY" unit="LBSFT">
94 <direction>
95 <x> 0.0 </x>
96 <y> 0.0 </y>
97 <z> 1.0 </z>
98 </direction>
99 </moment>
100
101 The old deprecated force based external moment implementation below is still
102 supported.
103
104 <force name="added-mass-pitch[0]" frame="BODY">
105 <location unit="">
106 <x> AERORP X </x>
107 <y> AERORP Y </y>
108 <z> AERORP Z - 0.3048 </z>
109 </location>
110 <direction>
111 <x> 1.0 </x>
112 <y> 0.0 </y>
113 <z> 0.0 </z>
114 </direction>
115 </force>
116 <force name="added-mass-pitch[1]" frame="BODY">
117 <location unit="M">
118 <x> AERORP X </x>
119 <y> AERORP Y </y>
120 <z> AERORP Z + 0.3048 </z>
121 </location>
122 <direction>
123 <x> 1.0 </x>
124 <y> 0.0 </y>
125 <z> 0.0 </z>
126 </direction>
127 </force>
128
129 <force name="added-mass-yaw[0]" frame="BODY">
130 <location unit="M">
131 <x> AERORP X </x>
132 <y> AERORP Y - 0.3048 </y>
133 <z> 0.0 </z>
134 </location>
135 <direction>
136 <x> 1.0 </x>
137 <y> 0.0 </y>
138 <z> 0.0 </z>
139 </direction>
140 </force>
141 <force name="added-mass-yaw[1]" frame="BODY">
142 <location unit="M">
143 <x> AERORP X </x>
144 <y> AERORP Y + 0.3048 </y>
145 <z> 0.0 </z>
146 </location>
147 <direction>
148 <x> 1.0 </x>
149 <y> 0.0 </y>
150 <z> 0.0 </z>
151 </direction>
152 </force>
153
154 </documentation>
155
156 <channel name="startup">
157
158 <!-- Allow the vehicle state to stabilize. -->
159 <fcs_function name="aero/added-mass/active">
160 <function>
161 <min>
162 <property> aero/constants/added-mass/tweak-factor </property>
163 <max>
164 <value> 0.0 </value>
165 <difference>
166 <property> simulation/sim-time-sec </property>
167 <value> 2.0 </value>
168 </difference>
169 </max>
170 </min>
171 </function>
172 </fcs_function>
173
174 </channel>
175
176 <property>aero/constants/added-mass/k-transverse</property>
177 <property>aero/constants/added-mass/k-traverse</property>
178 <channel name="backward-compatibility">
179
180 <!-- Allow vehicles still using the old misspelled k-traverse coefficient. -->
181 <switch name="aero/constants/added-mass/k-transverse-final">
182 <default value="aero/constants/added-mass/k-transverse"/>
183 <test logic="AND" value="aero/constants/added-mass/k-transverse">
184 aero/constants/added-mass/k-transverse NE 0.0
185 </test>
186 <test logic="AND" value="aero/constants/added-mass/k-traverse">
187 aero/constants/added-mass/k-traverse NE 0.0
188 </test>
189 </switch>
190
191 </channel>
192
193 <channel name="translational">
194
195 <fcs_function name="aero/added-mass/force-bx-lbs">
196 <function>
197 <product>
198 <value>-1.0</value>
199 <property> aero/added-mass/active </property>
200 <property> atmosphere/rho-slugs_ft3 </property>
201 <abs><property> aero/constants/added-mass/k-axial </property></abs>
202 <property> aero/constants/volume-ft3 </property>
203 <property> accelerations/udot-ft_sec2 </property>
204 </product>
205 </function>
206 <output> external_reactions/added-mass-bx/magnitude </output>
207 </fcs_function>
208
209 <fcs_function name="aero/added-mass/force-by-lbs">
210 <function>
211 <product>
212 <value>-1.0</value>
213 <property> aero/added-mass/active </property>
214 <property> atmosphere/rho-slugs_ft3 </property>
215 <abs><property> aero/constants/added-mass/k-transverse-final </property></abs>
216 <property> aero/constants/volume-ft3 </property>
217 <property> accelerations/vdot-ft_sec2 </property>
218 </product>
219 </function>
220 <output> external_reactions/added-mass-by/magnitude </output>
221 </fcs_function>
222
223 <fcs_function name="aero/added-mass/force-bz-lbs">
224 <function>
225 <product>
226 <value>-1.0</value>
227 <property> aero/added-mass/active </property>
228 <property> atmosphere/rho-slugs_ft3 </property>
229 <abs><property> aero/constants/added-mass/k-transverse-final </property></abs>
230 <property> aero/constants/volume-ft3 </property>
231 <property> accelerations/wdot-ft_sec2 </property>
232 </product>
233 </function>
234 <output> external_reactions/added-mass-bz/magnitude </output>
235 </fcs_function>
236
237 </channel>
238
239 <channel name="rotational">
240
241 <fcs_function name="aero/added-mass/pitch-moment-lbsft">
242 <function>
243 <product>
244 <property> aero/added-mass/active </property>
245 <value>-0.05 </value>
246 <property> atmosphere/rho-slugs_ft3 </property>
247 <abs><property> aero/constants/added-mass/k-rotational </property></abs>
248 <property> aero/constants/volume-ft3 </property>
249 <property> aero/constants/length-diameter-ft2 </property>
250 <property> accelerations/qdot-rad_sec2 </property>
251 </product>
252 </function>
253 </fcs_function>
254
255 <fcs_function name="aero/added-mass/yaw-moment-lbsft">
256 <function>
257 <product>
258 <property> aero/added-mass/active </property>
259 <value>-0.05 </value>
260 <property> atmosphere/rho-slugs_ft3 </property>
261 <abs><property> aero/constants/added-mass/k-rotational </property></abs>
262 <property> aero/constants/volume-ft3 </property>
263 <property> aero/constants/length-diameter-ft2 </property>
264 <property> accelerations/rdot-rad_sec2 </property>
265 </product>
266 </function>
267 </fcs_function>
268
269 <pure_gain name="aero/added-mass/pitch-moment/moment-lbsft">
270 <input>aero/added-mass/pitch-moment-lbsft</input>
271 <gain>1.0</gain>
272 <output>external_reactions/added-mass-pitch/magnitude-lbsft</output>
273 </pure_gain>
274 <pure_gain name="aero/added-mass/pitch-moment/force-lbs[0]">
275 <input> aero/added-mass/pitch-moment-lbsft </input>
276 <gain>-0.5</gain>
277 <output> external_reactions/added-mass-pitch[0]/magnitude </output>
278 </pure_gain>
279 <pure_gain name="aero/added-mass/pitch-moment/force-lbs[1]">
280 <input> aero/added-mass/pitch-moment-lbsft </input>
281 <gain>0.5</gain>
282 <output> external_reactions/added-mass-pitch[1]/magnitude </output>
283 </pure_gain>
284
285 <pure_gain name="aero/added-mass/yaw-moment/moment-lbsft">
286 <input>aero/added-mass/yaw-moment-lbsft</input>
287 <gain>1.0</gain>
288 <output>external_reactions/added-mass-yaw/magnitude-lbsft</output>
289 </pure_gain>
290 <pure_gain name="aero/added-mass/yaw-moment/force-lbs[0]">
291 <input> aero/added-mass/yaw-moment-lbsft </input>
292 <gain>-0.5</gain>
293 <output> external_reactions/added-mass-yaw[0]/magnitude </output>
294 </pure_gain>
295 <pure_gain name="aero/added-mass/yaw-moment/force-lbs[1]">
296 <input> aero/added-mass/yaw-moment-lbsft </input>
297 <gain>0.5</gain>
298 <output> external_reactions/added-mass-yaw[1]/magnitude </output>
299 </pure_gain>
300
301 </channel>
302
303 </system>