Introduction

The continuous development of new technologies in every scientific field is leading to dramatically increasing requirements for unconventional and fast computational systems. As the necessity of complex calculations becomes more demanding, especially for real-time and embedded applications, digital technology is not always able to fulfill the constraints of high velocity and limited power consumption with respect to the huge number of operations that must be performed.

In this sense, a promising solution can be provided by electromagnetic metamaterials, employed to guarantee fast and robust analog computations in different scenarios. In the literature, the feasibility to execute complex calculations by exploiting the exotic properties of photonic metastructures, such as solving integral equations, ordinary differential equations, or performing matrix-vector multiplications, has been widely demonstrated1,2,3,4,5,6. Photonic metastructures are suitable for performing mathematical operations literally at the speed of light by relying upon the light transmission and reflection caused by properly tuned metastructures, thus leading to the realization of rapid and accurate systems supporting the well-known digital techniques in specific tasks. Moreover, in the recent period, a great effort has been also directed towards the implementation of intelligent and cognitive metasurfaces, whose reconfigurability may unlock a significative advancement in computational field7,8,9,10,11,12. Besides, other proposed solutions involve the adoption of crossbars for the evaluation of matrix-vector multiplications for neural network applications13,14,15,16,17,18. By selecting the impedance values in the crossbar arrays, a linear combination of the input voltages can be opportunely translated into the corresponding output currents. Finally, few systems operating in the microwave regime have been implemented for operations such as matrix-vector multiplication and derivative19,20,21,22.

However, to the best of the Author’s knowledge, the adoption of magnetic metasurfaces operating in the low-frequency RF band for computational applications has not been analyzed in the literature so far. One of the advantages of employing magnetic metasurfaces in this peculiar frequency range relies on the circuital approach effectiveness to describe the overall structure23. Indeed, quantitative and analytically easily manageable parameters depending on the system geometry can be retrieved, thus providing accurate predictions and manipulation of the metasurface behavior. In the state of the art, analytical approaches based on the circuital models have already been developed and successfully applied to control the metasurfaces response in applications such as Wireless Power Transfer and Magnetic Resonance Imaging24,25,26,27,28,29,30. In addition, magnetic metasurfaces operating in the RF band, demonstrated to be effective in the propagation of slow waves, known as magneto-inductive waves,

useful in signal and power transmission31,32,33,34,35,36. Nevertheless, no computational or cognitive behavior was conferred to the metasurfaces in those works, thus limiting their impact. In addition to the circuital modelization, magnetic metasurfaces have also simple and low-cost fabrication procedures and can be dynamically reconfigured through variable loads, thus addressing photonic structures intrinsic limitations37,38,39,40,41,42.

Therefore, considering the aforementioned advantages and the actual gap in literature, the aim of this work is to investigate magnetic metasurfaces operating in the low-frequency RF band as potential candidates to support and integrate the existing computational analog devices (Fig. 1). To pursue this purpose, two different test-cases are conceived: the first model is designed to perform a linear combination of two input currents, allowing to arbitrarily select the complex coefficients of the operation, and providing an accurate output current as the calculation result; the second system is meant to extract the first N harmonics of a fundamental frequency from an arbitrary periodic input current, which are accurately transferred in amplitude and phase to N output elements. Prototypes for the linear combination model are fabricated by manually winding single strand copper wires while PCB technology is adopted to manufacture the harmonics extraction system. An assessment of their performance and practical implementation difficulties is carried out together with a comparison of the experimental results against the simulated outcomes.

Fig. 1
figure 1

Schematic representation of a computational system. N inputs are elaborated by a computational metasurface in order to provide M output.

The remainder of the paper is organized as follows: firstly, the analytical models for both the conceived test-cases are derived and explained in detail. Then, numerical simulations and experimental measurements performed on systems designed according to the analytical formulation are reported. Finally, a section is devoted to the discussion of both numerical and experimental results, highlighting the limitations and possible future developments.

Results and methods

Analytical formulation

We consider metasurfaces comprised of subwavelength magnetic unit-cells represented by accurately loaded loops or spirals. In such conditions, the i-th cell self-impedance and the mutual impedance between the i-th and j-th cells can be expressed as:

