Quantum nanomagnets in on-surface metal-free porphyrin chains

Unlike classic spins, quantum magnets are spin systems that interact via the exchange interaction and exhibit collective quantum behaviours, such as fractional excitations. Molecular magnetism often stems from d/f-transition metals, but their spin–orbit coupling and crystal field induce a significant magnetic anisotropy, breaking the rotation symmetry of quantum spins. Thus, it is of great importance to build quantum nanomagnets in metal-free systems. Here we have synthesized individual quantum nanomagnets based on metal-free multi-porphyrin systems. Covalent chains of two to five porphyrins were first prepared on Au(111) under ultrahigh vacuum, and hydrogen atoms were then removed from selected carbons using the tip of a scanning tunnelling microscope. The conversion of specific porphyrin units to their radical or biradical state enabled the tuning of intra- and inter-porphyrin magnetic coupling. Characterization of the collective magnetic properties of the resulting chains showed that the constructed S = 1/2 antiferromagnets display a gapped excitation, whereas the S = 1 antiferromagnets exhibit distinct end states between even- and odd-numbered spin chains, consistent with Heisenberg model calculations. Quantum nanomagnets, which display collective quantum behaviours, serve as important components in modern quantum technologies, but their fabrication has remained challenging. Quantum nanomagnets have now been constructed spin by spin in metal-free porphyrin chains, using on-surface synthesis and hydrogen manipulation using a scanning tunnelling microscope, and their collective quantum behaviours have been clearly resolved.

Unlike classic spins, quantum magnets are spin systems that interact via the exchange interaction and exhibit collective quantum behaviours, such as fractional excitations. Molecular magnetism often stems from d/f-transition metals, but their spin-orbit coupling and crystal field induce a significant magnetic anisotropy, breaking the rotation symmetry of quantum spins. Thus, it is of great importance to build quantum nanomagnets in metal-free systems. Here we have synthesized individual quantum nanomagnets based on metal-free multi-porphyrin systems. Covalent chains of two to five porphyrins were first prepared on Au(111) under ultrahigh vacuum, and hydrogen atoms were then removed from selected carbons using the tip of a scanning tunnelling microscope. The conversion of specific porphyrin units to their radical or biradical state enabled the tuning of intra-and inter-porphyrin magnetic coupling. Characterization of the collective magnetic properties of the resulting chains showed that the constructed S = 1/2 antiferromagnets display a gapped excitation, whereas the S = 1 antiferromagnets exhibit distinct end states between even-and odd-numbered spin chains, consistent with Heisenberg model calculations.
Molecular nanomagnets have been proposed as promising candidates for information storage, molecular spintronics and quantum computing. Porphyrins and related macrocycles have excellent stability, high chemical versatility, as well as the ability to stabilize different ions at their centre, which potentially allows for the tuning of their biological, electronic and magnetic properties [1][2][3][4] . Although individual magnetic porphyrins have been widely studied and are well understood, little is known about the coupled spins in multi-porphyrin systems. The magnetism of a porphyrin macrocycle typically comes from its central magnetic metal ion, in which any unpaired d/f electrons highly localize at the centre. This localization means that the spins in assembled porphyrin architectures undergo a negligible magnetic exchange interaction. In the past decade, a series of porphyrin architectures have been achieved on surfaces, including single porphyrin molecules, covalent porphyrin polymers and self-assembled nanostructures 1,3,5-17 . However, none has exhibited detectable collective magnetic behaviours, where the spins are correlated together and undergo collective excitation.
Recently, delocalized π-electron magnetism has been introduced in porphyrins through engineering of their π-electron topologies [18][19][20] . This delocalization effect allows for further realization of quantum nanomagnets with coupled spins in covalent porphyrin architectures. However, due to their high reactivity and/or low solubility, Article https://doi.org/10.1038/s41557-022-01061-5 nanomagnets with tunable magnetic exchange interactions. A series of molecular nanomagnets were constructed and thoroughly characterized by non-contact atomic force microscopy (nc-AFM) and scanning tunnelling microscopy/spectroscopy (STM/STS) together with density functional theory (DFT) calculations and theoretical modelling. Our results show that the two spins inside each porphyrin unit are ferromagnetically coupled with an intra-unit magnetic exchange strength of 20 meV, and the spins between two neighbouring porphyrin units are antiferromagnetically coupled with an inter-unit magnetic exchange strength of ~3 meV. Additionally, different quantum phases have been observed in the constructed molecular nanomagnets, such as gapped excitations in finite S = 1/2 antiferromagnetic nanomagnets, and zero-mode end states in S = 1 antiferromagnetic nanomagnets. The ability to construct coupled spins one by one provides ample opportunities for exploring the new exotic phases of quantum magnetism in organic nanomagnets. Figure 1a presents the three-step scheme-precursor synthesis, on-surface synthesis and atom manipulation-to construct quantum nanomagnets, spin by spin, in porphyrin chains. The precursor 5,15-bis(4-bromo-2,6-dimethylphenyl)porphyrin is synthesized in solution by traditional 'wet' chemistry ( Supplementary Fig. 1). After in-solution synthesis, the precursor is thermally deposited on Au(111) held at 180 °C, followed by a subsequent annealing to 290 °C for 10 min. With thermal activation, carbon-carbon coupling and cyclodehydrogenation reactions take place, giving rise to fully aromatic it has remained challenging to synthesize such porphyrin quantum nanomagnets by traditional 'wet' chemistry. Pioneered by Grill and colleagues in 2007, on-surface synthesis has become a powerful approach for the fabrication of atomically precise covalent nanostructures, with milestones including single molecules, covalent porphyrin polymers, graphene nanoribbons and two-dimensional (2D) covalent molecular frameworks [21][22][23][24][25][26][27][28][29][30][31] . Meanwhile, the atom manipulation approach has been developed by Hla, Gross and colleagues for studying individual chemical reactions in real space by using an atomically sharp metal tip, with outstanding examples being the syntheses of biphenyl molecules, triangulene nanographenes, sp-hybridized carbon chains and rings, to name a few [32][33][34][35][36] . These two approaches are complementary to each other, as on-surface synthesis enables the synthesis of large repeated nanostructures, and atom manipulation is effective for building single, complex custom-designed structures.

