1
0
Fork 0

Compile AI wake numerical core in FG main executable.

AI wake code is still dead code except that it is now compiled with FG.

Input data for wake computations are extracted from the performance database. The data must be specified as follows (values are for illustration only) :
<geometry>
  <wing>
    <span-ft> 100. </span-ft>
    <chord-ft> 12. <chord-ft>
  </wing>
  <weight-lbs> 90000. </weight-lbs>
</geometry>
This commit is contained in:
Bertrand Coconnier 2017-06-10 20:19:43 +02:00
parent cdf299391d
commit b5fe38c1eb
4 changed files with 17 additions and 2 deletions

View file

@ -69,6 +69,9 @@ void PerformanceData::initFromProps(SGPropertyNode *db_node)
_vApproach = db_node->getDoubleValue("approach-speed-kts", _vApproach);
_vTouchdown = db_node->getDoubleValue("touchdown-speed-kts", _vTouchdown);
_vTaxi = db_node->getDoubleValue("taxi-speed-kts", _vTaxi);
_wingSpan = db_node->getDoubleValue("geometry/wing/span-ft", 100.);
_wingChord = db_node->getDoubleValue("geometry/wing/chord-ft", 12.);
_weight = db_node->getDoubleValue("geometry/weight-lbs", 90000.);
}
double PerformanceData::actualSpeed(FGAIAircraft* ac, double tgt_speed, double dt, bool maxBrakes) {

View file

@ -45,6 +45,9 @@ public:
inline double vApproach () { return _vApproach; };
inline double vTouchdown () { return _vTouchdown; };
inline double vCruise () { return _vCruise; };
inline double wingSpan () { return _wingSpan; };
inline double wingChord () { return _wingChord; };
inline double weight () { return _weight; };
double decelerationOnGround() const;
private:
@ -63,6 +66,11 @@ private:
double _rollrate;
double _maxbank;
// Data for aerodynamic wake computation
double _wingSpan;
double _wingChord;
double _weight;
};
#endif

View file

@ -31,10 +31,10 @@
#include <simgear/math/SGQuat.hxx>
#include "AircraftMesh.hxx"
#include <FDM/flight.hxx>
#include "AIWakeGroup.hxx"
#ifndef FG_TESTLIB
#include "AIModel/AIAircraft.hxx"
#else
#include "AIWakeGroup.hxx"
#include "fakeAIAircraft.hxx"
#endif
extern "C" {

View file

@ -112,7 +112,6 @@ set(LARCSIM_SOURCES
ls_gravity.c
ls_init.c
ls_interface.c
ls_matrix.c
ls_model.c
ls_step.c
navion_aero.c
@ -136,6 +135,11 @@ set(SOURCES
${SP_FDM_SOURCES}
ExternalNet/ExternalNet.cxx
ExternalPipe/ExternalPipe.cxx
AIWake/AircraftMesh.cxx
AIWake/WakeMesh.cxx
AIWake/AeroElement.cxx
AIWake/AIWakeGroup.cxx
LaRCsim/ls_matrix.c
)
if(ENABLE_UIUC_MODEL)