$$\begin{array}{c}{Z}_{ii}={R}_{i}+j\omega\:{L}_{i}+\frac{1}{j\omega\:{C}_{i}}\end{array}$$
(1)
$$\begin{array}{c}{Z}_{ij}=j\omega\:{M}_{ij}\end{array}$$
(2)

where \(\:{R}_{i}\) and \(\:{L}_{i}\) are the cell resistance and inductance, \(\:{C}_{i}\) is the capacitance applied to the cell and \(\:{M}_{ij}\) is the inductive coupling coefficient between the i-th and the j-th cells.

In general, a physical system including N interacting elements can be electrically described through the circuital equations:

$$\begin{array}{c}\left(\begin{array}{ccc}{Z}_{11}&\:\dots\:&\:{Z}_{1N}\\\:\vdots&\:\ddots\:&\:\vdots\\\:{Z}_{N1}&\:\dots\:&\:{Z}_{NN}\end{array}\right)\left(\begin{array}{c}{I}_{1}\\\:\vdots\\\:{I}_{N}\end{array}\right)=\left(\begin{array}{c}{V}_{1}\\\:\vdots\\\:{V}_{N}\end{array}\right)\end{array}$$
(3)

where \(\:{I}_{i}\) is the current flowing in the i-th element and \(\:{V}_{i}\) is the corresponding applied voltage.

By referring to the metasurface as the system, the elements in the diagonal of the \(\:Z\) matrix introduced in (3) (i.e. the unit-cells self-impedances) can be adjusted by properly selecting a capacitor that must be applied to the desired cell. On the contrary, the elements out of the diagonal (i.e. the inductive mutual coupling between unit-cells) solely depend on the geometry of the system and must be tuned through the individual unit-cell design (e.g., the spiral’s number of turns, the overall diameter and so forth), and by adjusting its relative position within the array.

Linear combination computation

Regarding the linear combination, a preliminary arrangement aimed at performing the operation was introduced in43. In this section, we present a more general and accurate analytical framework, which can lead to more complex and relevant scenarios.

To maintain the formulation simple without losing generality, let us consider a linear array made of 5 adjacent cells, as depicted in Fig. 2. External cells 1 and 2 are active, and the respective currents \(\:{I}_{1}\) and \(\:{I}_{2}\) are the system inputs. Cells 4 and 5 are passive and serve to select the linear combination coefficients. Further, we refer to the current flowing in the central cell, \(\:{I}_{3}\), as the system output, i.e. a linear combination of the inputs \(\:{I}_{1}\) and \(\:{I}_{2}\):

$$\begin{array}{c}{I}_{3}=\alpha\:{I}_{1}+\beta\:{I}_{2}\end{array}$$
(4)

with arbitrary complex coefficients \(\:\alpha\:\) and \(\:\beta\:\), correctly selected through the passive cells 4 and 5.

Fig. 2
figure 2

Schematic representation of the metasurface employed to perform the linear combination. The two more external cells provide the inputs (elements 1 and 2), the central cell acts as the calculation output (element 3), and the remaining passive cells (elements 4 and 5) allow to arbitrarily select the linear combination coefficients.

The above-described array can be efficiently described through the following linear system:

$$\begin{array}{c}\left(\begin{array}{ccccc}{Z}_{11}&\:0&\:{Z}_{13}&\:{Z}_{14}&\:0\\\:0&\:{Z}_{22}&\:{Z}_{23}&\:0&\:{Z}_{25}\\\:{Z}_{31}&\:{Z}_{32}&\:{Z}_{33}&\:{Z}_{34}&\:{Z}_{35}\\\:{Z}_{41}&\:0&\:{Z}_{43}&\:{Z}_{44}&\:{Z}_{45}\\\:0&\:{Z}_{52}&\:{Z}_{53}&\:{Z}_{54}&\:{Z}_{55}\end{array}\right)\left(\begin{array}{c}{I}_{1}\\\:{I}_{2}\\\:{I}_{3}\\\:{I}_{4}\\\:{I}_{5}\end{array}\right)=\left(\begin{array}{c}{V}_{1}\\\:{V}_{2}\\\:0\\\:0\\\:0\end{array}\right)\end{array}$$
(5)