Synthesis and structural characterization
In this Article we take advantage of both on-surface synthesis and the atom manipulation approach to construct complex, custom-designed molecular nanomagnets in metal-free porphyrins, spin by spin on a Au(111) surface. On-surface synthesis is used to construct extended porphyrin chains with two sp 3 carbon sites per porphyrin unit, forming an extended 1D sp 3 carbon lattice. Through atom manipulation, one of the two hydrogens in each sp 3 carbon site can be controllably dissociated at predefined locations in the sp 3 carbon lattice. Each hydrogen-dissociation step transforms an sp 3 carbon into an sp 2 carbon, and thus introduces one delocalized π radical into the aromatic system. The delocalized character of π-electron magnetism gives rise to a considerable intra-unit as well as inter-unit magnetic coupling, allowing for the construction of quantum   Supplementary Fig. 5). Bond-resolved nc-AFM imaging was used to characterize the chemical structure of the achieved products by functionalizing a CO molecule at the tip apex 37 . The nc-AFM image in Fig. 1c shows that each porphyrin unit is composed of two sp 3 carbon sites, which appear as shallow protrusions located randomly at two outer corners of the porphyrin macrocycle. We attribute the high yield of sp 3 carbon sites to the diradical character of each porphyrin unit (see the Clar non-Kekulé structures in Supplementary Fig. 3). During the cyclodehydrogenation reaction process, the dissociated hydrogen atoms migrate on the surface and saturate the radical sites, forming two sp 3 carbon sites per porphyrin unit. For comparison, we studied the 5-(2,6-dimethylphenyl)porphyrin precursor, which results in products with a closed-shell electronic structure after cyclodehydrogenation. As expected, none of the products feature any sp 3 carbon sites (details are provided in Supplementary Fig. 4).
Through atom manipulation, we can controllably dissociate one hydrogen from an sp 3 carbon site by injecting inelastic tunnelling electrons (see the I-V curve in Supplementary Fig. 2), which transforms an sp 3 carbon into an sp 2 carbon (radical), thus introducing an unpaired π electron into the aromatic system. Using the above strategy, we constructed two typical examples of porphyrin nanomagnets holding four and eight unpaired spins, as confirmed by high-resolution nc-AFM imaging (Fig. 1d,e); these can be simplified as a finite S = 1/2 and S = 1 antiferromagnetic spin chain, respectively (vide infra). Note that all the porphyrin chains are adsorbed flat on the Au(111) due to their tight physisorption, although a twisted configuration is expected in the gas phase (see the DFT-optimized structure in Supplementary Fig. 15).

