27#include <simgear/structure/SGSharedPtr.hxx>
28#include <simgear/math/SGVec3.hxx>
29#include <simgear/math/SGGeoc.hxx>
30#include <simgear/math/SGGeod.hxx>
31#include <simgear/math/SGQuat.hxx>
40 collPt.resize(
nelm, SGVec3d::zeros());
41 midPt.resize(
nelm, SGVec3d::zeros());
46 SGVec3d pos = _pos * SG_METER_TO_FEET;
47 SGGeoc geoc = SGGeoc::fromCart(pos);
48 SGQuatd Te2l = SGQuatd::fromLonLatRad(geoc.getLongitudeRad(),
49 geoc.getLatitudeRad());
53 SGVec3d pt =
elements[
i]->getCollocationPoint();
54 collPt[
i] = pos + Te2b.backTransform(pt);
55 pt =
elements[
i]->getBoundVortexMidPoint();
56 midPt[
i] = pos + Te2b.backTransform(pt);
63 std::vector<double> rhs;
64 rhs.resize(
nelm, 0.0);
72 for (
int k=1; k<=
nelm; ++k)
77 moment = SGVec3d::zeros();
80 SGVec3d mp =
elements[
i]->getBoundVortexMidPoint();
86 SGVec3d Fi = rho*
Gamma[
i+1][1]*cross(v-vel,
89 moment += cross(mp, Fi);
SGVec3d getInducedVelocityAt(const SGVec3d &pt) const
SGVec3d GetForce(const AIWakeGroup &wg, const SGVec3d &vel, double rho)
void setPosition(const SGVec3d &pos, const SGQuatd &orient)
AircraftMesh(double _span, double _chord, const std::string &name)
std::vector< AeroElement_ptr > elements
SGVec3d getInducedVelocityAt(const SGVec3d &at) const
WakeMesh(double _span, double _chord, const std::string &aircraft_name)