It can be noticed from (5) that mutual impedances describing the interactions between more distant cells are neglected, even though the model is not theoretically limited to the coupling between strictly adjacent and next-neighboring cells pairs. Rigorously, this assumption does not hold in general, but the numerical simulations reported in the next section demonstrate that it can be verified with a properly designed cells arrangement. Furthermore, we assume that all the unit-cells are equal in terms of geometry and the distance between them (i.e., the periodicity) is identical for each element pair. Finally, the input currents are considered to be provided only by the voltage sources, without being affected by the coupling with other cells, which is valid if the following inequality holds:

$$\begin{array}{c}{V}_{i}\gg\:\sum\:_{j=1,j\ne\:i}^{5}{Z}_{ij}{I}_{j}\end{array}$$
(6)

As already mentioned for the mutual coupling coefficients, the numerical simulations show that it is possible to account for (6) without losing accuracy in the output results. Thus, by exploiting these designing hypotheses, the analytical formulation simplicity can be accomplished by reducing the number of parameters in the system, while at the same time preserving all the salient features of the investigated model. It is important to stress that the proposed arrangement is only one of the possible solutions to develop the desired computational kernel, and that a higher number of degrees of freedom provided by different geometries can be beneficial for obtaining even more flexible systems.

At this point, once the desired coefficients α and β are chosen, the reactance of cells 4 and 5 can be retrieved from (5). Accounting for the assumptions explained in this paragraph, closed form expressions for the required complex impedance values to be imposed in elements 4 and 5 are obtained as follows:

$$\begin{array}{c}{Z}_{44}=\frac{-{Z}_{33}{Z}_{s}{Z}_{y}\beta\:+\:{Z}_{33}{Z}_{x}^{2}\alpha\:+\:{Z}_{s}{Z}_{x}^{2}\alpha\:+\:{Z}_{s}{Z}_{x}^{2}\beta\:+\:{Z}_{s}{Z}_{x}^{2}-\:3\:{Z}_{s}{Z}_{x}{Z}_{y}\alpha\:-\:{Z}_{s}{Z}_{x}{Z}_{y}\beta\:-\:{Z}_{s}{Z}_{y}^{2}\alpha\:+\:{Z}_{s}{Z}_{y}^{2}\beta\:-\:{Z}_{s}{Z}_{y}^{2}+\:{Z}_{y}^{3}\alpha\:+\:{Z}_{y}^{3}\beta\:}{{Z}_{33}{Z}_{s}\alpha\:-\:{Z}_{s}{Z}_{y}\alpha\:+\:{Z}_{s}{Z}_{y}\beta\:+\:{Z}_{s}{Z}_{y}-\:{Z}_{y}^{2}\alpha\:-\:{Z}_{y}^{2}\beta\:}\end{array}$$
(7)
$$\begin{array}{c}{Z}_{55}=\frac{-{Z}_{33}{Z}_{s}{Z}_{y}\alpha\:+\:{Z}_{33}{Z}_{x}^{2}\beta\:+\:{Z}_{s}{Z}_{x}^{2}\alpha\:+\:{Z}_{s}{Z}_{x}^{2}\beta\:+\:{Z}_{s}{Z}_{x}^{2}-\:{Z}_{s}{Z}_{x}{Z}_{y}\alpha\:-\:3\:{Z}_{s}{Z}_{x}{Z}_{y}\beta\:+\:{Z}_{s}{Z}_{y}^{2}\alpha\:-\:{Z}_{s}{Z}_{y}^{2}\beta\:-\:{Z}_{s}{Z}_{y}^{2}+\:{Z}_{y}^{3}\alpha\:+\:{Z}_{y}^{3}\beta\:}{{Z}_{33}{Z}_{s}\beta\:+\:{Z}_{s}{Z}_{y}\alpha\:-\:{Z}_{s}{Z}_{y}\beta\:+\:{Z}_{s}{Z}_{y}-\:{Z}_{y}^{2}\alpha\:-\:{Z}_{y}^{2}\beta\:}\end{array}$$
(8)

where \(\:{Z}_{x}\) is the mutual impedance between adjacent cells, \(\:{Z}_{y}\) is the mutual impedance between next-neighboring cells (e.g., the coupling between cell 1 and 3 with respect to Fig. 2) and \(\:{Z}_{s}\) is the self-impedance of both input cells.