Intra-unit magnetic exchange interaction
Intra-unit magnetic coupling between the two spins within a porphyrin monomer was studied by means of STS measurements, together with DFT calculations and theoretical modelling. As shown in Fig. 2, we dissociated one hydrogen away from each of the two sp 3 carbon sites, one by one, and traced their magnetic ground states. We refer to the porphyrin monomer with two, one and zero sp 3 carbon site(s) as 2H-Por, 1H-Por and Por, respectively. Both spectroscopic measurements and DFT calculations confirm that the 2H-Por has a closed-shell electronic structure (Fig. 2a,d). The 2H-Por converts into 1H-Por after the bias voltage is slowly ramped to 3 V by positioning the STM tip above the sp 3 carbon site and retracting 400 pm away from a tunnelling setpoint of V = 10 mV and I = 10 pA. The 1H-Por features an odd number of π electrons, with a magnetic ground state of S = 1/2 as shown by DFT calculations (Fig. 2b). Using the same procedure, the 1H-Por is further manipulated into Por, as shown in Fig. 2c; this has two unpaired π electrons. DFT calculations suggest that the two spins reside at opposite sides along the long axis of the monomer, with a ferromagnetic coupling of 15 meV. The presence of delocalized magnetism in π-conjugated systems is due to the minimization of on-site Coulomb repulsion, which can be qualitatively captured by mean-field DFT calculations, but higher levels of calculations including correlation effects are required to quantitatively address these systems 38 . In the following we have mainly performed DFT calculations in the gas phase to analyse our measurements. Spin-flip spectroscopy measurements confirm the magnetic exchange interaction by showing two symmetric steps above/below the Fermi level at 20 mV (Fig. 2d); this is due to the presence of a spin-flip tunnelling channel induced by inelastic tunnelling electrons 39,40 . Additionally, the presence of net spins in 1H-Por and Por Article https://doi.org/10.1038/s41557-022-01061-5 was further confirmed by the Kondo resonance effect. The Au(111) surface electrons screen the net spin(s) and result in a many-body Kondo resonance, showing a sharp peak at the Fermi level. As shown in Fig. 3d, Kondo resonances have been observed in both 1H-Por and Por. However, the Kondo resonance intensity of spin S = 1/2 in 1H-Por is significantly stronger than that of spin S = 1 in Por. This difference is due to the different screening effects; the quantized spin S = 1/2 is completely screened by Au(111) conduction electrons, whereas the higher spin S = 1 is underscreened (partially screened with a remaining magnetic moment), in agreement with theory predictions and recent experimental observations on magnetic nanographenes 41,42 . This difference in Kondo screening was further confirmed by dI/dV spectra under an out-of-plane magnetic field. As shown in Fig. 2e,f, the Kondo resonance of S = 1/2 is robust against the magnetic field, but the Kondo resonance of S = 1 is extremely sensitive to the applied magnetic field due to its underscreened nature, with Zeemann splitting energy much smaller than the Kondo temperature 43 (the Kondo temperature estimation is shown in Supplementary Fig. 7). We simulated the observed dI/dV spectra by using a perturbative approach as established by Ternes 39 , which nicely reproduced the experimental features ( Supplementary Fig. 17).

