The nature of mean-field generation in three classes of optimal dynamos

In recent years, several optimal dynamos have been discovered. They minimize the magnetic energy dissipation or, equivalently, maximize the growth rate at a fixed magnetic Reynolds number. In the optimal dynamo of Willis (Phys. Rev. Lett., vol. 109, 2012, 251101), we find mean-field dynamo action for planar averages. One component of the magnetic field grows exponentially while the other decays in an oscillatory fashion near onset. This behaviour is different from that of an $\unicode[STIX]{x1D6FC}^{2}$ dynamo, where the two non-vanishing components of the planar averages are coupled and have the same growth rate. For the Willis dynamo, we find that the mean field is excited by a negative turbulent magnetic diffusivity, which has a non-uniform spatial profile near onset. The temporal oscillations in the decaying component are caused by the corresponding component of the diffusivity tensor being complex when the mean field is decaying and, in this way, time dependent. The growing mean field can be modelled by a negative magnetic diffusivity combined with a positive magnetic hyperdiffusivity. In two other classes of optimal dynamos of Chen et al. (J. Fluid Mech., vol. 783, 2015, pp. 23–45), we find, to some extent, similar mean-field dynamo actions. When the magnetic boundary conditions are mixed, the two components of the planar averaged field grow at different rates when the dynamo is 15 % supercritical. When the mean magnetic field satisfies homogeneous boundary conditions (where the magnetic field is tangential to the boundary), mean-field dynamo action is found for one-dimensional averages, but not for planar averages. Despite having different spatial profiles, both dynamos show negative turbulent magnetic diffusivities. Our finding suggests that negative turbulent magnetic diffusivities may support a broader class of dynamos than previously thought, including these three optimal dynamos.