Clearly, since the system is passive, the possible span of coefficients α and β is bound by the provided input power and the system ohmic losses. More in detail, the feasible coefficients couples are those requiring a real part greater than 0 for both \(\:{Z}_{44}\) and \(\:{Z}_{55}\), otherwise the system would need additional input power to perform the desired calculation.

Harmonics extraction

The second investigated application consists in the extraction of the first N harmonics, both in amplitude and phase, of a determined fundamental frequency \(\:{f}_{0}\) from a periodic input signal. Practically, the system input is a periodic current flowing in the corresponding loop while the currents relative to the first N signal harmonics of \(\:{f}_{0}\) are mapped on the N system output loops. As a matter of fact, a generic periodic current signal with a period P can be approximated as:

$$\begin{array}{c}I\left(t\right)=\sum\:_{i=1}^{N}{I}_{i}\text{cos}\left(2\pi\:\frac{i}{P}t-{\phi\:}_{i}\right)\end{array}$$
(9)

where \(\:{I}_{i}\) and \(\:{\phi\:}_{i}\) are, respectively, the amplitude and the phase of the i-th harmonic phasor. Thus, the conceived system must be able to identify the first N phasors \(\:{I}_{i}{e}^{j{\phi\:}_{i}}\) of the overall input signal \(\:I\left(t\right)\) provided that \(\:1/P\) coincides with \(\:{f}_{0}\). In other words, the fundamental frequency must be known to tune the system and extract the harmonics. Nevertheless, it is possible to reconfigure the system in order to recognize harmonics of signals with different periodicities.

In order to implement this computational task, let us consider a single active input loop where the current periodic signal \(\:I\left(t\right)\) is flowing, N passive spirals each resonating at one specific frequency \(\:i/P\), and N passive output loops where the correct current phasor \(\:{I}_{i}{e}^{j{\phi\:}_{i}}\) must be present. Since the spirals interposed between the input and the output loops are resonating at different frequencies, they are excited only by the input harmonic at the corresponding frequency. Moreover, their Q-factor is generally quite elevated, and consequently they are not significantly affected by mutual couplings or harmonics at frequencies different from their own respective resonance. Therefore, by recurring to the superposition principle in linear systems, we can first derive a model valid for the interaction between the input loop, one resonating spiral and the corresponding output loop. Then, we can apply the same derivation for each harmonic in order to properly design the overall system. In the following analysis, the input coil, the resonating spiral, and the output coil are labelled respectively with indices 1, 2 and 3, as schematically displayed in Fig. 3 where one functional unit-cell of the overall computational metasurface is depicted.

Fig. 3
figure 3

Schematic representation of one functional unit-cell of a harmonics extracting metasurface. The input loop with the periodic signal \(\:I\left(t\right)\) is coupled to a resonant element which is designed to transfer a specific harmonic in amplitude and phase to the corresponding output loop.

In this case, we assume as valid the hypothesis of mutual coupling only between strictly adjacent coils, thus neglecting all others mutual impedances. In such conditions, we can write the current flowing in the resonating spiral as:

$$\begin{array}{c}{I}_{2}=\frac{-{Z}_{12}{I}_{1}-{Z}_{23}{I}_{3}}{{R}_{2}}\end{array}$$
(10)

where we consider the spiral’s impedance equal to \(\:{R}_{2}\) since we are operating at its resonance frequency, while \(\:{Z}_{12}\) and \(\:{Z}_{23}\) are the spiral’s coupling coefficients with the input and output loops, respectively. Moreover, the output current can be expressed as:

$$\begin{array}{c}{I}_{3}=\frac{-{Z}_{23}{I}_{2}}{{Z}_{33}}\end{array}$$
(11)

where \(\:{Z}_{33}\) is the self-impedance of the output coil.

At this point, we must impose the input current equal to the output current (i.e. \(\:{I}_{1}={I}_{3}\) in amplitude and phase). This condition is effective only at the resonance frequency of the spiral 2, thus implementing the extraction of a single harmonic. Thus, by combining (10) and (11), we can retrieve the loading condition for the output loop:

$$\begin{array}{c}{Z}_{33}=\frac{{Z}_{12}{Z}_{23}+{Z}_{23}^{2}}{{R}_{2}}\end{array}$$
(12)