Inter-unit magnetic exchange interaction
Inter-unit magnetic coupling was studied by constructing four spins, one by one, in a covalent porphyrin dimer (Fig. 3). A π radical was first created inside the dimer; this localizes at the dehydrogenated side, exhibiting a sharp Kondo resonance in the dI/dV spectrum (Fig. 3d). In the second step, we deliberately created another π radical inside the other unit of the dimer to show the inter-unit magnetic coupling. DFT calculations suggest that the two spins are antiferromagnetically coupled with an inter-unit exchange strength of 2.1 meV if the two spins are resident on the same side along the long axis of the dimer, and 1.8 meV when the two spins are on opposite sides (Supplementary Fig. 9). The dI/dV spectra in Fig. 3d   Article https://doi.org/10.1038/s41557-022-01061-5 Fig. 14). In the following step, a third spin was introduced into the system. After positioning the tip over the right unit, two steps are observed at 3 mV and 20 mV due to the presence of inelastic tunnelling channels originating from the inter-and intra-unit spin-flip process (spectrum 4 in Fig. 3d). Similar observations were made for the tetra-radical dimer, confirming intra-unit ferromagnetic coupling and intra-unit antiferromagnetic coupling (spectra 6 and 7 in Fig. 3d). As illustrated in Fig. 3e, we modelled the magnetic exchange interactions among the four spins in the dimer by considering an intra-unit coupling of −20 meV and inter-unit couplings of 3.2 meV (same side) and 2.4 meV (opposite side). As shown in Fig. 2d, the simulated spectra obtained using the code reported in ref. 39 agree well with the STS measurements, confirming that the created spins are coupled together. Because the intra-unit coupling J 1 is significantly larger than inter-unit couplings J 2 and J 3 , the low-lying spin states of the tetra-spin S = 1/2 system in a porphyrin dimer can also be described by a bilinear-biquadratic S = 1 model. To fit the low-lying spin states, an effective magnetic coupling of J = 2.8 meV and β = 0.001 J was obtained, suggesting that the tetra-spin S = 1/2 system can be simplified as an antiferromagnetic S = 1 system (illustrated in Fig. 3e).

