Glider experiments

Glider Experiments in Python.

View the Project on GitHub

\[\newcommand{\vect}[1]{\underline{#1}} \newcommand{\est}[1]{\hat{#1}} \newcommand{\err}[1]{\tilde{#1}} \newcommand{\pd}[2]{\frac{\partial{#1}}{\partial{#2}}} \newcommand{\transp}[1]{#1^{T}} \newcommand{\inv}[1]{#1^{-1}} \newcommand{\norm}[1]{|{#1}|} \newcommand{\mat}[1]{\mathbf{#1}} \newcommand{\jac}[3]{\frac{\partial{#1}}{\partial{#2}}\bigg\vert_{#3}}\]

Optimal glider trajectories using direct collocation method and non-linear programming

We’re using opty to compute optimal trajectories for a glider.

4D model

We describe our glider by a simple dimension 4 model (implementation).

\(x, y, z\) are the coordinates of the glider’s center of gravity in an euclidian space, \(v_a\) is its airspeed, \(\phi\) and \(\psi\) are respectively roll and heading angles. \(w_x, w_y, w_z\) are the wind velocity’s components.

Using \(X = \transp{\begin{pmatrix} x & y & z & \psi \end{pmatrix}}\) as state vector and \(U = \transp{\begin{pmatrix} v_a & \phi \end{pmatrix}}\) as control input, we obtain the following state space representation:

\[\begin{align} \dot{X} &= f(X, U) \\ \begin{pmatrix} \dot{x} \\ \dot{y} \\ \dot{z} \\ \dot{\psi}\end{pmatrix} &= \begin{pmatrix} v_a \cos{\psi} + w_x \\ v_a \sin{\psi} + w_y \\ \dot{z}_a(v_a, \phi) + w_z \\ \frac{g}{v_a} \tan{\phi} \end{pmatrix} \end{align}\]

Lines 1 and 2 of the dynamics are pure kinematics. Line 3 (ref) is a polynomial model of the glider sink rate as a function of airspeed and bank angle.

\[CL_0 = \frac{K}{v_a^2}\] \[\dot{z}_a(v_a, \phi) = -v_a(\frac{CD_0}{CL_0}+\frac{B*CL_0}{\cos^2{\phi}})\]

implementation

The model is fitted in simulation on the trajectories of an aerodynamically correct simulator (see). In real life, it would have to be fitted on real flight trajectories (trimmed at different velocities and bank angles).

Line 4 is from a coordinated turn hypothesis (no slip turn).

Thermaling

The thermal is described by a wharignton model:

\[w_z = w_{z0} e^{\frac{-r^2}{r_0^2}}\]

As objective function, we tested both altitude gain (\(J = z(t_f)\)) and average altitude (\(J = \Sigma_{k=0}^n z(t_k)/n\)) (see).

Fig1. Thermaling

Slope soaring

Here we use a simple analytic model of wind blowing across a cylindrical obstacle (see).

The objective function can be the same as for thermaling (final or mean altitude).

Fig2. slope soaring

The solver returns a convincing trajectory that is similar to the one a human pilot would perform and consisting in lines parallel to the ridge, connected by headwind turns, the lines going further away from the ridge as altitude increases.

2D Wind field

We can fly to a waypoint by using the average distance to the waypoint as objective function (see).

Fig3. going to waypoint without wind

We are now able to find an optimal trajectory to a waypoint in a 2D wind gradient.

Fig4. going to waypoint in a 2D wind field

The trajectory on figure 4 leans north to find tailwind rather than going straight and experiencing headwind.

Cross country

If we add a constraint on altitude (forbiding us from hitting ground), we can find a trajectory that hunts thermals along the way.

Fig5. Cross country

If we give it a weak thermal, it might decide to skip it and instead gain altitude by performing loops in the stronger one.

Fig6. The trajectory favors strong thermals

What now?