Let us consider the input element 1 and the resonating element 2 to be coaxial, so that \(\:{Z}_{12}=+j\omega\:{M}_{12}\), and the output element 3 and the resonating element 2 to be coplanar, so that \(\:{Z}_{23}=-j\omega\:{M}_{23}\). As a consequence, the retrieved load to be imposed at the output loop is purely real and can be expressed as:

$$\begin{array}{c}{R}_{3}=\frac{{\omega\:}^{2}{M}_{23}\left({M}_{12}-{M}_{23}\right)}{{R}_{2}}\end{array}$$
(13)

while the output current has the following formulation:

$$\begin{array}{c}{I}_{3}=\frac{{\omega\:}^{2}{M}_{12}{M}_{23}}{{R}_{2}{R}_{3}+{\omega\:}^{2}{M}_{23}^{2}}{I}_{1}\end{array}$$
(14)

As evident from (14), since the factor multiplying the input current \(\:{I}_{1}\) is real, the output and input currents have the same phase. Finally, the output resistance \(\:{R}_{3}\:\)can be opportunely chosen to transfer the correct amplitude to the output element. Notably, the system must be designed in order to guarantee that \(\:{R}_{3}\) is greater than 0, namely \(\:{M}_{12}>{M}_{23}\).

Results

We realized two numerical models in order to demonstrate the effectiveness of the analytical methodologies derived in the previous section. The test-cases were designed and analyzed by employing a commercial Method of Moments full wave solver (Feko Suite, Altair, Troy, MI, USA). After that, we fabricated prototypes according to the conceived scenarios in order to validate the numerical results. Regarding the experimental measurements, the impedance matrices, which completely characterize the systems, were acquired through a Vector Network Analyzer (Fieldfox series VNA N9918A, Keysight, Santa Rosa, CA, USA) and employed to evaluate the systems outputs through MATLAB. The VNA was calibrated using a SOLT 85,521 A calibration kit (Keysight, Santa Rosa, CA, USA), and the impedance matrices were derived from the measured S-parameters assuming a 50 Ω reference resistance. The input phase reference plane was established at the VNA input ports.

Linear combination computation: numerical and experimental results

The numerical model was developed by following the pictorial representation depicted in Fig. 2. Each unit-cell was conceived as a 20-turn solenoid with a diameter of 10.5 mm, a total height of 8.4 mm and realized with an AWG 28 single strand copper wire. The periodicity, i.e. the distance between the central point of two adjacent solenoids, was set equal to 14 mm. The simulations were performed at 6 MHz, thus fully respecting the quasi-static approximation. As explained in the analytical model derivation, the most external solenoids 1 and 2 serve as inputs and the corresponding currents are summed in the output central solenoid 3, opportunely weighed for the coefficients imposed by the remaining solenoids 4 and 5. More in detail, the input cells were loaded with adequate capacitors in order to resonate at 6 MHz and with resistances devised to control the desired input magnitudes. Conversely, solenoids 4 and 5 were equipped with capacitors and resistors evaluated following (7) and (8), thus implementing the desired linear combination calculation. Finally, the prototype was assembled by winding the AWG 28 wire around 3D printed cylindrical PLA supports, which were in turn mounted on a 0.8 mm thick FR4 substrate. The FR4 board was equipped with PCB etched copper paths to allow the soldering of the resistors and capacitors evaluated through the design process. A depiction of both numerical and experimental set-ups is reported in (Fig. 4a,b).

Fig. 4
figure 4

Linear combination computation test case: CAD model of the conceived system (a) and fabricated prototype (b). The inset reports the schematic representation of the system in order to identify the inputs and output cells.

As stated in the Analytical Formulation section, physically realizable computations require that the solenoids 4 and 5 impedances evaluated through (7) and (8) present both a positive real part. Such constraint is visualized in (Fig. 5a,b) for an arbitrarily selected \(\:\alpha\:=0.7j\) and different coefficients \(\:\beta\:\).

Fig. 5
figure 5

Span of possible coefficients \(\:\beta\:\) with the arbitrarily selected \(\:\alpha\:=0.7j\) for the linear combination test case. Both impedances to be imposed in solenoids 4 and 5 (i.e. (a) \(\:{Z}_{44}\) and (b) \(\:{Z}_{55}\)) must have a positive real part, leading to feasible \(\:\beta\:\) ranging from − 0.4 to 0.