Spin S = 1/2 antiferromagnetic quantum nanomagnets
The spin S = 1/2 antiferromagnets were constructed one by one in a long porphyrin polymer, as shown in Fig. 4. We probed the excitation gap of S = 1/2 antiferromagnets of different lengths by means of inelastic tunnelling spectroscopy. As shown in Fig. 4d, a dip-like feature can be observed in the site-resolved dI/dV spectra; this can be attributed to the presence of the first excitation gap of the spin systems, that is, the energy difference between the ground state and the first excited state as excited by inelastic tunnelling electrons. To better determine the excitation energy positions, we took the numerical derivation of all the dI/dV spectra and found that the spin-flip energy positions remain constant, Article https://doi.org/10.1038/s41557-022-01061-5 although the peak intensity varies significantly when positioning the tip over different positions within a unit (see the site-dependent dI/dV spectra in Supplementary Fig. 6). Apparently, our constructed spin S = 1/2 antiferromagnets cannot be explained by the classic Ising model, where the energy required to flip a spin in the centre is two times larger than that at the two termini of a spin chain. This deviation from the Ising model originates from the extremely weak spin-orbital coupling of the carbons, which results in a negligible magnetic anisotropy energy. In this case, the physics of our constructed molecular nanomagnets is dominated by quantum effects and can be captured by the Heisenberg antiferromagnet S = 1/2 model 44 . Considering the coupling with Au(111) itinerant electrons and the scattering process of the tunnelling electrons, these dip features can be satisfactorily reproduced by such modelling using the code reported in ref. 39 (detailed fitting parameters are presented in Supplementary Fig. 17). Interestingly, we notice that Coulomb scattering between the molecule and substrate is site-dependent, similar to the behaviour observed for porphyrins on Pb(111) 45 . Spin S = 1 antiferromagnets of different length were constructed and studied thoroughly (Fig. 5). The S = 1 antiferromagnetic spin chain is a prototype of fractional and topological phase, as proposed by Haldane in the 1980s (also known as the Haldane spin chain). According to the Haldane conjecture, such a spin chain is a topological insulator due to quantum fluctuations (the random change of system's energy due to the uncertainty principle), with all spins cancelled in the bulk and spin-1/2 edge states at the ends 46 . Finite-size S = 1 antiferromagnets of up to five units were constructed to obtain size-dependent magnetic excitations. Figure 5d,e shows site-resolved dI/dV spectra taken for the finite S = 1 chains; these show spectral features that are distinct for the even-and odd-numbered chains. With even-numbered chains, step-like features are observed at all units, with the first excitation gap decreasing from 2.4 meV to 1.1 meV as the length increases from two to four units. With odd-numbered chains, a zero-bias peak is observed at the terminal units, and a dip-like feature in the bulk units. The magnetic-field-dependent dI/dV measurements show that the zero-bias peak is robust against a magnetic field of up to 3 T, and the temperature dependent dI/dV measurements show that the peak width broadens with increasing temperature. In the single-impurity Anderson model, the Kondo peak width reflects the magnetic exchange strength between spin impurities and itinerant electrons as obtained by Fermi liquid theory, which agrees well with our observations, giving a Kondo temperature of 21 K (Supplementary Fig. 7). Because this behaviour clearly deviates from that of an underscreened high spin S = 1 in odd-numbered chains, we attribute the presence of the zero-bias peak at the terminal units to Kondo screening of the end S = 1/2 spins. The detection of end S = 1/2 spins in S = 1 spin chains indicates that quantum fluctuations transform the antiferromagnetic S = 1 spin chain into a topological phase with spin cancelled in the bulk and the emergence of end states, as proposed by Haldane (Fig. 5j). A Heisenberg antiferromagnetic S = 1 model was used to elucidate our observations. In a Haldane chain, the considered length is long enough that the ground state is a four-fold degenerate edge state that contains one singlet level and three triplet levels. For short chains, S = 1 Heisenberg model calculations show that (1) the ground state of odd-numbered chains is the three-fold degenerate triplet edge state, and the first excited state is the singlet state; (2) the ground state of even-numbered chain is the singlet edge state, and the first excited state is the three-fold degenerate triplet edge state (Fig. 5f,g and Supplementary Fig. 16); (3) the energy difference between the triplet and singlet state decreases exponentially with increasing length and approaches to zero for infinitely long chains (Fig. 5h). We attribute the observed distinct zero-energy features of even-and odd-numbered spin chains to their different ground states, according to Heisenberg model calculations. As shown in Fig. 5i, we calculated the local average magnetization 〈S z 〉 on each unit by using the singlet and triplet ground states with | , S z 〉 = |1, +1〉 and | , S z 〉 = |0, +1〉, respectively. For even-numbered chains, the average magnetization 〈S z 〉 on all the units is always zero, which explains the absence of a zero-bias peak due to the singlet ground state. For odd-numbered chains, the average magnetization 〈S z 〉 on each unit is non-zero, with dominant weight on the two end units due to the triplet ground state, which causes the zero-bias Kondo resonances. Once the chains are long enough that the singlet and triplet states are nearly degenerate, the zero-bias peak can be observed in both odd-and even-numbered chains (Fig. 5i).

Conclusion
In summary, we have demonstrated an effective approach to building molecular quantum nanomagnets in metal-free porphyrins on Au(111), with the ultimate ability to arrange coupled spins, one by one, at predefined locations. The quantum magnetism behaviours of the constructed nanomagnets have been demonstrated by scanning probe techniques, together with theory calculations. Owing to the delocalized character of π radicals, significant intra-and inter-unit magnetic exchange interactions have been observed, with values up to −20 meV and 3 meV, respectively. Using our established strategy, we have constructed a series of S = 1/2 and S = 1 antiferromagnetic nanomagnets one by one, and traced their magnetic properties. A finite excitation gap was observed for S = 1/2 nanomagnets, consistent with the S = 1/2 Heisenberg antiferromagnetic model. Interestingly, we observed an end state for S = 1 nanomagnets with odd-numbered units, which is attributed to the presence of the triplet ground state. Our work provides a widely engineerable platform to further explore the exotic phases of quantum magnetism in real space, such as magnetic plateaux, spin liquid states or spin-Peierls states.

Online content
Any methods, additional references, Nature Research reporting summaries, source data, extended data, supplementary information, acknowledgements, peer review information; details of author contributions and competing interests; and statements of data and code availability are available at https://doi.org/10.1038/s41557-022-01061-5.