Introduction
Since the works of Varley, Wheatstone and Siemens of around 1867, we know that electromagnetic dynamos can be self-excited, i.e. they work without permanent magnets to turn kinetic energy into electromagnetic energy. Unlike those technical dynamos with wires, homogeneous dynamos work in uniformly conducting media (Larmor 1919). They are prone to short-circuiting themselves, so for a long time it was unclear whether they could work at all. Indeed, it became clear that axisymmetric magnetic fields cannot be sustained by a dynamo (Cowling 1933). Axisymmetric flows, on the other hand, are capable of producing dynamos, but the resulting magnetic field is necessarily non-axisymmetric (Gailitis 1970;Ponomarenko 1973;Dudley & James 1989). Moss (1990) found that the critical magnetic Reynolds number, i.e. the ratio of inertial to resistive electromagnetic forces, is rather large for the dynamo of Gailitis (1970) to be excited. This means that the typical scale and velocity can be very large, so an experimental verification is difficult for that flow. For the Ponomarenko dynamo, by contrast, the critical magnetic Reynolds number is sufficiently low so that an experimental verification was successful (Gailitis et al. 2000).
Another self-excited dynamo arrangement that has been subjected to experimental verification is that of Herzenberg (1958). The critical magnetic Reynolds number is again very large, but by using solid copper rotors that are in electric contact within a large copper block, it was possible to reach supercritical conditions (Lowes & Wilkinson 1963, 1968. Modelling the Herzenberg dynamo numerically has been possible by using relatively large rotors that are close together (Brandenburg, Moss & Soward 1998). From a numerical point of view, however, it is more advantageous to use periodic flow patterns. For example the Roberts flow I in a cubic domain has a critical magnetic Reynolds number of approximately 5 based on the root mean square (r.m.s.) velocity and the wavenumber of the flow. By comparison, the critical magnetic Reynolds number for the Arnold-Beltrami-Childress (ABC) flow (Galloway & Frisch 1986) is approximately 15.
Indeed, certain periodic flows are better than others at producing dynamos. The optimal flow of ABC type, for example, was identified by Alexakis (2011). Other studies (Pringle & Kerswell 2010;Pringle, Willis & Kerswell 2012) on pipe flows led  to consider this as a variational problem. The optimal steady flow to excite a kinematic dynamo is found iteratively. Due to the arbitrarily low kinetic energy required to excite a dynamo (Proctor 2015), the magnetic Reynolds number should be based on the r.m.s. vorticity rather than the r.m.s. speed, which we refer to as R ω in this paper. A series of optimization studies followed. Chen, Herreman & Jackson (2015) considered physical boundary conditions, and Chen et al. (2018) applied the same method to a sphere. The optimal axisymmetric flow in a sphere has also been identified in the thesis of Chen (2018). All optimal flows have lowered the critical R ω significantly.
It is often thought that some kind of swirl or helicity in the flow is important, but this is not generally true (Gilbert, Frisch & Pouquet 1988). Three of the four flows studied by Roberts (1972) have no helicity and yet they can produce mean magnetic fields, as defined by planar averaging. In fact, different types of flow geometries can produce very different types of dynamos: small-scale dynamos, large-scale dynamos, those with an α effect and those without, etc. Non-helical isotropic turbulence only leads to small-scale dynamo action when the magnetic Reynolds number based on the r.m.s. speed exceeds a critical value that is between 40 and 200, depending on the magnetic Prandtl number -the ratio of kinematic viscosity to magnetic diffusivity (Iskakov et al. 2007;Brandenburg 2011). Those dynamos produce magnetic fields at scales as small as the resistive scale -the smallest scale where turbulent magnetic fields exist.
Some flows also act as large-scale dynamos, which produce magnetic fields that can be detected even after spatial averaging over certain directions. Such dynamos are also referred to as mean-field dynamos. Here we show that some of the optimal dynamos do indeed produce mean fields. We also examine the nature of such meanfield dynamo action.

Instructive examples of mean-field dynamos
A particularly famous example of a large-scale dynamo is the Roberts flow I, a flow with maximum kinetic helicity. The flow is of the form U = k f ψẑ + ∇ × (ψẑ), where ψ = cos kx cos ky is the stream function in Cartesian (x, y, z) coordinates, k is the wavenumber, and k f = √ 2k is the effective wavenumber (Roberts 1972). The critical magnetic Reynolds number, based on the r.m.s. velocity and the effective wavenumber √ 2k, is 3.9 for a domain of length L = 2π/k in the z direction (Brandenburg & Subramanian 2005). Interestingly, a flow of the form U = k f ψẑ + ∇ × (φẑ), where φ = sin kx sin ky is phase shifted in the x and y directions by π/2 relative to ψ (Roberts flow II), has zero pointwise kinetic helicity. So, there is no swirl whatsoever, and yet, it produces not only a magnetic field, but one with non-vanishing xy averages, although it requires L 2π/(0.64k) ≈ 9.8/k (Rheinhardt et al. 2014).
In the following examples, we focus on dynamos that produce a non-vanishing mean field obtained by averaging over the xy plane of size L 2 . This mean field is therefore defined as B = B dx dy/L 2 . In the case of Roberts flow I, the resulting mean field is of the form B = B 0 (t)(sin(kz + ϕ), cos(kz + ϕ), 0), where ϕ is an arbitrary phase, k is the wavenumber and B 0 (t) is a time-dependent amplitude. In the case of Roberts flow IV, the velocity has no net but still pointwise helicity. The mean magnetic field is time dependent and its x and y components evolve independently of each other, i.e.
where B 0x (t) and B 0y (t) are time-dependent amplitudes, ϕ x and ϕ y are phases and k (x) and k (y) are wavenumbers for the x and y components, respectively. In principle, the values of B x and B y for a mean-field dynamo can be different from each other. For example, if B 0y = 0, the magnetic field can just be B = (B 0x cos kz, 0, 0), i.e. with only one component. In fact, the Robert flows II-IV all produce dynamos where B x and B y evolve independently of each other, albeit at the same rate, i.e. d ln B 0x /dt = d ln B 0y /dt; see Devlen, Brandenburg & Mitra (2013), Rheinhardt et al. (2014). We are not aware of any earlier demonstration of a case where the growth rates of different components are not the same. Solutions to large-scale or mean-field dynamos can be obtained if the mean electromotive force can be expressed in terms of the mean field. Here, the mean electromotive force is defined as E = u × b, where overbars denote xy averaging and lowercase symbols denote fluctuations around the mean field, i.e. u = U − U and b = B − B are the fluctuating velocity and magnetic fields. The general relationship between B and E is in terms of a convolution of the form where K is an integral kernel. In the case of Roberts flow I, when the mean magnetic field is marginally excited, the kernel is approximately of the form where α = (η + η t )k in the marginally excited case. In the case of Roberts flow II, the components of K ij cannot be described by an instantaneous relationship, but there is a turbulent pumping effect with a certain time delay (Rheinhardt et al. 2014). In this case, the x and y components evolve independently of each other. The dynamo for Roberts flow III is similar to that for Roberts flow II, except that the x and y components of the mean magnetic field experience pumping velocities that point in opposite directions. Finally, Roberts flow IV is again given by an equation similar to (2.3), but with α = 0 and η t being negative on the length scales of interest. At smaller scales, however, η t is always positive, which is necessary so as to ensure stability at small length scales. This can be accounted for by adding a magnetic hyperdiffusivity, corresponding to an additional third-order spatial derivative term in (2.3). We return to this at the end of the paper. With these preparations in place, we are now in a position to characterize the dynamos driven by the aforementioned optimized flows.
In this study, we encounter examples of dynamos that share similarities with some of the cases discussed above. In particular, we find cases that do exhibit this type of unusual behaviour with two components evolving independently of each other. For example, the Willis dynamo is even more bizarre than that of Roberts flow IV, because the two horizontal components of B evolve differently, with growth rates that have even different signs. Robert flow I, by contrast, is maximally helical and leads to an α effect that couples the two horizontal components of B. Those dynamos are called α 2 dynamos, because the α effect is responsible for producing B x from B y and for producing B y from B x . We talk about αΩ dynamos when shear in (say) the y direction (Ω effect) is responsible for producing B y from B x . The flows of  and Chen et al. (2015) turn out not to be of that type. Below, we present a more detailed analysis of these optimal dynamos.

Essentials of dynamos driven by optimized flow
The goal of this study is to determine the nature of dynamo action driven by the flows of  and Chen et al. (2015). We discuss three types of optimal flows with distinct boundary conditions for their excited magnetic eigenmodes, referred to as Willis, NNT and TTT cases. In Chen et al. (2015), the magnetic boundary conditions can be either superconducting or pseudo-vacuum in each direction. In terms of spectral representations, this means either using sine functions (T for tangential) or cosine functions (N for normal) in the direction perpendicular to the boundary. The corresponding magnetic eigenmodes then have four possible combinations: NNT, NTT, NNN, and TTT in x, y, z respectively. The NNT/NTT and NNN/TTT pairs give the same dynamo up to a symmetry transformation (Favier & Proctor 2013). Thus, only one solution from each pair is chosen for this study. We begin by briefly explaining the essential technique to obtaining these optimal flows, and then describe the dominant Fourier modes of the dynamo solution, if there is any.
Basically, the optimization method belongs to the family of constrained optimizations. Given a Lagrangian as follows, where ω = ∇ × U(x), B T = B(x, T), · · · = V −1 · · · dV denotes the volume average and T is a fixed time that is long enough to filter out a transient growth. The first term Mean-field generation in optimal dynamos 5 in (3.1) is a proxy of the growth rate that we want to maximize, whilst the other terms are constraints from a kinematic dynamo model (the backreaction from the magnetic field on the flow is not considered). We search for the optimal flow U and the initial field B 0 such that all variations vanish (3.2) Setting δL/δB † = 0 gives the induction equation and setting δL/δB = 0 gives the adjoint induction equation, The optimization procedure is based on the two equations above. Starting from some fields U and B 0 , we first evolve the system forward in time using (3.3) until time T, then backward in time using (3.4) and finally we use δL/δU and δL/δB 0 as gradients to update U and B 0 . A detailed optimization algorithm is described in Chen et al. (2015). The resulting optimal flow U and the corresponding least decaying magnetic eigenmode show drastically different features for the three cases we are interested in. The Willis case represents the most efficient solution (has lowest critical R ω ) with periodic boundary conditions for the flow and the magnetic eigenmode. Since the optimization algorithm does not fix the orientation of fields, any transformation such as shift (T δ ), rotation, or reflection (R) gives the same equivalent optimal flows, For the flow we use, the actual form in the transformed coordinate is (sin(z + π/2) cos(y − π/4), sin x cos(z + π/2), sin(y − π/4) cos x). (3.7) The two sets of coordinates are related by (x,ỹ,z) = (x, z + π/2, y − π/4). The magnetic eigenmode of this dynamo can also be approximated by a simple field (up to 2 % difference in energy) as in the transformed coordinate. The x, y, z components of (3.8) each vary only in one direction. If small fluctuations are added to this eigenmode, we would expect to find a non-zero mean field when taking any of the planar averages.

6
A. Brandenburg and L. Chen In Chen et al. (2015), a combination of sine and cosine functions is used to mimic physical boundary conditions in a domain of size 1. The flow satisfies non-penetrating boundary conditions and therefore only sine functions are allowed in the direction perpendicular to the boundary. In this study, we rescale the flows of Chen et al. (2015) such that they become periodic in a (2π) 3 domain while retaining the boundary conditions in a π 3 domain. In the extended (2π) 3 domain, the general form is given by and a i (m x , m y , m z ) with i = x, y, z being the spectral coefficients. This is similar to the Taylor-Green flow but with the sine and cosine functions swapped. The NNT magnetic field has the general form which corresponds to normal field boundary conditions in the x and y directions, and perfectly conducting boundaries in the z direction; B TTT has the same general representation as (3.9). This is because the boundary conditions for both fields forbid normal components across the boundary, but allow tangential components.
To distinguish the two cases, the optimal flows are named after the boundary conditions of their corresponding magnetic eigenmodes. For up to 83 % of the total enstrophy, ω 2 , the optimal NNT flow can be approximated by the velocity .16 sin 2y sin 2z 0.77 sin x sin z −0.18 sin 2x sin 2y   . (3.11) The leading components of the magnetic eigenmode are given in Chen et al. (2015). In particular, the most energetic Fourier mode takes 39 % of the total energy, and varies only in one direction where (0, 1, 0) are the wavenumbers in x, y, z respectively. We expect to see some contribution from B x for the xz averages taken in the (2π) 3 domain. The other dominant Fourier components depend on at least two directions, hence have zero planar averages. The TTT case has neither a dominant flow nor a dominant magnetic field that varies only in one direction. The optimal TTT flow is highly localized, but has approximately equal enstrophy per direction ( ω 2 i , i = x, y, z); see also Chen et al. (2015) for the streamline plot. We do not expect to find a planar mean field near onset for this type of dynamo.
With three types of boundary conditions, we get three optimal solutions: the Willis and NNT dynamos both have simple large-scale flows, except the NNT dynamo breaks the symmetry in one direction, and the TTT dynamo has a complex localized flow. These three dynamo solutions were computed without imposing specific physical properties of the flow a priori. While this approach allows us to remove bias and explore the full parameter space of solutions, it leaves the question of how to interpret the dynamo action. In the next section, we discuss how to extend the analysis of dynamos using mean-field theories.

Mean-field approaches to analysing the dynamos
To characterize the nature of dynamo action for the three optimized flow problems, we use both direct numerical simulations (DNS) and the test-field method (TFM). The DNS refer to the numerical solution of (3.3), whereas the TFM refers to solutions of the evolution equations for the fluctuations around a given planar averaged mean field, which is one of four test fields, B T . The TFM allows us to extract turbulent transport coefficients from the underlying flow fields (Schrinner et al. 2005(Schrinner et al. , 2007; see also Brandenburg et al. (2010) for a review. We use numerical representations of the flows of Chen et al. (2015) for NNT and TTT dynamos in their original form, i.e. the r.m.s. of velocity is unnormalized, but we extend the domain to (2π) 2 to match the periodic boundaries and also to reproduce Willis dynamo using a similar algorithm. The corresponding data files for these three flow fields can be found in the online material (Brandenburg & Chen 2019) for the published data sets used to compute each of the figures of the present paper. For comparison, we also use the original formulation of Willis (2012), denoted by Willis* (with an asterisk), which is written as U = (2/ √ 3)(sin y cos z, sin z cos x, sin x cos y) in the same coordinate as other flows, as opposed to the transformed form in (3.7). All these flows and the resulting magnetic fields are periodic in the (2π) 3 volume, but for the NNT and TTT cases, we also select a π 3 subvolume with the appropriate boundary conditions. The flows are represented on a 32 3 mesh, except for the TTT case, which is represented on a 48 3 mesh. For the NNT and TTT cases in π 3 subvolumes, we select the first 17 3 and 25 3 mesh points, respectively, which include the points on the boundaries.

Characterizing the growth of the mean field
The growth of the mean field can be characterized through averaging. From the kinematic model, we know the spatial distribution of the magnetic eigenmode. The choice of averaging is then determined by the dominant magnetic field components. We take xy averages for the Willis and TTT cases, and xz averages for the NNT case, and denote those by an overbar. To compute r.m.s. values, we employ volume averages, denoted by angle brackets. The r.m.s. values of the velocity, U rms ≡ U 2 1/2 , are listed in table 1. The kinetic helicity integrated over the full domain is zero, but its local value at arbitrary points in the domain is finite. For the NNT flow, the kinetic helicity integrated over the π 3 domain is also zero. By contrast, the TTT flow lacks the symmetry to have a net zero helicity in the π 3 domain.
To obtain B = ∇ × A, we solve for the magnetic vector potential A. Its evolution is governed by the uncurled induction equation, We solve this equation using the PENCIL CODE 1 , which is a high-order public domain code for solving partial differential equations, including the induction equation that is of interest here, as well as the test-field equations that are discussed in the next section. The code uses sixth order finite differences in space and the third-order low storage Runge-Kutta time stepping scheme of Williamson (1980). When η is below a certain critical value, η crit , the value of the r.m.s. magnetic field, B rms , grows exponentially proportional to e λt where λ is a constant. For oscillatory fields, λ can be complex such that 2π/Im λ is the period of the oscillation, and Re λ 8 A. Brandenburg and L. Chen  ), the growth rate λ of the r.m.s. magnetic field and those of the mean-field components B x and B y (or B z for the xz averaged NNT flow), denoted by λ (x) mean and λ (y,z) mean , respectively. Their imaginary parts give the frequency of oscillatory field components. The asterisk on the value 0.45 for q denotes that a columnar z average has been used in this case (see text).
is the growth rate, which can be estimated from the logarithmic derivative of B rms or its envelope for oscillatory fields. By experimenting with different values of η, and by interpolation, we find the critical value η crit below which the dynamo is excited.

Quantitative analysis using the TFM
The averaged evolution or mean-field equation reads where E = u × b is the electromotive force from the fluctuating velocity and magnetic fields, b = ∇ × a is the small-scale magnetic field and a is a solution to the equation that results by subtracting (4.2) from (4.1), which yields where E = E − E is the fluctuation of the electromotive force. This equation contains B, but it can also be formulated for arbitrary mean fields, which we then call test fields, B T . The goal is to determine solutions to this equation for sufficiently many independent test fields so that we can assemble all eight unknowns,α ij andη ij , for i, j = 1, 2 to the equationẼ In general, the actual mean fields are neither constant in space nor in time, so we need to sample all Fourier modes in z and t to capture the full dependence. (Here, and in the following, we mean y instead of z when dealing with the NNT flow.) Fourier-transformed variables are denoted by tildes. The electromotive force is then written in the form (Brandenburg, Rädler & Schrinner 2008) Mean-field generation in optimal dynamos 9 The z profiles of all components ofα ij (z, t, k, ω) andη ij (z, t, k, ω) are obtained by solving the test-field equations for different values of k and ω, where k is the wavenumber and ω is the frequency in Fourier space.
Here,B = e −i(kz−ωt) B dz dt is the Fourier-transformed mean field, and likewise for J. For determiningα ij andη ij , we solve four copies of (4.3), each with one of four different test fields; B T = (sin kz, 0, 0), (cos kz, 0, 0), (0, sin kz, 0) and (0, cos kz, 0). We then solve the test-field equation forward in time. Given that U is constant in time, we can use a relaxation method (see Rheinhardt et al. 2014, for details) and rewrite the test field as B T → e −iωtB T (z; ω). This notation is not to be confused with the solutions to the adjoint problem, B † , discussed in § 3.
We solve the Fourier-transformed complex equations for the response to each of the test fields. Those equations are given by (Rheinhardt et al. 2014) iωã whereb T = ∇ ×ã T are the solutions, tildes denote Fourier transform in time, a T (x, ω) = a T (x, t)e −iωt dt and lowercase letters and primes denote fluctuations about the planar average. We then compute the desired transport coefficients in Fourier space,α ij andη ij by measuringẼ T = u ×b T and then solving (4.4). The diagonal components of the sum η +η ij act as an effective magnetic diffusivity, which has to be overcome by the other inductive effects in order for mean-field dynamo action to occur. We apply the complex TFM to the three optimal flows discussed earlier.

DNS results and spatial averages for the different dynamos
The critical magnetic diffusivity, η crit , along with the r.m.s. velocities and other relevant parameters such as the critical magnetic Reynolds numbers, R crit m = u rms /η crit k 1 , (5.1) are listed in table 1. Here k 1 is an estimate of the relevant wavenumber of the magnetic field -usually the lowest in the domain. We use k 1 = 1 in all cases, and fluctuations are periodic. We also list the ratio q ≡ B rms /B rms of the r.m.s. values of the mean field, B rms , to that of the full field, B rms , for cases that are approximately 15 % supercritical. The Karlsruhe and Riga dynamo experiments were only approximately 10 % supercritical, as measured by the magnetic Reynolds number based on the characteristic flow speed (Gailitis et al. 2003;Dormy & Soward 2007). Testing the near-critical response of the mean field is, therefore, a useful way of characterizing a weakly supercritical dynamo. In table 1, we also list the growth rates λ of the actual field |B| and λ (i) mean of the ith component of the mean field B i . Negative values indicate decay and an imaginary part denotes the frequency for oscillatory behaviour.
For comparison, we have included in table 1 the results for the more familiar ABC and Roberts flows. The ABC flow (Childress 1970) is given by U = (sin z + cos y, sin x + cos z, sin y + cos x). The equation for the ABC flow is similar to that for the Willis flow, except that the multiplications in the latter are replaced by plus signs in the ABC flow.

Dynamo action in the Willis dynamo
For the analytically given flow Willis*, which has a r.m.s. velocity of unity, we find mean-field dynamo action for η < η crit = 0.568. This corresponds to R crit m = 1.76. For the FIGURE 1. The three components of the magnetic field, B x (red), B y (blue) and B z (green), at an arbitrarily selected point x * within the domain for the Willis flow with η = 0.35, which is supercritical. All three components begin to grow exponentially at the same rate. Solid (dashed) lines denote positive (negative) values.
numerically optimized flow 'Willis' (without asterisk), which we focus on in the rest of this paper, the r.m.s. velocity is smaller and η crit = 0.403. This corresponds to R crit m = 1.75, so it is only slightly easier to excite than Willis*. The following considerations apply all to the latter, numerically optimized flow. In the supercritical case, here using η = 0.35, all three components of B are seen to grow exponentially in time at the rate λ ≈ 0.052; see figure 1.
For the Willis flow, as we will see below, equation (4.1) possesses solutions with non-vanishing planar or xy averages. It turns out that there is a finite mean field, B(z * , t), where z * is a fixed position. In figure 2, we show its x and y components. Note that B z = 0 at all times owing to the fact that ∇ · B = ∂B z /∂z = 0 and that the mean field was vanishing initially. We see that B x (z * , t) grows with the same growth rate as the actual magnetic field at any arbitrarily selected point (see figure 1), but B y (z * , t) is seen to decay in an oscillatory fashion with frequency Im λ ≈ 0.58 at a rate Re λ (y) mean ≈ −0.26. The occurrence of different growth rates for different components is unusual and very different from the more familiar α 2 and αΩ dynamos (Krause & Rädler 1980), where two components (poloidal and toroidal fields) always evolve in tandem. For example, the previously mentioned Roberts flow I is of α 2 type, but the dynamos from flows II and III work with time delay, and flow IV generates a negative diffusivity dynamo. The different behaviours between standard α 2 and αΩ dynamos on the one hand and negative turbulent diffusivity and time delay dynamos on the other hand is illustrated in figure 3.
To understand the negative turbulent diffusivity dynamos, we emphasize that, in view of (4.2) and (4.5),η xx affects the evolution of A x and thus B y = ∂A x /∂z. Therefore, if η +η xx < 0, B y grows at the rate −(η +η xx )k 2 . On the other hand,η yy affects the evolution of A y and thus B x = −∂A y /∂z. Therefore, if η +η yy < 0, B x grows at the rate −(η +η yy )k 2 . For the Willis flow, as we shall see below, the latter can indeed be negative if R m is large enough, leading to a growth of B x , as is seen in figure 2. By contrast, η +η xx turns out to be always positive, so B y can only decay.  FIGURE 3. Sketch illustrating the mutual feedbacks between B x and B y in α 2 or αΩ dynamos (a), and the independent evolution of the two components in negative turbulent diffusivity and time delay dynamos (b). For negative turbulent diffusivity dynamos, the growth rate of B x is −(η +η yy )k 2 and that of B y is −(η +η xx )k 2 , and they can be different from each other.
The magnetic field found in the present simulations can be represented as a superposition of different eigenfunctions -each with a different eigenvalue. The dominant eigenfunction corresponding to the aforementioned growth rate or eigenvalue λ (x) mean ≈ 0.052 of the horizontally averaged eigenfunction has a vanishing y component, while the eigenfunction corresponding to the eigenvalue λ (y) mean ≈ −0.26 ± 0.58i has a vanishing x component. This explains the behaviour seen in figure 2. Without xy-averaging, one would only see the fastest growing mode, as was demonstrated in figure 1, where all three components of the original (non-averaged) field grow at a rate equal to the eigenvalue λ (x) mean ≈ 0.052. Thus, it is only after xy-averaging that we are able to separate the two dominant eigenfunctions from the numerically determined magnetic field.
To investigate different planar averages in the same set-up, we have rotated the flow in both directions, u i (x, y, z) → u i+1 (z, x, y) and → u i−1 (y, z, x), and found the same behaviour in all three cases. Below, we apply this technique to the NNT flow to  study xz averages as a function of y. However, to avoid confusion, we always express the final result in the original, unrotated coordinate system.

Dynamos in the NNT and TTT flows and comparison with the Willis flow
The NNT flow varies very little in the y direction and is dominated by flow components in the xz plane. The TTT flow, on the other hand, varies more strongly in the xy plane, but its z average still has no significant component in the z direction. For the Willis flow, the flow patterns in the xy, xz and yz planes look the same. In figure 4 we visualize z averages of the Willis and TTT flows in the xy plane and y averages of the NNT flow in the xz plane.
In figure 5(a) we show the evolution of the magnetic field components at selected points for the NNT flow at a 15 % supercritical value, η = η crit /1.15 = 0.116 and R m = 5.12. This value of R m , as defined in (5.1), is approximately 2.5 times larger than for the 15 % supercritical case of the Willis dynamo. In figure 5(b) we show the results for B x and B y using xz averages. The x component of the mean field grows at the same rate as the actual field, but the z component decays.
For the TTT flow, we show the results for the marginally excited case with η = 0.083 in figure 6. For the TTT flow, we show in figure 6 the results for the marginally excited case with η = 0.083. Here, the r.m.s. velocity is smaller than for the NNT flow,  so the magnetic Reynolds number is actually slightly less (4.05 instead of 4.47 for the NNT case). Furthermore, B x and B y now decay, both at different rates. For the 15 % supercritical TTT flow, on the other hand, the actual magnetic field is growing, but the xy average remains small. This does not necessarily imply that there is no mean field. Indeed, a finite mean field is, in this case, obtained by taking column averages just over the z direction. This is shown in figure 7, where we compare the resulting column averages of the magnetic fields for the Willis, NTT and TTT dynamos. We see that, even though we found a clear mean field for the Willis flow through planar averaging, we also find a clear mean field from just averaging over the z direction. Indeed, by computing the ratio of the r.m.s. values of the column averaged mean field and the total field, q = B rms /B rms , we now find the value 0.81 for the Willis dynamo, 0.08 for the NNT dynamo and 0.45 for the TTT dynamo. The latter value was already indicated in table 1 with an asterisk. The fact that the value for the NNT flow is small suggests that the flow does not have an important column average and that the appropriate average is here indeed the xy average.
It is important to emphasize that the Willis dynamo is completely isotropic with respect to the x, y and z directions. Therefore, all three planar averages give equally strong mean fields in this linear dynamo problem. In figure 2, we plotted B x (z * ), but this cannot be the same mean field seen for the Willis dynamo in figure 7, which is FIGURE 8. Dependence of the real and imaginary parts ofη ij on ω for the Willis flow in the marginally exited case with η = 0.403 and for k = 1. The off-diagonal components vanish, Reη xx (blue) is always positive, Imη xx (black) is always negative andη yy (red) changes sign from negative to positive values as ω increases. The dotted lines give approximate fits: instead a field B y (x) that is obtained through yz averaging. The third component, B z (y), is also excited and can be seen through xz averaging. It is only in the nonlinear case that one of the three planar averages will survive, as has been demonstrated in connection with helical isotropic turbulence; see figure 6 of Brandenburg (2001). The other two planar averages begin to decay in the nonlinear regime. Based on the analysis of the time series of the components of the magnetic field, we find mean-field dynamo action for the NNT and TTT cases. However, we still cannot say much more about the nature of the dynamo action. To make further progress, we now use the TFM to determine the underlying mean-field transport coefficients. Their knowledge would allow us to model the generation of mean magnetic fields and thereby to characterize the nature of the dynamo process. This is discussed in the next section.
6. Test-field results for the different dynamos 6.1. Results for the Willis flow We begin by showing in figure 8 the dependence ofη ij on ω for k = 1. We recall that k = 1 corresponds to the lowest wavenumber within our domain of size 2π. We see thatη xx andη yy have non-vanishing real parts at ω = 0. Furthermore, Reη xx is always positive and approaches zero monotonically. By contrast, Reη yy is negative, but grows and crosses zero at ω = 0.3, reaches a maximum at ω = 0.7 and then falls off toward zero.
For ω = 0,η xx becomes complex whileη yy remains real. Theη xx component determines the evolution of A x and correspondingly B y , which is decaying even in the marginally excited case; see figure 2. The time dependence of B leads a memory effect FIGURE 9. Dependence ofη xx (red) andη yy (blue) on k for the Willis flow in the marginally exited case with η = 0.403 and for ω = 0. The dashed line denotes the fit −0.233 + 0.11k 2 and will be discussed in § 7.2. in the evolution of A x , i.e. to a frequency-dependent time delay in the electromotive force (Hubbard & Brandenburg 2009). By contrast,η yy is real for time-independent mean magnetic fields, but it is negative for ω → 0 and k → 0; see figure 9. However, η yy is not sufficiently negative to overcome diffusive decay, because η +η yy is still positive. This is surprising, but we have to realize thatη yy depends also on z; see figure 10.
In figure 11 we plot the local minima, maxima and averages ofη xx andη yy versus η. Those z averages are denoted by an overbar. We see that the onset of dynamo action (η = η crit ≈ 0.403) coincides with the point where η +η min yy = 0. Interestingly, it is 16 A. Brandenburg and L. Chen apparently not the spatial average ofη yy (z) which must become negative for instability, but the minimum ofη yy (z).

6.2.
Results for the NNT and TTT flows For the NNT flow, the resulting profiles for the components of the turbulent magnetic diffusivity are shown in figure 12. We see that bothη xx andη yy become negative, but not quite as much as to make the sum of η +η ij negative. Nevertheless, it is still likely that this mean-field dynamo is due to the negative turbulent magnetic diffusivity, because the full system is more complicated due to the presence of pumping effects and the non-locality in space, for example.
For the TTT case, mean-field dynamo action has only been obtained for column averaged fields. Applying the TFM for xy averages, we find that the only nonvanishing components of the eight transport coefficients areη xx andη yy . Both are positive, so no mean-field dynamo action can be expected for xy planar averages. As we have seen above, the appropriate average is the column average. This case is more complicated and involves altogether 27 turbulent transport coefficients; see also Warnecke et al. (2018) for a recent study in spherical coordinates, where longitudinal averages were used. We will not consider this case here, but adopt instead xy and xz averages, as was done by Andrievsky (2015) in the investigation of the Taylor-Green flow, where mean fields were also only found through column averaging. They confirmed the presence of negative turbulent magnetic diffusivity for this flow, which was first found by Lanotte et al. (1999) and was not seen when using just planar averages (Devlen et al. 2013). In figures figure 13(a) and 13(b), we show the results for the TTT flow as functions of x and y, respectively. Note that bothη zz (x) andη zz (y) are negative over extended ranges. The sum η +η zz is still positive, but we have to remember that the mean-field dynamo works in this case with z averages, so the yz and xz averages adopted here are prone to additional cancellation. This suggests that the mean-field generation in this case is indeed of the type of a negative turbulent diffusivity dynamo.
As we will show next, for the π 3 domain, we always find a non-vanishing average, but it may not be a mean-field dynamo, because the scales of averaging and of the fluctuations are very similar. To get an idea about the resulting mean-field transport coefficients, we now solve the test-field equations in a π 3 domain using the standard TFM for the NNT and TTT flows. However, given that the Reynolds rules do not apply here, the TFM results cannot be fully reliable.
In figures 14 and 15 we show test-field results for the NNT and TTT cases in π 3 domains using the appropriate lateral and vertical boundary conditions. For both flows, we also have done calculations in domains where the extent in the y or z directions FIGURE 14. Dependences ofα ij andη ij on y for the NNT flow with k = 1 and ω = 0 in a π 3 domain using η = 0.133. For the diagonal components, we show the sum η +η ii . The dotted lines denote the result using averaging over a (2π) 2 plane. Here we only show the results in the range 0 y π for the NNT flow and in the range 0 z π for the TTT flow.
We also compare with solutions over the full (2π) 2 cross-section. The actual solutions for the response to the test fields are then unchanged, but now the planar averages extend over the full (2π) 2 plane, so there can be complete cancellation for certain variables -notably the two components ofα ij for i = j, as well as for the two components ofη ij for i = j. 7. Comparison with mean-field dynamos 7.1. The absence of α effect We now discuss in more detail the possibility of mean-field dynamo action based on the present results. Given that the diagonal components of α ij are finite, there is the possibility of α 2 dynamo action, except that the values of α appear too small in the sense that the dynamo number, | α |/ η + η t k 1 , is below the estimated critical value of unity. Here, η t is the average of the two diagonal components of the magnetic diffusivity tensor. Furthermore, given that the off-diagonal components ofη ij are finite, there could be a Rädler effect, also known at Ω × J effect, because the off-diagonal components ofη ij contribute to a term in the mean electromotive force of the form E = · · · + δ × J, where δ is often also aligned with the axis of rotation, Ω. For our planar averages, its components are given by δ i = − 1 2 ijk η jk . A well-known problem with this latter idea, however, is that the Rädler effect alone cannot explain an increase of the magnetic energy of the mean field. It can only work in conjunction with other effects such as shear. In the presence of an α effect, it can also make the solutions oscillatory and cause migratory dynamo waves, which becomes more pronounced in a periodic domain, as can be seen by solving the corresponding eigenvalue problem.
In the present case, we need to address the questions whether, first, the α effect is strong enough to produce α 2 or α-shear (αΩ) dynamo action, depending on whether or not the mean flow plays a role, and second, whether the Rädler effect plays a role, possibly in conjunction with effects other than the mean flow, for example the α effect. The first point, in fact, was already discussed by Andrievsky (2015). Assuming the total magnetic field can be written as a series expansion where is a small scaling factor that relates the slow-changing spatial variables to the fast-changing ones. The α effect can be written as an eigenvalue problem for the where Λ 0 is the eigenvalue, α is a tensor, U × S i is the ith column of α, U is the flow field, S i is the solution of and I is the induction operator, If the flow is parity invariant, U(−x) = −U(x), (7.5) then S i must be anti-invariant, so the operator of the α effect is α = 0. From (3.6) and (3.9), we see that the three optimal flows are all parity invariant in the full (2π) 3 domain, hence no α effect is expected at the leading order.
7.2. The negative turbulent magnetic diffusivity dynamo To model a negative turbulent magnetic diffusivity dynamo, we must take care of the fact that the high wavenumbers are not being destabilized at the same time. As we have seen from figure 9, η t is negative only for k 1.5. A simple way of taking the k dependence of the turbulent magnetic diffusivity into account is to expandη yy (k) up to the next order in the diffusive effects (which are even in k), i.e. η yy (k) =η (0) yy +η (2) yy k 2 + · · ·. (7.6) Looking at figure 9 for the Willis flow, we see that in the proximity of k = 1, which corresponds to the largest scale in the computational domain of 2π, the k-dependence ofη yy (k) can well be described by the parametersη (0) yy ≈ −0.233 andη (2) yy ≈ 0.11. In addition, there is still the microphysical magnetic diffusivity, which is positive (η = 0.403). The mean-field equations for the magnetic field components decouple. For the purpose of this problem, we just need to consider the equation for A y , which can then be written as Note that the minus sign in front of the fourth derivative corresponds to positive diffusion ifη (2) yy is positive, and so does the plus sign in front of the second derivative, unless the term in squared brackets is negative, which is the case we are considering here.
We have seen from figure 10 that η +η yy just barely approaches zero and does not become negative. This is unexpected. To understand the problem, we now solve (7.7) numerically with an assumed amplitude for the variation ofη (0) yy of the form where quantifies the amplitude of the spatial variation around the average value, which is η (0) yy . It turns out that, with the parameters given in figure 9, and η = 0.403 for the microphysical magnetic diffusivity, marginally excited solutions are only possible when > 1.99. On the other hand, when trying to fit the functional form ofη (0) yy in figure 10, it turns out that it is possible with = 1.99, but only if η (0) yy = −0.133 instead of −0.233, as expected from the fit to the k dependence.
It is not entirely clear how to interpret these findings. We do not know enough about such dynamos whose parameters depend both on z and k at the same time. Nevertheless, it seems that the overall idea of a negative turbulent magnetic diffusivity dynamo is the right one, but that the correct description is more complicated than what is suggested by (7.7). Effects such as pumping and additional non-localities have been ignored.  TABLE 2. Critical values of A α and the corresponding frequencies Im λ for different values of A δ for the NNT and TTT dynamos. The type of averaging employed for obtaining the mean-field coefficients is listed under 'aver' (xy or xz). All solutions are standing waves.

Mean-field excitation conditions for the NNT and TTT cases
To address the possibility of dynamo action from the α and Rädler effects, we use the profiles ofα ij (z) andη ij (z), as obtained from the TFM. To get an idea of how close to the dynamo onset we are, we scale the dynamo active coefficients by an amplitude factor, i.e.α ij →α ij A α for i = j, andη ij →η ij A δ for i = j. We then choose a value of A δ and determine the critical values of A α above which there is dynamo action, i.e. a growing solution. All solutions are oscillatory and correspond to standing waves. The result is shown in table 2.
We see that for the NNT flow, A α decreases with increasing values of A δ 5, so the dynamo becomes slightly easier to excite. For A δ = 10, however, A α increases again. The oscillation frequency increases slightly as A δ increases. For the TTT model, on the other hand, A α always increases with A δ , i.e. the δ effect does not contribute to dynamo dynamo action, but suppresses it. In both cases, the values of A α are small unless the scaling factor A δ is at least O(10).

Discussion and conclusions
There is only a small number of successful experimental dynamos to date (Gailitis et al. 2000;Stieglitz & Müller 2001;Monchaux et al. 2007). Several other dynamo experiments are currently in operation; see the review by Adams et al. (2015), who also discuss the newer Madison dynamo experiment and the Derviche-Tourneur sodium experiment. They all work with liquid sodium, and they all involve flows with significant swirl -in anticipation that those types of dynamos would be most suitable for driving dynamo action most easily. Different classes of optimal dynamos display flows largely reminiscent of those with an α effect, so it was natural to ask whether such an effect played a role in generating the magnetic field in those cases. It now turns out that this does not have to be the case. Instead, the optimal dynamo of Willis (2012) is driven by a negative turbulent magnetic diffusivity. This was rather unexpected, because such dynamos are not very common and have not been studied much (Zheligovsky, Podvigina & Frisch 2001;Zheligovsky 2012;Devlen et al. 2013).
The concept of negative turbulent magnetic diffusivity is somewhat mysterious and may have seemed to be more like a qualitative excuse for lack of a more definitive term than a quantitative and rigorous statement. In fact, we are not aware of a quantitative mean-field model employing negative magnetic diffusivity until now. This would need to be done with sufficient care to prevent small-scale instabilities. Here we have presented such a model that is stabilized by the inclusion of hyperdiffusivity. In the parameter regime of interest, it turned out that the sign of the coefficient of hyperdiffusivity is indeed such that it has a stabilizing effect.

A. Brandenburg and L. Chen
Among the systems with negative diffusivity and a stabilizing hyperdiffusivity is the Kuramoto-Sivashinsky equation, which has been employed as a model of forest fires (Hyman & Nicolaensko 1986). In that case, however, there is also an advection term, making the system nonlinear, and also the system size was large compared to the typical size of structures. This led to a rich spatio-temporal evolution. It is therefore of interest to ask whether such dynamics could possibly also be realized in an experimental or at least a numerical dynamo set-up.
Similarly to the Willis dynamo, the NNT dynamo also exhibits negative turbulent magnetic diffusivity. However, unlike the Willis dynamo, it is not isotropic and exists only for one of the three possible planar averages. Finally, the TTT dynamo shows no mean field after planar averaging. Nevertheless, a mean field exists also in this case, but it requires column averaging over only one coordinate direction. It is similar to the Taylor-Green flow, for which Lanotte et al. (1999) also found negative turbulent magnetic diffusivity, and the corresponding mean field can only be found through column averaging (Andrievsky 2015). Note that both NNT and TTT flows can be transformed into to a general Taylor-Green flow by a shift of π/2 in each direction. The spatial averaging then depends on the specific combination of field coefficients.
To assess the possibility of α or δ effect dynamos action in π 3 subdomains, we have compared with the corresponding mean-field dynamos. It turned out that both are strongly subcritical and would only become marginally excited when either the α effect or the δ effect are scaled up by factors between five and ten. These factors seem rather large, making a mean-field interpretation based on the α and δ effects in these cases unlikely. Thus, it now seems that the class of dynamos based on negative turbulent magnetic diffusivity is broader than previously anticipated and may include the class of optimal dynamos as well.