(A) Schematic diagrams of the neural circuits generating current-desired heading pairings for chemotaxis and anemotaxis. The copy-and-shift mechanism is only different in how the shift is realised: for chemotaxis, the temporal change of the odour concentration produces turns of different magnitude in a predefined direction, which for anemotaxis the wedge projection neuron (WPN) provide both turning magnitude and direction to steer the animal upwind. The corresponding hypothesised functional map of larvae brain is inserted in the left panel, showing that the olfactory descending neurons LPM-DN may play similar role as the central complex (CX). (B) Schematic diagram explaining the model functions. For chemotaxis, decreasing odour concentration will shift the desired heading from current heading causing the steering circuit to initiate a turn. For anemotaxis, the WPNs subtract the activation of the antennal mechanosensory and motor centre (AMMC) projection neuron (APN) from that of B1 that directly shifts the desired heading to align with the upwind direction. Note that the two mechanisms share a frame of reference. (C) Example behaviours generated by the model. Realistic chemotaxis behaviour is shown (left) in a ‘volcano’ odour landscape. On the right, realistic anemotaxis (magenta path segment) are shown when odour is ‘ON’ vs. undirected motion (black and cyan path segments) when odour is ‘OFF’. Upwind speed and angular velocity of the example agent are shown on the right panel. Note the obvious higher upwind translational velocity and low angular velocity during the presence of the odour indicate surges upwind.