On-surface synthesis and characterization
Under ultrahigh-vacuum (3 × 10 −10 mbar) conditions, a commercially available low-temperature Joule-Thomson scanning probe microscope was used for sample preparation and characterization. The Au(111) single crystal was cleaned cyclically by argon ion sputtering, then annealed to 800 K to obtain atomically flat terraces. The molecular precursors of 5,15-bis(4-bromo-2,6-dimethylphenyl)porphyrin and 5-(2,6-dimethylphenyl)porphyrin were thermally deposited on the clean Au(111) surface at 180 °C, then annealed to 290 °C for 10 min. The sample was subsequently transferred to a cryogenic scanner at 1.36 K for characterization. Carbon monoxide molecules were dosed onto the cold sample at ~12 K (1.5 × 10 −8 mbar, 1 min). To improve the resolution of STM/AFM imaging, the CO molecule was picked up from the Au surface onto the apex of the tungsten tip. In nc-AFM imaging, a quartz tuning fork with a resonance frequency of 28 kHz was used. A lock-in amplifier (521 Hz, 1 mV modulation) was used to obtain dI/dV spectra. The spectra were taken at 1.36 K unless otherwise stated. The STM and nc-AFM images were processed with WSxM software.

Synthetic procedure for 5,15-bis(4-bromo-2,6-dimethylphenyl)porphyrin in solution
A solution of dipyrromethane (1.75 g, 12 mmol) and 2,6-dimethyl-4-b romobenzaldehyde (12 mmol) in CHCl 3 (1.2 l) was treated with BF 3 ·OEt 2 (1 ml) at room temperature. The flask was shielded from light with aluminium foil, and the solution was stirred under argon for 8 h. Subsequently, 2,3-dicyano-5,6-dichlorobenzoquinone (4.09 g, 18 mmol) was added and the mixture was stirred at room temperature for 0.5 h. The mixture was neutralized with triethylamine (15 ml). The volume of the solvent was reduced to ~300 ml under reduced pressure, then the mixture was filtered through a pad of basic alumina (Merck, aluminium oxide 90 active basic). The filtrate was concentrated and the residue chromatographed on silica gel. The eluate was then evaporated and the resulting solid purified by recrystallization from CH 2 Cl 2 /hexane to afford the product (25%) 47 .

DFT calculations in the gas phase
Spin-polarized DFT calculations were performed using the Gaussian 16 package. The PBE0-D3 (BJ) functional was applied to show the electronic structure of all gas-phase molecular nanomagnets 48 , and using the def2-SVP basis set for geometry optimization, which was extended to a def2-TZVP basis set for the single-point energy calculation 49 . The electronic structures of molecules were calculated using the restricted and unrestricted methods for different spin multiplicities. Molecular orbitals and electron spin density distributions were analysed by Multiwfn 50 . Images of the structures and isosurfaces were plotted using VESTA 51 .

DFT calculations with the Au substrate
Periodic DFT calculations are performed with the VASP package 52-54 , relying on the spin-polarized, van der Waals inclusive functional devised by Dion and others 55 . Electron-core interactions are accounted for through the projector augmented wave method 56 . We used a cutoff kinetic energy of 400 eV and a single k point. The models consist of porphyrin dimers supported on a hexagonal supercell of Au(111) of size 45.99 Å × 20.12 Å and contain 526 atoms, with the Au(111) substrate described by four slabs of Au atoms. All atomic coordinates are optimized with a tolerance on forces of 25 meV Å −1 , except the three slabs of Au farthest from the porphyrins, which are constrained to their equilibrium position in the bulk Au(111).

Theoretical modelling
To understand the scattering and screening effects in the STM junction, we fitted our dI/dV spectra using the perturbation approach up to third order, as developed by Ternes 57 . We calculated the spin states of finite S = 1 spin chains using a bilinear-biquadratic model. The Hamiltonian iŝ where J is the magnetic coupling strength between two spins ⃗ S i and ⃗ S j , and β is the strength of the biquadratic term relative to the bilinear term.

Data availability
Data supporting the findings of this study are available within the paper and its Supplementary Information. The Supplementary Information includes details of experiments, synthetic procedures and characterization data of the molecular precursor, as well as details of calculations. Source data are provided with this paper.

Code availability
The Heisenberg Hamiltonians were solved using Python. Details of this code are available from the corresponding author on request.