{'fraction_non_alphanumeric': 0.05006411223412279, 'fraction_numerical': 0.01940337909186906, 'mean_word_length': 4.428147389969293, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 10, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 3, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Sensory feedback in a bump attractor model of path integration

The mammalian spatial navigation system makes use of several different sensory information channels. This information is then converted into a neural code that represents the animal's current position in space by engaging place cell, grid cell, and head direction cell networks. In particular, sensory landmark (allothetic) cues can be utilized in concert with an animal's knowledge of its own velocity (idiothetic) cues to generate a more accurate representation of position than (idiothetic) path integration provides on its own (Battaglia et al, 2004). We develop a computational model that merges path integration with information from external sensory cues that provide a reliable representation of spatial position along an annular track. Starting with a continuous bump attractor model, we allow for the possibility of synaptic spatial heterogeneity that would break the translation symmetry of space. We use asymptotic analysis to reduce the bump attractor model to a single scalar equation whose potential represents the impact of heterogeneity. Such heterogeneity causes errors to build up when the network performs path integration, but these errors can be corrected by an external control signal representing the effects of sensory cues. We demonstrate that there is an optimal strength and decay rate of the control signal when cues are placed both periodically and randomly. A similar analysis is performed when errors in path integration arise from dynamic noise fluctuations. Again, there is an optimal strength and decay of discrete control that minimizes the path integration error.


Introduction
Animals have a remarkable ability to accurately navigate over large distances (Geva-Sagiv et al, 2015). For instance, birds can utilize neural systems that sense the earth's magnetic field, orienting themselves geocentrically (Cochran et al, 2004;Wu and Dickman, 2012). This is in contrast to the systems studied in mammalian species, who are typically shown to use path integration (Etienne et al, 1996;McNaughton et al, 2006). Path integration models of spatial navigation assume mammals have knowledge of their direction and speed of motion, which networks of the brain can then integrate to encode the path of their idiothetic motion (Samsonovich and McNaughton, 1997). However, there are a number of potential sources of error to this mechanism. The nervous system itself is prone to a wide variety of noise sources due to channel fluctuations, synaptic failures, or even stochastic network-wide events (Faisal et al, 2008). This could lead to faulty communication of velocity or head direction signals, or it could corrupt the storage of the position signal. Furthermore, the network that integrates the velocity signal may be comprised of architecture that is heterogeneous, providing an imperfect summation of velocity inputs (Brody et al, 2003). Any inaccuracy in the represented position or velocity will be compounded over time, as the neural code continues to trace the animal's true path (Knierim et al, 1995;Valerio and Taube, 2012). Fortunately, path integration is not the sole navigational technique of the mammalian brain; landmarks detected by the sensory system help anchor and correct the integrated velocity signal (Fig. 1A) (Collett and Graham, 2004;Etienne et al, 1996;Solstad et al, 2008).
Several experiments have demonstrated that mammals' representation of space is sharpened in the presence of sensory cues (Aikath et al, 2014;Battaglia et al, 2004;Ulanovsky and Moss, 2011;Zhang et al, 2014). Experiments typically compare place fields of individuals cells -spatial locations where the cell becomes active -in the presence and absence of sensory landmarks (e.g., steel brush or ticking clock; Fig. 1B). For instance, Battaglia et al (2004) recorded from hippocampal place cells in rats moving on an annular track. When there were no sensory cues along the track, the place fields of individual cells differed substantially, depending on whether the rat was moving clockwise or counterclockwise around the annulus. This suggests there was some drift in animals' neural representation of their position. However, when several position landmarking cues were placed along the track, the clockwise and counterclockwise place fields of individual cells were considerably correlated. This suggests the sensory cues tightened the navigation systems fine representation of the animal's spatial position. Similar effects have been observed in brown bats, whose echolocation signals provide a brief burst of rich sensory information, sharpening the animal's place fields (Ulanovsky and Moss, 2011). Thus, sensory cues appear to provide a correction mechanism for the many sources of error that disrupt position representation and broaden place fields.
We bring these two features of the mammalian navigation system -path integration and sensory feedback -together into a single model. Our main focus is the role sensory feedback can play in correcting the path integration signal. Errors in the path integration signal will arise, in our model, due to internal disruptions of an accurately delivered velocity input. The model represents position by utilizing a perturbation of a continuous bump attractor (Amari, 1977;Zhang, 1996). Bump states arise in these models due to a combination of strong local excitation and broadly tuned inhibitory feedback (Wang, 1999). In translation symmetric networks, bumps can be formed with their center of mass at any location. However, such well-balanced architecture is unlikely to occur in actual networks of the brain, which tend to be spatially heterogeneous (Brody et al, 2003;Renart et al, 2003). Such symmetry-breaking in the bump attractor network leads to system states that drift toward a finite number of discrete attractors, so the long term dynamics are weakly correlated with the input signal (Itskov et al, 2011;Zhang, 1996). Furthermore, any dynamic fluctuations in the voltage or synaptic signals of the network can lead to diffusive wandering of the bump state that will also degrade its signal representation (Burak and Fiete, 2012;Compte et al, 2000;. Our study mainly focuses on how external control can reduce the deleterious effects of both spatial heterogeneity and noise, ultimately improving long term accuracy of the network's path integration. Our model is intended to describe the neural activity of place cell networks in the hippocampus (O' Keefe and Burgess, 1996). Based on a simplified version of the model by Samsonovich and McNaughton (1997), neural activity bumps are propelled around the network by external velocity inputs that introduce spatial asymmetry into the balance of excitation and inhibition. A similar mechanism was utilized by Burak and Fiete (2009) in a two-dimensional model of grid cell activity. Thus, this framework is a well accepted model of position encoding cells in hippocampus, entorhinal cortex, and the vestibular system (Zhang, 1996). Since we are modeling motion along an annulus (Fig. 1B), we have restricted the network to a one-dimensional periodic domain. Sensory cues are assumed to provide a reliable estimate of the animal's true current position. This position is then compared with the place cell network's estimate of position. Any discrepancy in the position estimate is then translated into a corrective velocity input, which is added to the baseline velocity input (Fig. 1A). Even when the cues occur discretely in space, this mechanism works well for reducing the long term error in the position estimate.
In section 2, we introduce the neural field model of spatial navigation, which combines path integration and sensory cue feedback. Next, we derive a low-dimensional approximation for the dynamics of bump position in the neural field model (section 3). This reduction reveals the relative influence of velocity inputs, sensory feedback, and heterogeneity on the animal's perceived position of its current location. Ultimately, this allows us to calculate the impact of various control strategies on the error between the Velocity input v(t)

Sensory cues
Error comparison Place cell network position output annulus with sensory cues Fig. 1 Mammalian spatial navigation network with sensory feedback. The animal utilizes its own velocity to update its remembered position (path integration) and corrects this memory with sensory cues that serve as position landmarks.
(A) Schematic of the underlying neuronal network demonstrates the place cell network receives direction input from the animal's velocity signal v(t). Its position estimate is compared with the true position read-out from a sensory cue, and this error is then used to generate a control input signal vc(t) back into the place cell network. (B) Illustration of the experiments by Battaglia et al (2004), showing an annular track with various object placed in the environment to provide the animal with sensory cues.
animal's perceived position and true position (section 4). Our main finding is that there is an optimal control strength at which the long term error of the network is minimized. Our findings were similar in the case that errors arose due to dynamic noise fluctuations (subsection 4.2), rather than synaptic heterogeneities (subsection 4.1). In this case, the low-dimensional approximation of the neural field is a stochastic differential equation whose variance we can evaluate explicitly.
2 Sensory control in velocity-integrating place cell networks We employ a neural field model of velocity integration that sustains a bump attractor of neural activity in the absence of any inputs. Amari (1977) pioneered the scalar neural field model as a reduction of the excitatory-inhibitory model of Wilson and Cowan (1973), but the incorporation of velocity inputs that shift the bump around the spatial domain is more recent. Originally developed as a model of the head direction system (Zhang, 1996), velocity-integrating networks introduce an external input that alters the shape of the recurrent architecture (McNaughton et al, 1991). As a result, a moving bump, rather than a stationary bump, becomes the stable solution to the model equations. This model has since been extended to account for place fields and grid cell fields in planar systems (Burak and Fiete, 2009;Samsonovich and McNaughton, 1997). The fully general form of our neural field model is given where u(x, t) denotes the total synaptic activity at a position x ∈ [−π, π] at some point in time t. While x labels the position of neurons in the network it also corresponds to location in the environment, so the domain Ω = [−π, π] is taken to be periodic as it represents an annular track (Fig. 1B). The function w(x, y) represents the synaptic connectivity between neurons, which we model as a translationally symmetric unimodal function w 0 , modified by spatial heterogeneity w u or odd asymmetry φ, so w(x, y) : with σ, φ 1. Note that in the limit σ → 0 and φ → 0, we obtain w(x, y) = w 0 (x − y), a distancedependent even function. However, in the fully general case (σ > 0 and/or φ > 0), it is straightforward to see that the function w(x, y) need not be distance-dependent or even symmetric. In particular, when Velocity-integration with moving bump attractors in the neural field model (2.1) with a Heaviside firing rate function (2.8) with threshold θ = 0 and a cosine base weight function w 0 (x) = cos(x). (A) Bump of neural activity u(x, t) perfectly integrates velocity inputs in the case of no heterogeneity (σ = 0) and no noise ( = 0), showing the animal's true position (solid line) is perfectly tracked by the center of mass of the bump (dashed). (B) In a heterogeneous network (σ = 0.1 with wu = sin(x)), the bump initially moves too fast due to a discrete attractor of the input-free system at x = π/2, so the bump's center of mass is mismatched with the true position of the animal. (C) In the presence of spatiotemporal noise ( = 0.2 with cosine correlations C(x) = cos(x)), the bump wanders diffusively so the encoded position tends to slowly distance itself from the true position. Here the external velocity input is constantṽ(t) = 0.1. Numerical simulations are performed using an Euler timestep with dt = 0.1 and a trapezoidal rule on the integral with dx ≈ 0.003. σ > 0, discrete attractors form in the network (2.1) whereby bumps tend to drift away from their initial position to a finite number of linearly stable locations (Itskov et al, 2011;Zhang, 1996). We consider this to be a major source of error in the network, since near-perfect integration of the velocity inputs could be achieved if w(x, y) = w 0 (x − y). For ease of analysis, the translationally symmetric function is typically taken to be a cosine w 0 (x) := cos x. We will allow w u to be arbitrary, by representing it as a series of N Fourier modes w u (x) := N n=1 α n cos(nx) + β n sin(nx); α n = β n = 0; α 2 n = β 2 n = σ 2 n . (2. 3) The coefficients α n , β n are random variables drawn from the normal distribution with mean zero and variance σ n . Velocity inputs are represented by the shifting function w v (x − y) := −w 0 (x − y) as in the original head direction system model (Zhang, 1996) and recent grid cell models (Burak and Fiete, 2009). In the absence of any heterogeneity or asymmetry, the sum w(x, y) +ṽ(t) · w v (x − y) would be translation symmetric but not even symmetric in general. This asymmetry produces a moving bump as the solution to (2.1) that will move at a speed given by |ṽ(t)| (Fig 2A). Incorporating heterogeneity, σ > 0, the system is no longer translation symmetric, and a moving bump will not move at the same speed as the velocity input |ṽ(t)| (Fig. 2B). Thus, assuming a sensory mechanism for correcting the place cell's encoded position when a cue is encountered, take the velocity input to bẽ v(t) := v(t) + v c (t), the sum of the animal's true velocity v(t) and an external control signal v c (t). This is meant to account for the improved place representation observed when animals can employ information about sensory landmarks (Aikath et al, 2014;Battaglia et al, 2004;Ulanovsky and Moss, 2011). As shown in the schematic in Fig. 1A, we assume there is a network that can access the place cell network's perceived position ∆(t) via a readout of the center of mass of neural activity (Deneve et al, 1999) (2.4) The present positional error is then computed by comparing the perceived position ∆(t) to the animal's actual position given by a time integral of the velocity input so the error (2.5) which will be positive (negative) if the estimated position is to the left (right) of the true position. Note, we extend the domain x ∈ [−π, π] to compute (2.5) in cases where the closest distance between ∆ T and ∆ is across the boundary cuts at x = ±π. The error r(t) is then translated either into a continuous velocity control signal v c (t) = λr(t) = λ · (∆ T (t) − ∆(t)), (2.6) or a discrete control signal given by where sensory cues occur at times t k and λ and τ determine the strength and time decay of control. As we will show, in the case of continuous control (2.6) strengthening the sensory feedback λ always leads to a reduction of the error. This is not the case for discrete control (2.7), since the previous sensory cue at t k < t becomes less relevant as t increases toward t k+1 . One of the main goals of this study is to explore how the spacing between subsequent cues t k+1 − t k determines how strong λ the control signal should be.
The nonlinearity f is a firing rate function taken to be sigmoidal (Wilson and Cowan, 1973) f (u) := 1 1 + e −γ (u−θ) where γ is the gain and θ is the firing threshold. For ease in analysis, we will often consider the high gain limit γ → ∞ so that f becomes a Heaviside step function of the form Lastly, we also will consider the impact of the additive noise increment dW (x, t). Spatially extended Langevin equations of the form (2.1) have become a common model of the effects of fluctuations in largescale neuronal networks (Bressloff, 2012). The noise term is a spatially filtered spatiotemporal white noise process where F is the spatial filter and dY (x, t) is a spatially and temporally white noise increment. With these definitions, the mean and variance can be calculated as dW (x, t) = 0 and dW (x, t) dW (y, s) = C(x − y)δ(t − s), where δ(t) is the delta function and C is the spatial correlation given in terms of the filter F as As an example, consider F(x) = cos(x) + sin(x). Then, the spatial correlation C can be computed explicitly as cos 2 (x ) cos(x) cos(y) + sin 2 (x ) sin(x) sin(y)dx = π cos(x) cos(y) + sin(x) sin(y) = π cos(x − y) =: C(x − y).
As we demonstrate, the control introduced to account for the impact of synaptic spatial heterogeneity can also be utilized to decrease errors brought about by spatiotemporal noise (Fig. 2C). We demonstrate the impact of discrete control (2.7) on the dynamics of neural fields that imperfectly integrate their velocity inputs, comparing to a perfectly integrating network for reference ( Fig. 3A). Integrating (2.7), we find that the discrete perturbations to the velocity signal are given by a series of exponentially decaying impulses (2.9) Furthermore, note in the limit of the timestep t k+1 − t k between subsequent cues tending to zero and τ → 0, the equation for discrete control (2.7) approaches that of the continuous control (2.6). Assuming for demonstration that cues are spaced in such a way that an animal encounters one every 2 units of time (t k+1 − t k = 2 for all k = 1, ..., N c − 1), we demonstrate in a single realization that a network with spatially heterogeneous coupling can recover its ability to correctly integrate velocity (Fig. 3B). In a similar way, networks with additive noise can have their velocity integration corrected by the sensory feedback signal given by discrete control impulses (2.9) as shown in Fig. 3C. In the next section, we will analyze the impact of heterogeneity and noise on the position of the bump in a low-dimensional approximation of the bump's center of mass ∆(t).

Analysis and low-dimensional reduction of bump solutions
To develop an understanding of the impact the sensory feedback signal has on the statistics of bump position in (2.1), we derive a low-dimensional approximation of the model that projects the dynamics down to a single equation describing bump position ∆(t). Our analysis is adapted from recent studies of stochastic neural field equations assuming the impact of perturbations to a translationally symmetric neural field can be separated into slow timescale changes to the position of patterns along with fast timescale changes to the profile of patterns (Bressloff and Kilpatrick, 2015;Bressloff and Webber, 2012;. Such analysis must begin by constructing the patterns of the unperturbed system. In our case we take the velocity inputs, heterogeneity, asymmetry, and noise all to be perturbations to a translationally symmetric system (taking v = σ = φ = = 0 in (2.1)). While it is possible to develop exact analytical results in the case wherein we break the symmetry of this model, which we show, it is also helpful to collect the effects of all the possible perturbations to (2.1) into a single scalar equation. Doing so makes it more clear how such perturbations interact.

Stationary bump solutions to the translation symmetric network
We begin by assuming the homogeneous connectivity function w 0 (x) in (2.2) satisfies evenness (w 0 (x) = w 0 (−x)) and there is no heterogeneity (σ = 0) or asymmetry (φ = 0) in w(x, y). In this case, it is possible to show there is a stationary bump solution u(x, t) = U (x) with U (x) > θ over an excited region x ∈ [a 1 , a 2 ] (Amari, 1977;Ermentrout, 1998) in the absence of velocity inputs (ṽ ≡ 0) in (2.1). Furthermore, the weight function is translation symmetric since so there will be a continuum of bump locations associated with any single bump solution to (2.1) in this case. Stationary bumps satisfy the equation Note that U (x + s) will also be a solution for any s, since A change of variables y + s → z yields and another change of variables x + s → x yields which is precisely the equation (3.2). Now, taking the high gain limit γ → ∞, we employ the Heaviside firing rate function (2.8). Doing so allows us to generate an equation for the bump width d = a 2 − a 1 as in Amari (1977). In this case, the equation (3.2) becomes We then use the threshold crossing conditions U (a 1 ) = U (a 2 ) = θ and evenness of w 0 (x) to derive Note that the evenness of w 0 (x) allows us to manipulate the above equations so they are the same equalities. If evenness did not hold, the above pair of equations would each be different and we would have an overdetermined system for the bumpwidth d, meaning stationary bumps do not exist. Thus, For example, in the case of a cosine weight w 0 (x) = cos(x), we have As mentioned, the threshold conditions specify the width d of the bump. Translation symmetry allows the position of the bump to be anywhere x ∈ [−π, π], which allows this network to integrate and store velocity inputs as a position memory. As mentioned in section 2, the position of the bump will be given by its center of mass (2.4), which for unimodal and even symmetric bumps will also be given by the peak For example, in the case of cosine weight functions w 0 (x) = cos(x), there is an even symmetric solution such that a 1 = −a and a 2 = a, so cos(x − y)dy = 2 sin(a) cos(x). (3.5) Thus, the location of the bump as computed by (3.4) is ∆ = 0. Similarly, if we compute the center of mass using (2.4), we find which is consistent.

Perfect velocity integration by traveling bumps
Now we explore the impact of velocity inputs (v(t) = 0) on the translationally symmetric network (w(x, y) = w 0 (x − y)). For now, we assume constant velocity inputs, v(t) ≡ v 0 . Assuming the bump subsequently moves at a constant speed c, we look for a traveling wave solution u(x, t) = U (ξ) where ξ = x − ct. We will show that the traveling wave speed c is exactly equal to the velocity input amplitude v 0 , under the assumption that w v (x) = −w 0 (x) in (2.1). Plugging these conditions into (2.1), we find Now plugging in our requirement that the velocity portion of the weight function w Under the assumption that the function U (ξ) satisfies the equality (3.2), we have differentiate this equation to yield Canceling the (3.2) portion of (3.6), we find that The equality (3.8) follows from (3.7) as long as we set c ≡ v 0 . Another implication of our analysis is that the shape of the bump U (ξ) will be the same no matter what c (equivalently v 0 ) is, suggesting there will be no relaxation time if the external drive v 0 were to be changed abruptly. In this way, we can expect the translation symmetric version of the network (2.1) to integrate inputs perfectly as was originally proposed by Zhang (1996).
3.3 Imperfect integration due to heterogeneity, asymmetry, and noise Now that we have explored the dynamics of the perfect velocity-integrating network, we study the impact of introducing heterogeneities (σ), asymmetry (φ), and noise ( ) into the network (2.1). Rather than deriving exact solutions as we did for the translationally symmetric system, we take a perturbative approach under the assumption that alterations to the symmetric system are weak. Following perturbation methods originally developed for the study of front propagation in reaction-diffusion systems (Panja, 2004;Sagués et al, 2007), we employ a separation of time scales to decompose these effects into a slowly evolving displacement ∆(t) of the bump from its uniformly translating position and perturbations to the bump profile Φ(x, t). This yields the following decomposition where we assume σ, φ,ṽ(t) ∼ O( ). Plugging the ansatz (3.9) into (2.1) and expanding in powers of , we find that at O(1), the system has a stationary bump solution given by (3.2). At linear order O( ), we find the following equation where L is a linear functional given by and its adjoint operator To ensure a solution to (3.10), we require that the inhomogeneous portion of the equation be orthogonal to the nullspace of the adjoint operator L * . Indeed, the nullspace of L * is spanned by 2), which we can verify using integration of parts (3.11) The last line holds by differentiating the bump existence equation as in (3.7). Now, by taking inner products of the null vector ϕ with the O( ) equation (3.10), we can derive an evolution equation for ∆(t), the position of the bump where we have applied the equation (3.7). We can simplify the equation (3.12) further by isolating d∆(t) to yield the stochastic differential equation where the impact of synaptic spatial heterogeneities is described by the nonlinear function and the noise term has been projected to a temporal white noise process W(t) with mean zero ( W(t) = 0) and variance W(t) 2 = Dt with associated diffusion coefficient Setting v c (t) ≡ 0 and v(t) ≡ v 0 (constant), the dynamics of the position variable ∆(t) can be equivalently described by a potential function so ∆(t) will descend the gradient of V (∆) toward its local minima. Note that in the case F (∆) ≡ φ ≡ W(t) ≡ 0, the control term will vanish v c (t) ≡ 0 and the bump will perfectly integrate the velocity input, ∆(t) = t 0 v(s)ds. We find that the low dimensional approximation is in excellent agreement with simulations of the full system in this case of perfect integration (Fig. 4A).
Ignoring the control for the time being in (3.13), we can also identify how different network imperfections contribute to the resultant error in path integration. To do so, we simply compute the error function r(t) = ∆ T (t) − ∆(t) as given in (2.5). First, note that in a network with asymmetry φ = 0 and no heterogeneity F (∆) ≡ 0, the long term error accumulates linearly in time so the animal's true position ∆ T will be behind (in front of) the estimated position ∆ when φ > 0 (φ < 0). We will demonstrate the impact external control via sensory cues has upon this error in section 4. Errors due to arbitrary heterogeneities are more difficult to express explicitly. In general, we can express the solution to (3.13) implicitly in this case if we assume the velocity is constant v(t) ≡ v 0 : If indeed the function G(∆) is invertible, then we can express ∆(t) = G −1 (t), so (3.18) We will demonstrate some cases where we can perform this calculation explicitly in subsection 3.4. Note that the main impact of heterogeneities is to establish a finite number of discrete attractors, in the velocity input-free system, so that bumps drift toward these locations (Fig. 4B). Even in the velocitydriven network, spatial heterogeneities lead to a sinuous trajectory of the bump that is mismatched to a straight integration of velocity input (Fig. 4C,D). Lastly, note that the impact of noise can be quantified by averaging across realizations of the stochastic process While the mean position will be the same for the true and encoded positions (∆ T (t) − ∆(t) = 0), the variance will grow linearly in time where the diffusion coefficient D can be computed using (3.15). Previous work has characterized the impact of the bump profile and spatiotemporal noise correlation structure on the diffusion coefficient D, providing some explicit calculations . In general, the main effects of noise perturbations on the bump will be experienced by the bump edges, where the activity variable u(x, t) crosses the firing rate threshold θ. We now provide some explicit calculations demonstrating the impact of spatial heterogeneity on the long term position of the bump.

Explicit results for spatially heterogeneous networks with a Heaviside firing rate
Several previous studies have characterized the impact of periodic microstructure on the propagation of waves in neural media (Bressloff, 2001;Coombes and Laing, 2011;Kilpatrick et al, 2008). Typically, periodic heterogeneities can slow down waves and even cause propagation failure. We extend these previous results here, showing that the low dimensional equation (3.13) allows us to estimate the location of bifurcations separating detectable and undetectable constant velocity inputs v(t) ≡ v 0 . Again, we are ignoring the impact of control at this point, studying its effects in more detail in section 4. To allow for fully general weight heterogeneities, we consider the decomposition given by (2.3). Thus, we can integrate each of the Fourier modes independently to derive the function F (∆) given by (3.14). Furthermore, we assume a cosine for the homogeneous weight function w 0 (x) = cos(x) and a Heaviside firing rate (2.8).
Thus, we can write the resultant heterogeneity in general as where C n = n cos(na) − cot(a) sin(na) n 2 − 1 , (3.20) and notice in the special case n = 1, we can take the limit n → 1 to find C 1 = sin(a) cos(a) − a 2 sin(a) . (3.21) We can explicitly compute the solution to (3.13) in some special cases of the heterogeneity F (∆), defined by (3.19). In particular, we focus on a single cosine-shaped heterogeneity so that α m = 1, α n = 0 (n = m), and β n = 0 (∀n). Furthermore, we assume a constant input velocity v(t) ≡ v 0 , so that the scalar equation (3.13) for ∆(t) is given bẏ where κ = σC n . Now, assuming ∆(0) = 0 the equation (3.22) can be integrated to yield an explicit solution There is a partition in (κ, v 0 ) parameter space given by the equation |κ| = |v 0 |. When |κ| > |v 0 |, so the arguments κ 2 − v 2 0 of the square roots in (3.23) are positive, then there is a family of fixed points of the equation (3.22), so that the bump position ∆(t) will eventually become pinned to a single position. In this case, velocity inputs are not detectable by the network, since they do not result in the propagation of a bump. Consistent with this, the equation (3.23) has a defined limit at t → ∞, The general formulas for all equilibria of (3.22) are given bȳ On the other hand, when |κ| < |v 0 |, the heterogeneity F (∆) will not lead to pinning of bumps, so bump will propagate indefinitely in response to velocity inputs. However, the heterogeneity will ultimately reduce the speed of propagation of bumps, as found in previous studies of periodically heterogeneous neural fields (Bressloff, 2001;Coombes and Laing, 2011;Kilpatrick et al, 2008). We can determine the average reduction in the bump's speed by calculating the time T at which ∆(t) crosses ∆ = 2π/m, completing one period of the heterogeneity sin(m∆): which means that the average speed of the bump v b is given similar to the speed scaling formulas found in Bressloff (2001); Coombes and Laing (2011). This allows us to directly compute the curve in parameter space at which wave propagation failure occurs, |v 0 | = |κ| as stated above. Note that the bump speed (3.27) depends on the frequency and amplitude of the heterogeneity through the term κ = σ cot(a) sin(ma) − m cos(ma) m 2 − 1 . (3.28) Thus, we can approximate coarse time-average error in path integration for this network as (3.29) A more precise estimate is obtained by using the formula for ∆(t) given by (3.23). We demonstrate the accuracy of this full approximation in Fig. 4C,D. Bump position approximations (3.23) and average speed approximation computed from (3.27) are compared with the full neural field model (2.1) are given in Fig. 5. We find the low-dimensional approximation (3.22) is in excellent agreement with simulations.
In particular, the points in parameter space at which propagation failure occur are well matched, and the sinuous trajectory of the bump is well tracked by our low dimensional theory. This suggests we can gain many insights concerning the full model by analyzing this simpler equation (3.13). As noted above, the existence of spatial heterogeneities in networks can lead to pinning or a reduction in speed of propagating bumps, which should be accurately tracking velocity-input. However, several previous experiments have suggested that sensory feedback is incorporated into the neural representation of spatial navigation (Battaglia et al, 2004;Hardcastle et al, 2015;Ulanovsky and Moss, 2011;Zhang et al, 2014). As discussed in section 2, we propose a simple external control mechanism that incorporates a comparison of an animal's current estimate of position with an external sensory cue (Fig. 1A). In section 4, we will demonstrate the improvement in position encoding afforded by sensory feedback control. Furthermore, we will show that there is an optimal weighting and timescale of control feedback when sensory cues appear discretely in space or time.

Incorporating sensory cues with online control
Recent experimental studies have shown that the presence of sensory landmarks reduces the size of mammalian place fields as compared to the case of no landmarks (Aikath et al, 2014;Battaglia et al, 2004;Zhang et al, 2014). Interestingly, such a reduction in place field size can occur quite quickly, in response to the temporary presence of sensory information, as show in echolocating bats (Ulanovsky and Moss, 2011). Note here, we are referring to sensory information beyond the animal's proprioceptive experience of its own motion. Specifically, we are referring to objects placed along the track of navigation that may provide visual, auditory, or olfactory feedback (Fig. 1B). This suggests an online interaction between the sensory system and the path integration system that passes some positional information acquired by sensory cues (Tsao et al, 2013). We suggest that such a mechanisms could counteract errors in position encoding that could arise due to synaptic heterogeneity (Brody et al, 2003;Hansel and Mato, 2013;Itskov et al, 2011) or noise (Burak and Fiete, 2012;Compte et al, 2000;Laing and Chow, 2001). However, when cues occur discretely in space, tuning the strength of feedback introduces a tradeoff between the immediate benefits of recent cues and the deleterious influence of older irrelevant cues. We explore this in the low-dimensional model (3.13) derived in section 3.

Reducing error due to network asymmetry and heterogeneity
We first examine the case of instantaneous cues and updates, modeled as a continuous update to the position, as described by (2.6). This would be the case in which landmark cues are continuously apparent to an animal, allowing the sensory system to send a constant stream of information to the position encoding network. For the time being, we also ignore the impact of noise, exploring its effect in subsection 4.2. Under these assumption, the low-dimensional equation for bump position iṡ (4.1) As a simple example of the impact of the control term in (4.1), we examine the case of no heterogeneity F (∆) ≡ 0 and non-zero asymmetry φ > 0. In this case, we can analytically calculate the long term trajectory of the error r(t) = ∆ T (t) − ∆(t). To do so, we can write down the first order differential equation for the error (Slotine and Li, 1991) It is straightforward to calculate the solution to the linear differential equation (4.2) in the case r(0) = 0, finding r(t) = −φ/λ. Thus, perfect convergence of the trajectory ∆(t) to ∆ T (t) can only be obtained in the limit of infinitely strong control λ → ∞. It is also important to note that as long as the control strength is positive λ > 0, the error r(t) will be bounded in the long time limit t → ∞. We can extend our analysis of the equation (4.1) to the case of arbitrary heterogeneities using regular perturbation theory. Writing the linear expansion of ∆(t) = ∆ 0 (t) + ∆ 1 (t)/λ under the assumption λ 1, we find that the zeroth order equation for ∆ 0 (t) is simply given by ∆ 0 (t) = ∆ T (t). Extending to the first order equation in 1/λ, we finḋ Applying the equation∆ T (t) = v(t), we thus find that ∆ 1 (t) = F (∆ T (t)) + φ, which means that the long term error can be approximated by to first order in 1/λ. Thus, as long as F (∆) is a bounded function, then the error will remain bounded, reaching a maximum amplitude of max x |F (x) + φ| (Slotine and Li, 1991).
Thus far, we have considered the case of a continuous flow of sensory information providing an accurate estimate of an animal's position in space. However, in more realistic scenarios, animals receive external sensory information discretely in time via local landmarks (Battaglia et al, 2004;Tsao et al, 2013) or echolocation (Ulanovsky and Moss, 2011). Sensory cues that provide a landmark for an animal's present position may be captured periodically in time or more randomly; we account for both forms of sensory cue acquisition. As discussed in our formulation of the model in section 2, we assume the influence of sensory cues weakens as time elapses from the time at which they were received. This is consistent with recent observations concerning the evolution of place fields in bats as a function of the time since the last echo signal (Ulanovsky and Moss, 2011). Thus we consider the following model combing path integration with sensory cues acquired at times t k : Analogous to the continuous control case, the error term r k computes the instantaneous difference between the true position ∆ T (t) and the encoded position ∆(t) at time t k . This is then incorporated into the discretely incremented control term v c (t) with strength λ, and the temporal decay of cue influence is determined by the timescale τ . We will demonstrate that for any given τ , there is an optimal strength of feedback that trades off the error reduction of recent cues (t k ) with the error increase potentially arising for older cues (t 1 , ..., t k−1 ). Assuming v c (0) = 0 and treating the pointwise values of r(t) as constant, we can integrate (4.4) to yield the piecewise smooth function as we did in section 2 for the full neural field model in (2.9). Thus, adjustments in velocity are discretely incremented and then decay over time. Also, note in the limit τ → 0 and t k+1 − t k → 0, we obtain the continuous control function v c (t) = λr(t). This can be seen by performing this limit on (4.4) and then integrating.
To demonstrate the impact of discrete control in more detail, we begin by studying the case of a network subject only to asymmetry (F (∆) ≡ 0 and φ > 0). Furthermore, we focus on the case of constant velocity input v(t) ≡ v 0 , so we can write the discretely controlled position equation (4.3) aṡ (4.5) We can solve the piecewise smooth differential equation (4.5) recursively, integrating with a new initial condition ∆(t k ) at each cue time t k . In the initial time domain [0, t 1 ), ∆(0) = 0 and∆(t) = v 0 + φ, so ∆(t) = (v 0 + φ)t and ∆(t 1 ) = (v 0 + φ)t 1 . On the subsequent time domain [t 1 , t 2 ), we havė In a similar way, we can solve for ∆(t) on [t 2 , t 3 ) to find and in general, we can express Thus, we can express the error as a function of time Expressing r k := r(t k ) and focusing on the error at the cue timepoints t k , we can write (4.6) as Furthermore, in the case of periodically spaced cues, we can write t k+1 − t k = (∆t), ∀k, so that Assuming that λ is not too large, the discrete equation (4.7) will have a fixed point in the long time limit r l → r * , which we can compute by taking the difference between r l+1 and r l and approximating r k ≈ r * : 1 − e −(l+1−k)∆t/τ , and we can make the approximation e −l∆t/τ → 0, so that r l − r l+1 yields 0 = φ · ∆t + λτ r * ⇒ r * = −φ · ∆t/(λτ ). (4.8) We demonstrate the accuracy of the formula in Fig. 6A,B, showing that the error remains bounded due to the periodic perturbations of the discrete control term. Of course, the fixed point value given by (4.8) is contingent on its existence and stability. In cases where either condition is violated, the error r l will diverge in the long time limit (Fig. 6C). Essentially, negative feedback overcorrects for the previously observed errors at each cue time, leading to unstable oscillations in the error. Analytically identifying the cases in which r l diverges would require a more thorough study of the discrete equation (4.7). Numerical simulations suggest there is a boundary value of λ above which these unstable oscillations occur. Thus, the maximal value λ for which the fixed point r * exists and is stable would correspond to the optimal control strength, all other parameters being fixed. We now study the case of heterogeneities and explore the impact of sensory cues on the long term error. Note, in the case of no asymmetry and constant velocity input v(t) = v 0 , the low dimensional equation for bump position takes the forṁ (4.9) While we cannot solve (4.9) explicitly for general heterogeneities F (∆), we can numerically analyze the impact of both the control strength λ and the control decay timescale τ on the long term error r(t) = ∆ T (t) − ∆(t). Specifically, we associate error with a scalar quantity by computing the log of the L 2 -norm where t f is time at which the path ends. We compare the effects of varying the spacings t k+1 −t k between subsequent cues, testing both time-periodic cues (t k+1 − t k = ∆t, ∀k) and exponentially distributed spacings (p(∆t) = µe −µ∆t ). Furthermore, we randomize the heterogeneity according to the formula (2.3) with variance σ 2 n = 1 with four total modes (N = 2). To average error across many realizations, we simulate the controlled version equation (4.9) for many different randomly generated heterogeneities, compute an L 2 -norm of error R j for the jth realization and average R = 1 Nr Nr j=1 R j for N r realizations. We are mainly interested in the (λ, τ ) values that minimize the average log error R . Our findings are summarized in Fig. 7. First, we note that there is always a curve through (λ, τ ) space determining the values of the control term that minimize the average error R . In all plots, the associated τ value decreases with λ and vice versa. In general, we find this relationship to be roughly inversely proportional λ ∝ 1/τ . This means that stronger control should decay more quickly, and equivalently weaker control can last longer. Furthermore, by comparing plots for periodic cues with ∆t = 4 (Fig. 7A) versus ∆t = 2 (Fig. 7B), we find longer decay timescales associated with each λ value in the case ∆t = 2. Such a trend may arise due to the fact that more frequent updates in sensory information via cues prevents overcorrection that could occur in the case of less frequent curves. A similar trend arises in the case of exponentially distributed time spacings between cues (µ = 0.5 in Fig. 7C versus µ = 1 in Fig. 7D). When cues are more frequent, the optimal timescale of decay τ is slightly larger for each value of λ.
In addition, we have studied the average error as a function of time for both continuously and discretely controlled networks with heterogeneities. Note that we randomize the heterogeneity w u (x) = α 1 cos(x) so that α 1 is normally distributed with variance unity. To compute the average error, we take the mean of the absolute value |r(t)| as shown in Fig. 8. In the case of strong continuous control, it is possible to substantially decrease the impact of heterogeneities as compared with the uncontrolled case (Fig. 8A). Discrete control maintains an intermediate level of error, since there is not a constant stream Fig. 7 Average log error R computed across realizations of (4.10) for the discretely controlled low-dimensional approximation (4.9) with spatial heterogeneity resulting from (2.3) with N = 2 and coefficient variance σ 2 n = 1. (A) For periodically appearing control cues with ∆t = 4, we find there is an intermediate curve (solid) of (λ, τ ) values that minimizes R . In particular, as the control decay timescale τ is increased, the optimal value of λ decreases. (B) The same trend is consistent for periodic cues with spacing ∆t = 2, but the curve of optimal (λ, τ ) values shifts so there are higher values of τ associated with each value of λ as compared with A. (C,D) When spacings between cue times are exponentially distributed p(∆t) = µe −µ∆t with µ = 0.5 in C and µ = 1 in D, we find the optimal curve shifts to shorter values of τ for more frequent cues. Other parameters v 0 = 0.15, θ = 0, σ = 0.1, and simulation time t f = 40. Numerical simulations are performed using Euler's method with a timestep of 0.05, and each grid point used 1000 realizations.
of information provided to reduce error. Varying the strength λ and timescale τ of control alters the long term variance in the error (Fig. 8B). As suggested by Fig. 7, strong and fast decaying control tends to lead to substantial reductions in error.

Reducing error due to dynamic fluctuations
We now examine the impact of sensory feedback on networks subject to temporal noise fluctuations. Dynamic variability in networks can arise from ion channel fluctuations (Chow and White, 1996), synaptic variability (Ribrault et al, 2011), or finite size effects (Bressloff, 2009). As demonstrated in our analysis in section 3, we can derive a reduced equation for the position of a velocity-driven bump subject to noise to a single stochastic differential equation (3.13). Focusing specifically on the impact of noise, taking constant speed v(t) ≡ v 0 , and ignoring heterogeneities, we find that the controlled equation for the bump position takes the form (4.11) We begin by examining the case of continuous sensory feedback, in which case (4.11) becomes (4.12) Note that (4.12) is a non-autonomous Ornstein-Uhlenbeck process, and we can use integrating factors to identify an explicit solution. Utilizing the change of variables h(∆, t) = ∆e λt and differentiating with respect to t, we find (4.13) Assuming ∆(0) = 0, we can integrate (4.13) and multiply through by e −λt to yield the solution t 0 e λs dW(s), whose mean is ∆(t) = v 0 t and variance is given where the diffusion coefficient D can be calculated from the neural field model parameters as in (3.15).
The long term variance is thus given by lim . Note that in the limit λ → ∞, the variance goes to zero ∆(t) 2 − ∆(t) 2 → 0, suggesting that strengthening continuous control will always reduce the average error further. Continuous control substantially reduces the long term variance in the bump position ∆(t) as well as the error Note that r(t) = 0 and r(t) 2 = √ D 2λ 1 − e −2λt . We compare the continuously controlled system to the control-free system in Fig. 9A, revealing the long term saturation in the position variance.
We also study the effect of discrete control on the variance in position, using the low-dimensional approximation of bump position (4.14) v Again, this is under the assumption that cues are spaced discretely in time or space, and they provide sensory input for a brief period of time. As in subsection 4.1, we can solve (4.14) iteratively. To begin, note that when t ∈ [0, t 1 ), ∆(t) has yet to be affected by the feedback control term in (4.14), so ∆(t) = v 0 t + W(t). Subsequently, we can integrate (4.14) to find the stochastic formula for ∆(t) after the first cue at t 1 : Each realization will typically produce a different value for ∆(t 1 ) = v 0 t 1 +W(t 1 ). Note that ∆(t) = v 0 t, so the impact of noise and control can be observed by calculating the variance (Gardiner, 2004) (4.15) One insight to be gained from the formula (4.15) is that infinitely strong and fast decaying control, even when it is discrete, will minimize the variance in the position. Specifically, if we take λ = λ 0 /τ , then we can write Taking the limit as λ → ∞, we find that which is minimized when the scaling term λ 0 = 1, yielding ∆(t) 2 − ∆(t) 2 = D(t − t 1 ). We can solve (4.14) explicitly for an arbitrary number of cue times, yielding (4.16) While it is clear that the mean ∆(t) = v 0 t, it is more complicated to compute the variance ∆(t) 2 − ∆(t) 2 in general. This is chiefly due to the fact that r(t k ) will depend on (r(t 1 ), ..., r(t k−1 )), and this Fig. 10 Average log error R computed across realizations of (4.10) for the discretely controlled low-dimensional approximation (4.16) driven by additive noise with amplitude = 0.1 as described in (2.1). (A) For periodic cues with spacing ∆t = 4, we find that the curve (solid line) of optimal (λ, τ ) values has τ decreasing with λ as in Fig. 7. (B) A similar tend is observed for exponentially distributed p(∆t) = µe −µ∆t spacings between cue times with µ = 0.5. Other parameters v 0 = 0.15, θ = 0, and simulation time t f = 40. Numerical simulations are performed using the same method as in Fig. 7.
long-lasting history-dependence will accumulate indefinitely. To gain some analytical understanding, we make the assumption of brief control impulses, so that τ 1 and e −(t k+1 −t k )/τ 1, ∀k. In this case, we can write the equation for the update of the error term r k := r(t k ) as where r 1 = W(t 1 ). Again, it should be clear there is an inverse relationship between the impact of λ and τ on the long term error in this limiting case. We compute the variance numerically from (4.16) for the case of discrete control in Fig. 9, demonstrating an excellent match with the neural field model (2.1).
We conclude by computing the average log error (4.10) across realizations of (4.14) in Fig. 10. Notice again that the optimal value of τ , which minimizes R is inversely related to the strength of control. Furthermore, this trend is preserved whether cues appear periodically in time (Fig. 10A) or at exponentially distributed intervals (Fig. 10B).

Discussion
We have introduced and studied a neural field model of path integration with sensory feedback. Velocityinput results in the propagation of a bump attractor whose position encodes an animal's estimate of its position. Sensory information is assumed to come in the form of cues that are either constantly present, in the case of continuous feedback, or present at discrete points in time, in the case of discrete feedback. The full neural field model (2.1) can be reduced to a single scalar equation (3.13) for the resulting position of the bump attractor. Analyzing this reduced equation, we have found that continuous control can be used to reduce the error to zero in a variety of cases. Incorporating the more realistic assumption of discrete sensory control, we find a tradeoff arises as the strength of control λ is tuned: error reduction when cues are recent, counteracted by error increases when cues are older and irrelevant. Thus, there is an optimal control strength λ that minimizes the long term error in the model's position estimate. This pattern holds when errors originate from spatial heterogeneities as well as dynamic fluctuations.
Our analysis has focused on one-dimensional periodic systems, wherein it is assumed the animal is navigating along a narrow annular track (Fig. 1B). This was based on the protocol used in the experiments of Battaglia et al (2004), which were used to study the effect of local cues on the sharpness of neuronal place fields. However, there are several studies of navigation in two-dimensional and even three-dimensional space that demonstrate mammals' ability to use sensory cues to perform error correction (Geva-Sagiv et al, 2015;Solstad et al, 2008). For instance, a recent study has demonstrated that encounters with the boundaries of rectangular environments correct for the systematic drift in position representation (Hardcastle et al, 2015). In particular, border cells in medial entorhinal cortex (MEC) are thought to provide inputs to position-encoding grid cells when an animal senses an environmental boundary. Such recent studies are consistent with the predictions of planar models of spatial navigation based on the dynamics of velocity-driven bump attractors (Burak and Fiete, 2009;Samsonovich and McNaughton, 1997). The model we have presented here could be extended to incorporate the effects of position-dependent cues, like boundaries, in two-dimensional domains. We expect the extension to two-dimensional neural field models should be possible through a similar negative feedback control mechanism to those presented in section 2. Our derivation of the reduced equation would then simply yield a position variable that is two-dimensional, with a correction term along each coordinate.
We also note that there is recent evidence that the position of discrete objects in the environment may be encoded by cells in the lateral entorhinal cortex (LEC) (Tsao et al, 2013). In particular, these cells tend to be inactive in open environments with no spatial landmarks, but they become active in the presence of objects that can help animals to orient themselves (Deshmukh and Knierim, 2011). Some cells in LEC, object-trace cells, have been shown to fire when an animal encounters a location where an object previous was located, demonstrating a persistent memory of location (Tsao et al, 2013). If in fact such cells provide inputs to the position-encoding networks in MEC or hippocampus, LEC object cells could provide a candidate mechanism for the sensory feedback control which we have modeled here.