Fig 1.
Computation of normalized bottleneck distance .
Procedure for the computation of the normalized bottleneck distance between two barcodes and
in H1, for (A) a barcode consistent with toroidal topology and (B) a barcode very different from one expressing toroidal topology. The inset in (A) is a zoomed version showing small and otherwise invisible bars. The value of bottleneck distance is similar in the cases (A) and (B) even though one is much closer to a toroidal barcode than the other. The normalized bottleneck distance, dividing the barcodes by
and
, takes into account the absolute and relative length of bars, solving this problem.
Fig 2.
Sigmoidal relationship between and noise added to simulated tori.
(A) Zero mean Gaussian noise with standard deviation was added to 1200 points on a 3-dimensional torus defined by Eq. (2) with a = 5 and c = 10, shown on the top row for three increasing values of
. Persistent homology is performed on this dataset. Barcodes for low (left) and high (right) noise levels are shown in the middle row. The two plots on the bottom show the components of the degree of toroidality,
versus the size of the noise,
. The solid line shows the average over 20 realizations of the noise, and the shaded region is the standard deviation. The vertical arrows connects the torus, barcodes and toroidality for two values of
. (B) Same as (A) with a = 50 and c = 100. (C) Same as (A, B) for 20 realizations of data generated on a 6-dimensional torus from Eq (9), in Methods.
Table 1.
Grid cell modules quantification.
Fig 3.
Degree of toroidality in the experimental data.
(A) vs
computed using the subset of pure grid cells in each module. Modules S59 (purple) and
(black) have a low degree of toroidality. (B) When all neurons are taken into account, module
(pink) exhibits a smaller degree of toroidality, while the toroidality of
substantially increases. (C) Barcode for
with pure cells only, showing a third long bar in H1 and one relatively short bar in H2. (D) Barcode for S59 with pure cells only, showing multiple bars of comparable length in both H1 and H2. (E) The relative difference
between
computed on all grid cells and
computed only on pure cells shows the relative change in the degree of toroidality.
Fig 4.
Degree of toroidality smoothly increases as a function of the number of recorded cells.
(A) (black) and
(magenta) computed over a subset of Ns (out of 149) grid cells from module
. (B) Barcode from module
with Ns = 29 has low toroidality. (C) Barcode from module
with Ns = 149 has high toroidality. (D)
and
computed over a subset of Ns (out of 168) grid cells from module
. (E) Barcode from module
with Ns = 33 has low toroidality. (F) Barcode from module
with Ns = 168 has high toroidality. (G)
and
computed over a subset of Ns (out of 189) grid cells from module
. (H) Barcode from module
with Ns = 30 has low toroidality. (I) Barcode from module
with Ns = 189 has high toroidality. Each point is averaged over 30 different subsets of Ns cells. The last points in each plot are computed on the entire dataset, thus they are single realizations.
Fig 5.
Jittering the spikes by 125 ms does not destroy the toroidal topology and leaves the grid scores practically unchanged.
(A) Left. Rate maps of 5 representative grid cells from a population of 149 from module Middle. Barcodes in dimension one (H1) and two (H2) with toroidality
. Long, significant bars are indicated by blue arrows. The ordering of the bars along the y-axis is not meaningful. Right. 3-dimensional UMAP embedding of population activity. The color of each point represents the angle along a chosen axis and it is shown only for visualization. (B) Spike times from three simultaneously recorded grid cells showing synchronous theta modulation on the top. Spike times were jittered by zero-mean Gaussian numbers with standard deviation
ms which removed theta correlation, on the bottom. Note that, as a result of jittering, some spikes went out of the depicted range. (C) Same as (A) but for jittered spike trains, which yield toroidality
, similar to unjittered toroidality. (D) The grid score of each cell in module
for the non-jittered and jittered spike trains was similar;
before jittering and
after jittering.
Fig 6.
Toroidality has a sigmoidal dependence on temporal jitter magnitude over a range in which hexagonality is maintained.
(A) Effect of jittering spike times on the degree of toroidal topology of module (
on the left and
on the right) is sigmoidal. The star shows the value of
(see Methods Estimating time scales for details) and the inset shows the slope at the inflection point. (B) Subset of 5 (out of 149) rate maps (left) and the barcode (right) relative to the entire population for a value of jitter smaller than
(
ms) showing toroidal topology. (C) Subset of 5 (out of 149) rate maps (left) and the barcode (right) relative to the entire population for a value of jitter larger than
(
ms) which is inconsistent with toroidal topology. (D) Grid scores of the jittered spike trains show little change compared to the unperturbed ones. (E) Same as (A)-(D) for module
. (F) Same as (A)-(D) and (E) for module
.
Table 2.
Critical timescale values.
Fig 7.
Simulation of a grid cell module from Eq. (3).
(A) Subset of 5 (out of 75) rate maps with spacing similar to . (B) Power spectral density of a single cell simulated spike train showing peaks in the eta (4 Hz) and theta (8 Hz) frequency bands, as constructed in Eq. (3). (C) Barcode from the persistent homology of a population of 75 simulated grid cells show clear toroidal topology. (D) The 3D UMAP embedding of the population activity shows a 3-dimensional torus. The color of each point represents the angle along a chosen axis and it is shown only for visualization.
Fig 8.
The dependence of the degree of toroidality on the field size with and without oscillations.
(A, B) The barcodes of the simulated populations modulated by oscillations are similar to the associated experimental module for large enough values of , averaged over 20 realizations (shaded area indicates standard deviation). The parameters for the oscillations are as described in Methods. Removing the oscillations dramatically reduces this similarity and increases the variability both in
(A) and
(B). (C, D) Similarity measures
and
between the barcodes from the simulations and a reference barcode produced from the simulated population with two long bars in H1 and one long bar in H2, as descried in text.
Fig 9.
Barcodes for the simulated population with oscillations are similar to data.
Barcodes from experimental data (A), simulation with oscillatory modulation (B) and simulation without (C). The barcodes from simulations with oscillations (B) look very similar to the data barcode (A), as quantified by . The parameters of the oscillations are as described in Methods. When oscillations are removed (C), toroidal topology can still be present, but the barcodes are far from the data. (D) The histogram shows that the difference between the death radius of the longest bar in H1 and the birth radius of the longest bar in H2 takes a large positive value in the data and in the simulation with oscillations, while it is much closer to zero in the simulation without oscillations. The long bar in H2 is consistently born at the same time as the longest bars in H1 die. The histogram is from 20 realizations in each case.
Fig 10.
Dependence of on firing rate and oscillation frequency.
(A) The simulation with one single oscillator shows that is not dependent on the oscillator frequency in a module with spacing similar to
. Except for the choice of the dominant frequency described in the text, the parameters for the oscillations are as described in Methods. (B) The variance of
shows a minimum at the eta and theta time scales. Simulation parameters are the same as Fig 7, removing the oscillation at eta, and varying the frequency of the remaining one. The errors bars are over 30 realizations. (C, D) Toroidality increases when cells are modulated by oscillations for a large span of G0 values both in
and
. The averages and errorbars for each value of G0 are over 20 realization of the simulations.
Fig 11.
The dependence of on grid field displacement.
The degree of toroidal topology of the simulated populations modulated by oscillations is refractory to grid field center displacement up to around 10-15% of the grid spacing, where it drops suddenly. The arrows show a rate map example for the following levels of relative displacement: 0%, 12% and 24%. The mean and error bars are from 20 realizations of the simulations with the parameters for the oscillations described in Methods.
Fig 12.
Firing of grid cells are modulated at eta and theta bands.
The power spectra of the neurons’ spike counts from different modules averaged over all neurons (full curves) and corresponding s.e.m. (shaded area) for (A)-(C) groups of cells recorded from the same animal on the same day that did exhibit high toroidality. (D)-(F) the three modules that did not show high toroidality when all cells were considered. Modules in panels (A) and (D) and in panels (B) and (E) were simultaneously recorded.
Fig 13.
Dependence of and spacing to eta-to-theta power.
(A) While for small some modules show high toroidality, while others do not, for all modules that do show large toroidality, there is little dependence of
(hexagon) and
(cross) on eta-to-theta power ratio. (B) Grid spacing correlated with eta-to-theta (correlation 0.62, p-value <0.05). The one outlier
and the samples represented by the cross do not exhibit large toroidality.
Fig 14.
Eta-to-theta power ratio shows a positive correlation trend with the critical jitter size.
The relationship of (A) , (B)
and (C)
with
. Populations recorded simultaneously are shown with the same color shade, one with full lines, the other with dashed lines. The mean and errorbars are calculated over the neurons from each module. The lines are linear regressions between these means and the corresponding x-axes in each panel ((A) slope = 3.7
, r2 = 0.27, (B) slope = 4.1
, r2 = 0.55, (C) slope = 4.3
, r2 = 0.38). For each pair of simultaneously recoded modules the mean
was larger in the module with larger
compared to the one with smaller
(p-value<0.001); the same holds for
and
.
Fig 15.
Toroidal topology is more robust for small spacing when large eta-to-theta oscillations are included.
(A) The variability of is reduced when eta and theta oscillations are included (
) in the simulation with the experimental trajectory of the rat from day 2, and the simulated population shows toroidal topology more consistently over 20 different realizations. (B) The difference between the death radius of the longest bar in H1 and the birth radius of the longest bar in H2 takes a large positive value in the data and in the simulation with oscillations, while it is much closer to zero in the simulation without oscillations. (C) Example barcodes with oscillations and without them (D), corresponding to the simulations indicated by orange and blue stars in (A), respectively.