As evident from Fig. 5, regarding this specific model and for the coefficient \(\:\alpha\:=0.7j\), the set of possible choices for the coefficient \(\:\beta\:\) lies between \(\:-0.4\) and \(\:0\), where both the required impedances have a positive real part. In fact, the realizable range of output currents is limited by the dissipated power in the structure, which must be at most equal to the active power provided by the source. Attempting to achieve an output current that results in higher dissipated power would require additional energy to be introduced into the system, which is mathematically equivalent to the presence of a negative resistance. Notably, a different set-up, with a larger number of degrees of freedom, may provide different and wider sets of coefficients combinations. In fact, increasing the number of unit-cels leads to a larger N×N impedance matrix (where N is the unit-cells number), whose diagonal can be modified by applying loads to the individual unit-cells, so that the design space expands. In Fig. 6a–d, ideal, numerical and experimental linear combination outputs for 4 different coefficients combinations are reported and compared. For each combination, the input solenoids are loaded with a 15 Ω resistor and a 161 pF capacitor, while the output solenoid is equipped with a 1 Ω resistor and a 161 pF capacitor. Then, in Table 1 the capacitance and resistance values applied to cells 4 and 5 are listed.

Fig. 6
figure 6

Comparison among ideal, numerical and experimental calculation outcomes for different linear combination arrangements: (a) \(\:\alpha\:=0.7j\) and \(\:\beta\:=\)-0.2, (b) \(\:\alpha\:=0.5j\) and \(\:\beta\:=\)-0.4, (c) \(\:\alpha\:=0.3j\) and \(\:\beta\:=0.6j\), (d) \(\:\alpha\:=-0.2\) and \(\:\beta\:=\)-0.4. In general, it is possible to observe a good agreement between the ideal output and the one provided by the conceived system.

Table 1 Resistors and capacitors applied to solenoids 4 and 5 in order to implement the desired combination of coefficients for the linear combination test case.

Both numerical and experimental outputs provide a valid approximation of the ideal calculation. The errors, which can be appreciated on the scatter plots in Fig. 6, are mainly caused by the influence of the couplings on the input currents in elements 1 and 2, meaning that (6) is not perfectly verified. On the contrary, couplings with cells distant more than two times the periodicity are actually negligible, as shown in the following Fig. 7. For instance, the mutual coupling between two cells distant 3 times the periodicity (i.e., 43.5 mm) is 3.3% of the strictly adjacent cells coupling and, consequently, can be neglected without significantly affecting the output accuracy.

Fig. 7
figure 7

Mutual coupling between two solenoids unit-cells adopted in the linear combination test case as a function of their respective distance. While cells placed at 2 periodicity distance (next-neighbors) are characterized by a significative coupling (10% of the coupling between strictly neighboring cells), cells distant 3 periodicities present a coupling that drops at 3.3% and can be safely neglected.

In Table 2, root mean square errors and standard deviations between experimental and ideal current outputs are reported, as evaluated with the following expression:

$$\begin{array}{c}err=\frac{\sqrt{{\left[real\left({I}_{measured}\right)-real\left({I}_{ideal}\right)\right]}^{2}+{\left[imag\left({I}_{measured}\right)-imag\left({I}_{ideal}\right)\right]}^{2}}}{\left|{I}_{ideal}\right|}\end{array}$$
(15)

From Table 2, the general good agreement between ideal and experimental results, already qualitatively highlighted in Fig. 6, can be confirmed, with mean errors not exceeding 14.7% and thus fully validating the proposed approach.

Table 2 Root mean square errors and standard deviations of the experimental output currents with respect to the ideal computations.

Moreover, the robustness of the system to errors in practical scenarios is a critical aspect to consider. While the required impedances are derived analytically using parameters obtained from ideal full-wave simulations, a physical implementation is inevitably subject to noise, manufacturing imperfections, and tolerances in lumped components. As a result, the actual impedance values of the unit cells may deviate from their theoretical targets, potentially compromising the accuracy of the desired computation.

To evaluate this effect, we conducted a numerical robustness analysis by introducing a ± 1% variation to the self-inductances of cells 4 and 5 (mimicking fabrication issues and noise), as well as to the associated lumped resistors and capacitors (to evaluate tolerances). For each perturbed configuration, the system’s output currents were computed for 10 randomly selected input vectors, and then compared to the ideal output obtained using the nominal values. The resulting errors on the system output, expressed as root mean square errors across all coefficient pairs, are summarized in Table 3, revealing a robust behavior and proving the practical implementation feasibility.

