1 /*******************************************************************************
6 Purpose: Encapsulates an aircraft
9 ------------- Copyright (C) 1999 Jon S. Berndt (jsb@hal-pc.org) -------------
11 This program is free software; you can redistribute it and/or modify it under
12 the terms of the GNU General Public License as published by the Free Software
13 Foundation; either version 2 of the License, or (at your option) any later
16 This program is distributed in the hope that it will be useful, but WITHOUT
17 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
18 FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
21 You should have received a copy of the GNU General Public License along with
22 this program; if not, write to the Free Software Foundation, Inc., 59 Temple
23 Place - Suite 330, Boston, MA 02111-1307, USA.
25 Further information about the GNU General Public License can also be found on
26 the world wide web at http://www.gnu.org.
28 FUNCTIONAL DESCRIPTION
29 --------------------------------------------------------------------------------
30 Models the aircraft reactions and forces. This class is instantiated by the
31 FGFDMExec class and scheduled as an FDM entry. LoadAircraft() is supplied with a
32 name of a valid, registered aircraft, and the data file is parsed.
35 --------------------------------------------------------------------------------
37 04/03/99 JSB Changed Aero() method to correct body axis force calculation
38 from wind vector. Fix provided by Tony Peden.
39 05/03/99 JSB Changed (for the better?) the way configurations are read in.
40 9/17/99 TP Combined force and moment functions. Added aero reference
41 point to config file. Added calculations for moments due to
42 difference in cg and aero reference point
44 ********************************************************************************
45 COMMENTS, REFERENCES, and NOTES
46 ********************************************************************************
47 [1] Cooke, Zyda, Pratt, and McGhee, "NPSNET: Flight Simulation Dynamic Modeling
48 Using Quaternions", Presence, Vol. 1, No. 4, pp. 404-420 Naval Postgraduate
50 [2] D. M. Henderson, "Euler Angles, Quaternions, and Transformation Matrices",
52 [3] Richard E. McFarland, "A Standard Kinematic Model for Flight Simulation at
53 NASA-Ames", NASA CR-2497, January 1975
54 [4] Barnes W. McCormick, "Aerodynamics, Aeronautics, and Flight Mechanics",
55 Wiley & Sons, 1979 ISBN 0-471-03032-5
56 [5] Bernard Etkin, "Dynamics of Flight, Stability and Control", Wiley & Sons,
57 1982 ISBN 0-471-08936-2
59 The aerodynamic coefficients used in this model are:
62 CL0 - Reference lift at zero alpha
63 CD0 - Reference drag at zero alpha
64 CDM - Drag due to Mach
65 CLa - Lift curve slope (w.r.t. alpha)
66 CDa - Drag curve slope (w.r.t. alpha)
67 CLq - Lift due to pitch rate
68 CLM - Lift due to Mach
69 CLadt - Lift due to alpha rate
71 Cmadt - Pitching Moment due to alpha rate
72 Cm0 - Reference Pitching moment at zero alpha
73 Cma - Pitching moment slope (w.r.t. alpha)
74 Cmq - Pitch damping (pitch moment due to pitch rate)
75 CmM - Pitch Moment due to Mach
78 Cyb - Side force due to sideslip
79 Cyr - Side force due to yaw rate
81 Clb - Dihedral effect (roll moment due to sideslip)
82 Clp - Roll damping (roll moment due to roll rate)
83 Clr - Roll moment due to yaw rate
84 Cnb - Weathercocking stability (yaw moment due to sideslip)
85 Cnp - Rudder adverse yaw (yaw moment due to roll rate)
86 Cnr - Yaw damping (yaw moment due to yaw rate)
89 CLDe - Lift due to elevator
90 CDDe - Drag due to elevator
91 CyDr - Side force due to rudder
92 CyDa - Side force due to aileron
94 CmDe - Pitch moment due to elevator
95 ClDa - Roll moment due to aileron
96 ClDr - Roll moment due to rudder
97 CnDr - Yaw moment due to rudder
98 CnDa - Yaw moment due to aileron
100 ********************************************************************************
102 *******************************************************************************/
104 #include <sys/stat.h>
105 #include <sys/types.h>
108 # ifndef __BORLANDC__
109 # include <simgear/compiler.h>
111 # ifdef FG_HAVE_STD_INCLUDES
120 #include "FGAircraft.h"
121 #include "FGTranslation.h"
122 #include "FGRotation.h"
123 #include "FGAtmosphere.h"
125 #include "FGFDMExec.h"
127 #include "FGPosition.h"
128 #include "FGAuxiliary.h"
129 #include "FGOutput.h"
131 /*******************************************************************************
132 ************************************ CODE **************************************
133 *******************************************************************************/
135 FGAircraft::FGAircraft(FGFDMExec* fdmex) : FGModel(fdmex),
152 AxisIdx["PITCH"] = 4;
155 Coeff = new CoeffArray[6];
159 alphaclmin = alphaclmax = 0;
161 numTanks = numEngines = numSelectedFuelTanks = numSelectedOxiTanks = 0;
165 /******************************************************************************/
168 FGAircraft::~FGAircraft(void) {
171 cout << " ~FGAircraft" << endl;
172 if (Engine != NULL) {
173 for (i=0; i<numEngines; i++)
176 cout << " Engine" << endl;
179 for (i=0; i<numTanks; i++)
182 cout << " Tank" << endl;
184 cout << " NumAxes: " << 6 << endl;
185 for (i=0; i<6; i++) {
186 cout << " NumCoeffs: " << Coeff[i].size() << " " << &Coeff[i] << endl;
187 for (j=0; j<Coeff[i].size(); j++) {
189 cout << " Coeff[" << i << "][" << j << "]: " << Coeff[i][j] << endl;
195 cout << " Coeffs" << endl;
197 for (i=0; i<lGear.size(); i++) {
202 /******************************************************************************/
204 bool FGAircraft::LoadAircraft(string aircraft_path, string engine_path, string fname) {
207 string aircraftCfgFileName;
210 AircraftPath = aircraft_path;
211 EnginePath = engine_path;
214 aircraftCfgFileName = AircraftPath + "/" + fname + "/" + fname + ".xml";
216 aircraftCfgFileName = AircraftPath + ";" + fname + ";" + fname + ".xml";
219 FGConfigFile AC_cfg(aircraftCfgFileName);
220 if (!AC_cfg.IsOpen()) return false;
222 ReadPrologue(&AC_cfg);
224 while ((AC_cfg.GetNextConfigLine() != "EOF") &&
225 (token = AC_cfg.GetValue()) != "/FDM_CONFIG") {
226 if (token == "METRICS") {
227 cout << " Reading Metrics" << endl;
228 ReadMetrics(&AC_cfg);
229 } else if (token == "AERODYNAMICS") {
230 cout << " Reading Aerodynamics" << endl;
231 ReadAerodynamics(&AC_cfg);
232 } else if (token == "UNDERCARRIAGE") {
233 cout << " Reading Landing Gear" << endl;
234 ReadUndercarriage(&AC_cfg);
235 } else if (token == "PROPULSION") {
236 cout << " Reading Propulsion" << endl;
237 ReadPropulsion(&AC_cfg);
238 } else if (token == "FLIGHT_CONTROL") {
239 cout << " Reading Flight Control" << endl;
240 ReadFlightControls(&AC_cfg);
241 } else if (token == "OUTPUT") {
249 /******************************************************************************/
251 bool FGAircraft::Run(void) {
252 if (!FGModel::Run()) { // if false then execute this Run()
255 for (int i = 1; i <= 3; i++) vForces(i) = vMoments(i) = 0.0;
264 if (fabs(Position->GetGamma()) < 1.57) {
265 nlf = vFs(eZ)/(Weight*cos(Position->GetGamma()));
268 } else { // skip Run() execution this time
275 /******************************************************************************/
277 void FGAircraft::MassChange() {
278 static FGColumnVector vXYZtank(3);
280 float IXXt, IYYt, IZZt, IXZt;
282 unsigned int axis_ctr;
284 for (axis_ctr=1; axis_ctr<=3; axis_ctr++) vXYZtank(axis_ctr) = 0.0;
286 // UPDATE TANK CONTENTS
288 // For each engine, cycle through the tanks and draw an equal amount of
289 // fuel (or oxidizer) from each active tank. The needed amount of fuel is
290 // determined by the engine in the FGEngine class. If more fuel is needed
291 // than is available in the tank, then that amount is considered a shortage,
292 // and will be drawn from the next tank. If the engine cannot be fed what it
293 // needs, it will be considered to be starved, and will shut down.
295 float Oshortage, Fshortage;
297 for (unsigned int e=0; e<numEngines; e++) {
298 Fshortage = Oshortage = 0.0;
299 for (t=0; t<numTanks; t++) {
300 switch(Engine[e]->GetType()) {
301 case FGEngine::etRocket:
303 switch(Tank[t]->GetType()) {
305 if (Tank[t]->GetSelected()) {
306 Fshortage = Tank[t]->Reduce((Engine[e]->CalcFuelNeed()/
307 numSelectedFuelTanks)*(dt*rate) + Fshortage);
310 case FGTank::ttOXIDIZER:
311 if (Tank[t]->GetSelected()) {
312 Oshortage = Tank[t]->Reduce((Engine[e]->CalcOxidizerNeed()/
313 numSelectedOxiTanks)*(dt*rate) + Oshortage);
319 case FGEngine::etPiston:
320 case FGEngine::etTurboJet:
321 case FGEngine::etTurboProp:
323 if (Tank[t]->GetSelected()) {
324 Fshortage = Tank[t]->Reduce((Engine[e]->CalcFuelNeed()/
325 numSelectedFuelTanks)*(dt*rate) + Fshortage);
330 if ((Fshortage <= 0.0) || (Oshortage <= 0.0)) Engine[e]->SetStarved();
331 else Engine[e]->SetStarved(false);
334 Weight = EmptyWeight;
335 for (t=0; t<numTanks; t++)
336 Weight += Tank[t]->GetContents();
338 Mass = Weight / GRAVITY;
339 // Calculate new CG here.
342 for (t=0; t<numTanks; t++) {
343 vXYZtank(eX) += Tank[t]->GetX()*Tank[t]->GetContents();
344 vXYZtank(eY) += Tank[t]->GetY()*Tank[t]->GetContents();
345 vXYZtank(eZ) += Tank[t]->GetZ()*Tank[t]->GetContents();
347 Tw += Tank[t]->GetContents();
350 vXYZcg = (vXYZtank + EmptyWeight*vbaseXYZcg) / (Tw + EmptyWeight);
352 // Calculate new moments of inertia here
354 IXXt = IYYt = IZZt = IXZt = 0.0;
355 for (t=0; t<numTanks; t++) {
356 IXXt += ((Tank[t]->GetX()-vXYZcg(eX))/12.0)*((Tank[t]->GetX() - vXYZcg(eX))/12.0)*Tank[t]->GetContents()/GRAVITY;
357 IYYt += ((Tank[t]->GetY()-vXYZcg(eY))/12.0)*((Tank[t]->GetY() - vXYZcg(eY))/12.0)*Tank[t]->GetContents()/GRAVITY;
358 IZZt += ((Tank[t]->GetZ()-vXYZcg(eZ))/12.0)*((Tank[t]->GetZ() - vXYZcg(eZ))/12.0)*Tank[t]->GetContents()/GRAVITY;
359 IXZt += ((Tank[t]->GetX()-vXYZcg(eX))/12.0)*((Tank[t]->GetZ() - vXYZcg(eZ))/12.0)*Tank[t]->GetContents()/GRAVITY;
362 Ixx = baseIxx + IXXt;
363 Iyy = baseIyy + IYYt;
364 Izz = baseIzz + IZZt;
365 Ixz = baseIxz + IXZt;
369 /******************************************************************************/
371 void FGAircraft::FMAero(void) {
372 static FGColumnVector vDXYZcg(3);
373 static FGColumnVector vAeroBodyForces(3);
374 unsigned int axis_ctr,ctr;
376 for (axis_ctr=1; axis_ctr<=3; axis_ctr++) vFs(axis_ctr) = 0.0;
378 for (axis_ctr = 0; axis_ctr < 3; axis_ctr++) {
379 for (ctr=0; ctr < Coeff[axis_ctr].size(); ctr++) {
380 vFs(axis_ctr+1) += Coeff[axis_ctr][ctr]->TotalValue();
384 vAeroBodyForces = State->GetTs2b(alpha, beta)*vFs;
385 vForces += vAeroBodyForces;
387 // The d*cg distances below, given in inches, are the distances FROM the c.g.
388 // TO the reference point. Since the c.g. and ref point are given in inches in
389 // the structural system (X positive rearwards) and the body coordinate system
390 // is given with X positive out the nose, the dxcg and dzcg values are
391 // *rotated* 180 degrees about the Y axis.
393 vDXYZcg(eX) = -(vXYZrp(eX) - vXYZcg(eX))/12.0; //cg and rp values are in inches
394 vDXYZcg(eY) = (vXYZrp(eY) - vXYZcg(eY))/12.0;
395 vDXYZcg(eZ) = -(vXYZrp(eZ) - vXYZcg(eZ))/12.0;
397 vMoments(eL) += vAeroBodyForces(eZ)*vDXYZcg(eY) - vAeroBodyForces(eY)*vDXYZcg(eZ); // rolling moment
398 vMoments(eM) += vAeroBodyForces(eX)*vDXYZcg(eZ) - vAeroBodyForces(eZ)*vDXYZcg(eX); // pitching moment
399 vMoments(eN) += vAeroBodyForces(eY)*vDXYZcg(eX) - vAeroBodyForces(eX)*vDXYZcg(eY); // yawing moment
401 for (axis_ctr = 0; axis_ctr < 3; axis_ctr++) {
402 for (ctr = 0; ctr < Coeff[axis_ctr+3].size(); ctr++) {
403 vMoments(axis_ctr+1) += Coeff[axis_ctr+3][ctr]->TotalValue();
408 /******************************************************************************/
410 void FGAircraft::FMGear(void) {
416 // iGear = lGear.begin();
417 // while (iGear != lGear.end()) {
418 // vForces += iGear->Force();
419 // vMoments += iGear->Moment();
423 for (unsigned int i=0;i<lGear.size();i++) {
424 vForces += lGear[i]->Force();
425 vMoments += lGear[i]->Moment();
430 /******************************************************************************/
432 void FGAircraft::FMMass(void) {
433 vForces(eX) += -GRAVITY*sin(vEuler(eTht)) * Mass;
434 vForces(eY) += GRAVITY*sin(vEuler(ePhi))*cos(vEuler(eTht)) * Mass;
435 vForces(eZ) += GRAVITY*cos(vEuler(ePhi))*cos(vEuler(eTht)) * Mass;
438 /******************************************************************************/
440 void FGAircraft::FMProp(void) {
441 for (unsigned int i=0;i<numEngines;i++) {
443 // Changes required here for new engine placement parameters (i.e. location and direction)
445 vForces(eX) += Engine[i]->CalcThrust();
450 /******************************************************************************/
452 void FGAircraft::GetState(void) {
455 alpha = Translation->Getalpha();
456 beta = Translation->Getbeta();
457 vEuler = Rotation->GetEuler();
460 /******************************************************************************/
462 void FGAircraft::ReadMetrics(FGConfigFile* AC_cfg) {
466 AC_cfg->GetNextConfigLine();
468 while ((token = AC_cfg->GetValue()) != "/METRICS") {
469 *AC_cfg >> parameter;
470 if (parameter == "AC_WINGAREA") {
472 cout << " WingArea: " << WingArea << endl;
473 } else if (parameter == "AC_WINGSPAN") {
475 cout << " WingSpan: " << WingSpan << endl;
476 } else if (parameter == "AC_CHORD") {
478 cout << " Chord: " << cbar << endl;
479 } else if (parameter == "AC_IXX") {
481 cout << " baseIxx: " << baseIxx << endl;
482 } else if (parameter == "AC_IYY") {
484 cout << " baseIyy: " << baseIyy << endl;
485 } else if (parameter == "AC_IZZ") {
487 cout << " baseIzz: " << baseIzz << endl;
488 } else if (parameter == "AC_IXZ") {
490 cout << " baseIxz: " << baseIxz << endl;
491 } else if (parameter == "AC_EMPTYWT") {
492 *AC_cfg >> EmptyWeight;
493 cout << " EmptyWeight: " << EmptyWeight << endl;
494 } else if (parameter == "AC_CGLOC") {
495 *AC_cfg >> vbaseXYZcg(eX) >> vbaseXYZcg(eY) >> vbaseXYZcg(eZ);
496 cout << " CG (x, y, z): " << vbaseXYZcg << endl;
497 } else if (parameter == "AC_EYEPTLOC") {
498 *AC_cfg >> vXYZep(eX) >> vXYZep(eY) >> vXYZep(eZ);
499 cout << " Eyepoint (x, y, z): " << vXYZep << endl;
500 } else if (parameter == "AC_AERORP") {
501 *AC_cfg >> vXYZrp(eX) >> vXYZrp(eY) >> vXYZrp(eZ);
502 cout << " Ref Pt (x, y, z): " << vXYZrp << endl;
503 } else if (parameter == "AC_ALPHALIMITS") {
504 *AC_cfg >> alphaclmin >> alphaclmax;
505 cout << " Maximum Alpha: " << alphaclmax
506 << " Minimum Alpha: " << alphaclmin
512 /******************************************************************************/
514 void FGAircraft::ReadPropulsion(FGConfigFile* AC_cfg) {
519 AC_cfg->GetNextConfigLine();
521 while ((token = AC_cfg->GetValue()) != "/PROPULSION") {
522 *AC_cfg >> parameter;
524 if (parameter == "AC_ENGINE") {
526 *AC_cfg >> engine_name;
527 Engine[numEngines] = new FGEngine(FDMExec, EnginePath, engine_name, numEngines);
530 } else if (parameter == "AC_TANK") {
532 Tank[numTanks] = new FGTank(AC_cfg);
533 switch(Tank[numTanks]->GetType()) {
535 numSelectedFuelTanks++;
537 case FGTank::ttOXIDIZER:
538 numSelectedOxiTanks++;
546 /******************************************************************************/
548 void FGAircraft::ReadFlightControls(FGConfigFile* AC_cfg) {
551 FCS->LoadFCS(AC_cfg);
554 /******************************************************************************/
556 void FGAircraft::ReadAerodynamics(FGConfigFile* AC_cfg) {
559 AC_cfg->GetNextConfigLine();
561 while ((token = AC_cfg->GetValue()) != "/AERODYNAMICS") {
562 if (token == "AXIS") {
564 axis = AC_cfg->GetValue("NAME");
565 AC_cfg->GetNextConfigLine();
566 while ((token = AC_cfg->GetValue()) != "/AXIS") {
567 ca.push_back(new FGCoefficient(FDMExec, AC_cfg));
568 DisplayCoeffFactors(ca.back()->Getmultipliers());
570 Coeff[AxisIdx[axis]]=ca;
571 AC_cfg->GetNextConfigLine();
576 /******************************************************************************/
578 void FGAircraft::ReadUndercarriage(FGConfigFile* AC_cfg) {
581 AC_cfg->GetNextConfigLine();
583 while ((token = AC_cfg->GetValue()) != "/UNDERCARRIAGE") {
584 lGear.push_back(new FGLGear(AC_cfg, FDMExec));
588 /******************************************************************************/
590 void FGAircraft::ReadOutput(FGConfigFile* AC_cfg) {
591 string token, parameter;
595 token = AC_cfg->GetValue("NAME");
596 Output->SetFilename(token);
597 token = AC_cfg->GetValue("TYPE");
598 Output->SetType(token);
599 AC_cfg->GetNextConfigLine();
601 while ((token = AC_cfg->GetValue()) != "/OUTPUT") {
602 *AC_cfg >> parameter;
603 if (parameter == "RATE_IN_HZ") *AC_cfg >> OutRate;
604 if (parameter == "SIMULATION") {
605 *AC_cfg >> parameter;
606 if (parameter == "ON") subsystems += ssSimulation;
608 if (parameter == "AEROSURFACES") {
609 *AC_cfg >> parameter;
610 if (parameter == "ON") subsystems += ssAerosurfaces;
612 if (parameter == "RATES") {
613 *AC_cfg >> parameter;
614 if (parameter == "ON") subsystems += ssRates;
616 if (parameter == "VELOCITIES") {
617 *AC_cfg >> parameter;
618 if (parameter == "ON") subsystems += ssVelocities;
620 if (parameter == "FORCES") {
621 *AC_cfg >> parameter;
622 if (parameter == "ON") subsystems += ssForces;
624 if (parameter == "MOMENTS") {
625 *AC_cfg >> parameter;
626 if (parameter == "ON") subsystems += ssMoments;
628 if (parameter == "ATMOSPHERE") {
629 *AC_cfg >> parameter;
630 if (parameter == "ON") subsystems += ssAtmosphere;
632 if (parameter == "MASSPROPS") {
633 *AC_cfg >> parameter;
634 if (parameter == "ON") subsystems += ssMassProps;
636 if (parameter == "POSITION") {
637 *AC_cfg >> parameter;
638 if (parameter == "ON") subsystems += ssPosition;
640 if (parameter == "COEFFICIENTS") {
641 *AC_cfg >> parameter;
642 if (parameter == "ON") subsystems += ssCoefficients;
644 if (parameter == "GROUND_REACTIONS") {
645 *AC_cfg >> parameter;
646 if (parameter == "ON") subsystems += ssGroundReactions;
650 Output->SetSubsystems(subsystems);
652 OutRate = OutRate>120?120:(OutRate<0?0:OutRate);
653 Output->SetRate( (int)(0.5 + 1.0/(State->Getdt()*OutRate)) );
656 /******************************************************************************/
658 void FGAircraft::ReadPrologue(FGConfigFile* AC_cfg) {
659 string token = AC_cfg->GetValue();
661 AircraftName = AC_cfg->GetValue("NAME");
662 cout << "Reading Aircraft Configuration File: " << AircraftName << endl;
663 scratch=AC_cfg->GetValue("VERSION").c_str();
665 CFGVersion = AC_cfg->GetValue("VERSION");
666 cout << " Version: " << CFGVersion << endl;
667 if (CFGVersion != NEEDED_CFG_VERSION) {
668 cout << endl << "YOU HAVE AN INCOMPATIBLE CFG FILE FOR THIS AIRCRAFT."
669 " RESULTS WILL BE UNPREDICTABLE !!" << endl;
670 cout << "Current version needed is: " << NEEDED_CFG_VERSION << endl;
671 cout << " You have version: " << CFGVersion << endl << endl;
678 /******************************************************************************/
680 void FGAircraft::DisplayCoeffFactors(vector <eParam> multipliers) {
681 cout << " Non-Dimensionalized by: ";
683 for (unsigned int i=0; i<multipliers.size();i++)
684 cout << State->paramdef[multipliers[i]];
689 /******************************************************************************/
691 string FGAircraft::GetCoefficientStrings(void) {
692 string CoeffStrings = "";
693 bool firstime = true;
695 for (unsigned int axis = 0; axis < 6; axis++) {
696 for (unsigned int sd = 0; sd < Coeff[axis].size(); sd++) {
700 CoeffStrings += ", ";
702 CoeffStrings += Coeff[axis][sd]->Getname();
709 /******************************************************************************/
711 string FGAircraft::GetCoefficientValues(void) {
712 string SDValues = "";
714 bool firstime = true;
716 for (unsigned int axis = 0; axis < 6; axis++) {
717 for (unsigned int sd = 0; sd < Coeff[axis].size(); sd++) {
723 sprintf(buffer, "%9.6f", Coeff[axis][sd]->GetSD());
724 SDValues += string(buffer);
732 /******************************************************************************/
734 string FGAircraft::GetGroundReactionStrings(void) {
735 string GroundReactionStrings = "";
736 bool firstime = true;
738 for (unsigned int i=0;i<lGear.size();i++) {
739 if (!firstime) GroundReactionStrings += ", ";
740 GroundReactionStrings += (lGear[i]->GetName() + "_WOW, ");
741 GroundReactionStrings += (lGear[i]->GetName() + "_compressLength, ");
742 GroundReactionStrings += (lGear[i]->GetName() + "_compressSpeed, ");
743 GroundReactionStrings += (lGear[i]->GetName() + "_Force");
748 return GroundReactionStrings;
751 /******************************************************************************/
753 string FGAircraft::GetGroundReactionValues(void) {
755 string GroundReactionValues = "";
757 bool firstime = true;
759 for (unsigned int i=0;i<lGear.size();i++) {
760 if (!firstime) GroundReactionValues += ", ";
761 GroundReactionValues += string( lGear[i]->GetWOW()?"1":"0" ) + ", ";
762 GroundReactionValues += (string(gcvt(lGear[i]->GetCompLen(), 5, buff)) + ", ");
763 GroundReactionValues += (string(gcvt(lGear[i]->GetCompVel(), 6, buff)) + ", ");
764 GroundReactionValues += (string(gcvt(lGear[i]->GetCompForce(), 10, buff)));
769 return GroundReactionValues;