Table 3 Root mean square errors of the output currents affected by impedance errors and lumped components tolerances with respect to the ideal output currents.

Harmonics extraction: numerical and experimental results

The numerical model conceived to demonstrate the extraction of the harmonics of a determined fundamental frequency from a periodic input signal consisted of an input loop, 8 resonating spirals, and 8 output loops (Fig. 8a). The periodic current flowing in the input loop was synthetized as a sum of 8 harmonics with a fundamental frequency equal to 5 MHz and arbitrarily selected amplitudes and phases. Thus, the system was meant to map these harmonics of the input signal (from 5 MHz to 40 MHz) on the currents flowing in the external output loops.

In detail, the input loop was placed 10 mm above the metasurface and presented a 25 mm radius. Regarding the metasurface design, the 8 resonating 5-turn spirals, that serve to transfer each harmonic to the corresponding output loop, were conceived with an inner radius of 4 mm, an external radius of 8 mm and a periodicity of 19 mm. Finally, the metasurface output loops were realized with a radius of 4 mm and a periodicity of 21 mm, positioned 1 mm externally and in a coplanar fashion with respect to the corresponding spirals. Regarding the manufacturing process, PCB technology was selected to fabricate the prototype. All the system elements were realized with a 35 μm thick copper trace. The substrate was FR4 with a 0.1 mm thickness for the metasurface, while a 0.8 mm thick FR4 was employed for the input loop (Fig. 8b). Opportune copper paths were added to allow the soldering of capacitors and resistors required according to (13) to perform the desired computational task.

In Fig. 9, we reported the currents distribution in the system for two exemplificative harmonics, i.e. 10 MHz (Fig. 9a) and 30 MHz (Fig. 9b), obtained through numerical simulations. From a visual inspection, it can be pointed out the same current amplitude between the input and output loops for the two respective harmonics, while currents do not circulate in other cells. This proves that, as described in the Analytical Formulation section, for each harmonic flowing in the input loop, only the spiral resonating at the corresponding frequency is activated. In this way, the first 8 harmonics of the input signal can be properly transferred through the superposition principle to the output loops. Moreover, the 8 harmonics imposed as input and those extracted by the computational metasurface, in terms of both magnitude and phase, are summarized in (Fig. 10a,b), comparing ideal, numerical and experimental data. Besides, Table 4 reports the root mean square errors between ideal and experimentally measured harmonics evaluated according to Eq. 15. It can be noticed that the proposed arrangement is able to effectively accomplish the planned computational task, with the maximum experimental errors equal to 11.8% (for amplitude) and 18.3% (for phase) at 25 MHz. As for the linear combination test-case, also for harmonic extraction experimental implementations, component tolerances, particularly those of the lumped loads, represent a significant source of error. Consequently, the robustness of the system to such variations is a key factor to assess. As discussed in the analytical formulation section, the resistors connected to the output loops play a crucial role in ensuring the correct transfer of harmonic magnitudes, while capacitors guarantee the filtering behaviour by providing the desired resonance frequencies. To evaluate the impact of loads tolerances, manufacturing errors and noise on harmonic extraction, we introduced a random ± 1% variation to the nominal load and self-impedance values and computed the resulting error in the extracted harmonics. The outcomes of this analysis are summarized in Table 5, confirming the excellent device robustness against the aforementioned non-idealities.

Then, Fig. 11 compares the input overall periodic signal and the reconstructed one obtained by summing the harmonics circulating in the metasurface external loops, both for simulated and experimental scenarios. Since the manufactured metasurface is characterized by higher losses with respect to the simulated structure44, the distance between the input loop and the kernel had to be reduced to 1 mm in order to guarantee a correct harmonic evaluation. This modification was necessary in order to increase the coupling between the input and the metasurface, thus compensating for the additional losses as predicted in (14). As evident, both the numerical and measured reconstructed signals are excellent representations of the ideal input current. To quantitatively verify the signals similarity, the correlation coefficients between the input signal and the numerical and experimental reconstructed signals were evaluated, resulting in 0.997 and 0.991 respectively, thus confirming the excellent performance of the arrangement. Finally, we assessed the effect of each harmonic on non-corresponding output loop by evaluating the Inter-Channel Rejection Ratio, defined as follows:

$$\begin{array}{c}IRR=10{\text{log}}_{10}\frac{{I}_{j}}{{I}_{i}}\end{array}$$
(16)

where \(\:{I}_{i}\) is the amplitude of the correct harmonic extracted in the i-th loop, and \(\:{I}_{j}\)​ is the amplitude of undesired harmonics circulating in the other loops caused by \(\:{I}_{i}\). The results are reported in Table 6 where an excellent independence of each output loop with respect to the others can be observed.

Fig. 8
figure 8

Harmonics extraction test case: CAD model (a) and fabricated PCB prototype (b) of the conceived metasurface. The inset in (b) shows the PCB input loop.

Fig. 9
figure 9

Harmonics extraction test case: current distribution evaluated at 10 MHz (a) and at 30 MHz (b). In both cases, the harmonic is correctly transferred in amplitude and phase to the corresponding output without affecting the other cells in the system.

Fig. 10
figure 10

Harmonics extraction test case: comparison among the individual input harmonics and the corresponding numerical and experimental results in terms of (a) magnitude and (b) phase. The system is able to accurately transfer the harmonics in the correct output cells.

Fig. 11
figure 11

Input signal and signals reconstructed by summing the retrieved harmonics (both numerical and experimental). An overall satisfying agreement can be observed in the comparison.

Table 4 Mean square errors in the harmonics extraction for the measured configuration.
Table 5 Mean square errors in the harmonics extraction in case of a 1% tolerance applied to the nominal loads and self-impedances.
Table 6 Inter-Channel Rejection Ratio (IRR, expressed in dB) demonstrating the excellent independence of each loop with respect to the others.

Discussion

In this paper, we introduced the concept of analog computing through magnetic metasurfaces in the low radiofrequency regime by exploiting inductive coupling. In particular, we developed two analytical models which can be employed for the realization of systems capable to: (i) evaluate the linear combination between two current inputs with arbitrary weighting coefficients, and (ii) extract the first 8 harmonics of a fundamental frequency from a generic periodic input current. In both cases, the analytical framework indicates the lumped loads that must be applied to each unit-cell in order to achieve the desired output. We provided numerical and experimental designs to validate the models, with simple and low-cost manufacturing techniques, which include winded copper wire solenoids for the liner combination test case and PCB printed cells for the harmonics extraction case. We obtained promising results, with experimental root mean square errors that does not exceed 15% for the linear combination model and 18% for the harmonic extraction system, thus proving the possibility to employ magnetic metasurfaces for computational purposes.

Regarding the first test case (i.e. the linear combination), we showed that the set of possible coefficients that can be chosen is limited by the impedance loading conditions, since the loads must have a positive real part. However, more complex designs involving a larger number of unit-cells and, consequently, more degrees of freedom can be explored to overcome the aforementioned limitation. Notably, linear combinations can be interpreted as scalar products between vectors, and their extension to matrix–vector multiplications is fundamental to many numerical methods. These include the approximation of equation solutions and more advanced operations such as derivatives and integrals. Therefore, the approach presented in this work can serve as a foundational step toward the development of analog computing architectures capable of implementing a wide range of numerical computations.

It must be also underlined that the fabrication procedure is of particular importance due to possible additional losses and components tolerances that may occur. In fact, in the second test case (i.e. the harmonics evaluation), an added resistor is employed to retrieve the correct harmonic in terms of magnitude and, consequently, must be realized with sufficient accuracy.

As future perspectives, an additional value of the proposed technology consists in the system dynamic reconfiguration by modifying the unit-cells reactance through the adoption of varactors, thus achieving multiple computational capabilities with the same hardware. Moreover, further studies will be directed to the improvement of system performance in terms of accuracy, leading to the possibility of realizing reliable computational devices with multifrequency capabilities through the harmonics recognition, and to the exploration of different possibilities, including large matrix-vector multiplications and equation solutions. Clearly, while larger systems may enable in principle more complex operations with multiple inputs and outputs, thereby broadening the scope of possible calculations, deeper studies are required to evaluate physical constraints and error accumulation due to fabrication tolerances and lumped-element inaccuracies—factors that are particularly critical given the resonant behavior of the proposed structures. These aspects will be addressed in future works.