Abstract
Living substrates are capable for nontrivial mappings of electrical signals due to the substrate nonlinear electrical characteristics. This property can be used to realise Boolean functions. Input logical values are represented by amplitude or frequency of electrical stimuli. Output logical values are decoded from electrical responses of living substrates. We demonstrate how logical circuits can be implemented in mycelium bound composites. The mycelium bound composites (fungal materials) are getting growing recognition as building, packaging, decoration and clothing materials. Presently the fungal materials are passive. To make the fungal materials adaptive, i.e. sensing and computing, we should embed logical circuits into them. We demonstrate experimental laboratory prototypes of manyinput Boolean functions implemented in fungal materials from oyster fungi P. ostreatus. We characterise complexity of the functions discovered via complexity of the spacetime configurations of onedimensional cellular automata governed by the functions. We show that the mycelium bound composites can implement representative functions from all classes of cellular automata complexity including the computationally universal. The results presented will make an impact in the field of unconventional computing, experimental demonstration of purposeful computing with fungi, and in the field of intelligent materials, as the prototypes of computing mycelium bound composites.
Similar content being viewed by others
Introduction
The fungi are one of the largest, the oldest, most adaptive and widely distributed group of organisms^{1}. Smallest fungi are single cells. The largest mycelium spreads in hectares^{2}. When growing in a bulk medium of wood or plant shavings fungi bind the medium in a solid monolith with outstanding mechanical properties. The mycelium bound composites are seen as future environmentally sustainable growing biomaterials^{3,4,5,6}. They are already used in acoustic^{7,8,9} and thermal^{10,11,12,13,14,15} insulation panels and cladding, materials for packaging^{16,17,18} and wearables^{3,19,20,21,22}. The currently used fungal materials are passive and inert because the fungi in the composites are dead and treated to prevent decay. To make the fungal materials adaptive and intelligent we must either (1) leave part of the fungal materials alive, or (2) dope the materials with functional nanoparticles and polymers. In the present paper we explore the first option of sensing and computing with living mycelium.
Why do we need to compute with fungi? The research is undertaken in the frame for the FUNGAR (www.fungar.eu), acronym for Fungal Architectures, a EU Horizon 2020 research project that seeks to develop a fully integrated structural and computational living monolith by using fungal mycelium. The goal, to advance towards the realisation of fullscale intelligent biobuildings and other functional biostructures. Distributions of Boolean gates depends on environmental and physiological conditions of the mycelium bound composites and therefore will provide a computational characterisation of the fungal material states. This distribution of logical functions will be somewhat analogous to Kolmogorov complexity of the living building materials.
Fungal colonies are characterised by rich typology of mycelium networks^{23,24,25,26,27} in some cases similar to fractal structures^{28,29,30,31,32,33}. Rich morphological features might imply rich computational abilities and thus worth to analyse from a realising Boolean functions point of view. To implement logical functions we adopted a theoretical approach developed in^{34,35}. The technique is based on selecting a pair of input sites, applying all possible combinations of inputs, where logical values are represented by electrical characteristics of input signals, to the sites and recording outputs, represented by electrical responses of the substrate, on a set of the selected output sites. The approach belong to the family of reservoir computing^{36,37,38,39,40} and in materio computing^{41,42,43,44,45} techniques of analysing computational properties of physical and biological substrates.
The paper is structured as follows. First, the experimental setup will be described, then the procedure for data gathering and analysis will be outlined.
Methods
A hemp shavings substrate was colonised by the mycelium of the grey oyster fungi, P. ostreatus (Ann Miller’s Speciality Mushrooms Ltd, UK). Recordings were carried out in a stable indoor environment with the temperature remaining stable at \(22 \pm 0.5\)°and relative humidity of air \(40 \pm 5\)%. The humidity of the substrate colonised by fungi was kept at c. 7080%.
Hardware was developed that was capable of sending sequences of 4 bit strings to a mycelium substrate. The strings were encoded as step voltage inputs where 5 V denoted a logical 0 and 5 V a logical 1. The hardware was based around an Arduino Mega 2560 (Elegoo, China) and a series of programmable signal generators, AD9833 (Analog, USA). The 4 input electrodes were 1 mm diameter platinum rods inserted to a depth of 50 mm in the substrate in a straight line with a separation of 20 mm. Data acquisition (DAQ) probes were placed in a parallel line 50 mm away separated by 10 mm. The electron sink and source was placed 50 mm on from DAQ probes. There were 7 DAQ differential inputs from the mycelium substrate to a Pico 24 (Pico Technology, UK) analoguetodigital converter (ADC), the 8th channel was used to pass a pulse to the ADC on every input state change, see Fig. 1 for a schematic of the apparatus. The substrate and probes were placed in a semisealed container. After each experimental repeat the substrate was sprayed with water, left for an hour and then the next repeat was conducted. There were a total of 14 repeats.
A sequence of 4 bit strings counting up from binary 0000 to 1111, with a state change every hour, were passed into the substrate, see Fig. 2 for timing details. In all 14 repeats of the experiment were done on the same substrate to capture changes in structure of the growing mycelium. Samples from 7 channels were taken at 1 Hz over the whole duration of a given experimental run. Peaks for each channel were located for a set of 32 thresholds, from 20 to 175 mV with step 5 mV, for each input state, 0000 to 1111.
The voltage spiking events occur at the scale of seconds usually during state transitions which happen every hour which is in line with the decay time after a spike. Boolean strings were extracted from the data, where a logic “1” was noted for a channel if it had a peak outside the threshold band for a particular state else, a value of “0” was recorded, the polarity of the peak was not considered.
The strings for each experimental repeat were stored in their respective Boolean table. To extract state graphs, a state/node was defined as the string of output values from each channel at each input state, transitions/edges were defined as a change in input state. This led to a total of 448 state graphs. The sum of products (SOP) Boolean functions were calculated for each output channel. For each repeat there were 7 channels and 32 thresholds giving total of 3136 individual truth tables.
See Fig. 3 for SOP extraction. If a peak is found in Fig. 3a during an input state then this is considered a logical 1, highlighted in yellow in table Fig. 3b are the thresholded values for channel 5, the resulting truth table is then reduced to a sum products shown below the table.
Results
We have discovered total of 3136 4inputs1output Boolean functions. 470 unique functions are presented in Supplementary Materials. Figure 4 shows the Boolean function distribution. The two peak values were logical False, \(n=238\), and logical True, \(n=237\). The highest occurring nontrivial gate was \({\overline{A}}+{\overline{B}}+{\overline{C}}+{\overline{D}}\), \(n=145\). The top 16 occurring nontrivial Boolean functions are listed in Table 1. The only single gate functions found were for nand (\({\overline{A}}+{\overline{B}}+{\overline{C}}+{\overline{D}}\)), \(n=145\), or (\(A+B+C+D\)), \(n=46\), and and (ABCD), \(n=8\).
Let us discuss complexity of the functions discovered (Table 1) via complexity of the spacetime configurations of onedimensional cellular automata governed by the functions. We consider an array Z of finite state machines, called cells, where every cell takes states ‘0’ or ‘1’ and updates its state depending on the states of its four immediate neighbours. All cells update their states by the same rule and in discrete time. For example, a cell with index i, \(x_i \in Z\), updates its state at time t as a function of states of its four neighbours: \(x^{t+1}=f(x_{i2}^t, x_{i1}^t, x_{i+1}^t, x_{i+2}^t)\). To map functions from Table 1 to the rules governing the cellular automata we assume that A corresponds to \(x_{i2}^t\), B to \(x_{i1}^t\), C to \(x_{i+1}^t\) and D to \(x_{i+1}^t\). For example, a cell \(x_i\) of cellular automaton governed by the function \(F_5\) (Table 1) updates its state as \(x^{t+1}= \overline{x_{i2}}x_{i1}+x_{i+1}\overline{x_{i+2}}+\overline{x_{i2}}x_{i+2}\).
Automaton governed by \(F_1\), \(F_6\), \(F_8\) fall into absorbing state where all cells are in state ‘0’. The automaton governed by rule \(F_9\) falls into the state where all cells are in state ‘1’. Spacetime configurations, random initial conditions and absorbing boundaries, of automata governed by other rules are shown in Fig. 5. We characterise a complexity of the spacetime patterns via LempelZiv complexity (compressibility) LZ. The LZ complexity is evaluated by a size of concentration profiles saved as PNG files of the configurations. This is sufficient because the ’deflation’ algorithm used in PNG lossless compression^{46,47,48} is a variation of the classical Lempel–Ziv 1977 algorithm^{49}. The frequency of the functions occurrence in the experimental circuit mining versus LZ complexity of the functions is shown in Fig. 6. We can see that there is no correlation between how often a function can be found and how complexity the function is. Thus, e.g. the function \(F_{13}\) (Table 1) generates most complex spacetime configuration (Fig. 5i) yet it is in the midrange of the frequency of experimental occurrence. The less complex functions \(F_5\), \(F_7\), \(F_{12}\), \(F_{15}\) span the interval [29,55] counts of occurrences in experimental laboratory mining.
Let us consider positions of the functions Table 1 in the Wolfram classification^{50} of cellular automaton behaviour. Functions \(F_1\), \(F_6\), \(F_8\), \(F_9\) and \(F_11\) belong to the class I, the class of automata exhibiting a dull dynamics and evolving to a stable state where all cells are in the same state. Functions \(F_2\), \(F_7\), \(F_{12}\), \(F_{14}\), \(F_{15}\) belong to the class II: the automata fall into global cells do not update their state or update them cyclically from ‘0’ to ‘1’. Functions \(F_4\), \(F_{10}\) and \(F_{13}\) belong to class III: the spacetime dynamics is characterised by quasirandom behaviour and difficult predictability of the successions of the global states. These functions generate the most complex, as evaluated by LZ measure, spacetime configurations. Function \(F_2\) shows an interesting example of the function belonging to classes II and III. Two functions \(F_3\) and \(F_{16}\) belong to class IV: the spacetime dynamics of automata show gliders (compact patterns translating in space) with nontrivial interactions between the gliders. The automata governed by rules \(F_3\) and \(F_{16}\) are computationally universal, because it is possible to implement an arbitrary logical circuit via collisions between the gliders, see e.g.^{51,52}.
Discussion
Mycelium bound composites transform electrical signals in a nonlinear manner due to memfractive and capacitive properties of the fungal tissue^{53}. Whilst exact biophysical mechanisms of the signal transformation by the mycelium remain unknown we can explore the nonlinear properties of this living substrate to implement logical circuits. In experimental laboratory studies we demonstrated that mycelium bound composites implement a wide range of Boolean circuits. Analyses of the functions extracted in terms of spacetime dynamics of cellular automata helped us to order the functions in several classes of complexity and pinpoint the functions supporting a universal computation. It would be possible to concatenate outputs from the different channels to create another layer of logic gate outputs. The current study looked at single output systems via SOP but the potential of using multiple outputs in parallel is there.
The first ever prototype of the fungal reservoir computer, presented in the paper, demonstrates that a computation can be embedded into living materials. The research presented also pinpointed a high degree of variability in the logical circuits implemented by the fungi. This is because the live mycelium remain in the continuous process of growth and reconfiguration. To decrease the variability of the results we could consider to functionalise the mycelium networks with semiconductive particles and polymers and allow the mycelium to dry. The resulting networks will have a permanent structure which will guarantee repeatability of the experimental circuits discovered. This will be a topic of our future studies.
References
Michael, J. C., Watkinson, S. C., & Gooday, G. W. The Fungi, (Gulf Professional Publishing, 2001).
Myron Smith, L., Johann Bruhn, N. & James Anderson, B. The fungus Armillaria bulbosa is among the largest and oldest living organisms. Nature 356(6368), 428 (1992).
Karana, E., Blauwhoff, D., Hultink, E.J., Camere, S. When the material grows: A case study on designing (with) myceliumbased materials. Int. J. Des. 12, 119–136 (2018).
Jones, M., Mautner, A., Luenco, S., Bismarck, A. & John, S. Engineered mycelium composite construction materials from fungal biorefineries: A critical review. Mater. Des. 187, 108397 (2020).
Cerimi, K., Akkaya, K. C., Pohl, C., Schmidt, B. & Neubauer, P. Fungi as source for new biobased materials a patent review. Fungal Biol. Biotechnol. 6(1), 1–10 (2019).
Adamatzky, A., Gandia, A., Ayres, P., Wösten, H., & Tegelaar, M. Adaptive fungal architectures. LINKsseries, 5:66–77.
Pelletier, M. G., Holt, G. A., Wanjura, J. D., Bayer, E. & McIntyre, G. An evaluation study of mycelium based acoustic absorbers grown on agricultural byproduct substrates. Industrial Crops Prod. 51, 480–485 (2013).
Elsacker, E. et al. A comprehensive framework for the production of myceliumbased lignocellulosic composites. Sci. Total Environ. 725, 138431 (2020).
Robertson, O. et al. Fungal future: A review of mycelium biocomposites as an ecological alternative insulation material. DS 101: Proceedings of NordDesign 2020, Lyngby, Denmark, 12th14th August 2020, pages 1–13, (2020).
Yang, Z., Zhang, F., Still, B., White, M. & Amstislavski, P. Physical and mechanical properties of fungal myceliumbased biofoam. J. Mater. Civ. Eng. 29(7), 04017030 (2017).
Xing, Y., Brewer, M., ElGharabawy, M., Griffith, G. & Jones, P. Growing and testing mycelium bricks as building insulation materials. IOP Conf. Series Earth Environ. Sci. 121, 022032 (2018).
Girometta, C. et al. Physicomechanical and thermodynamic properties of myceliumbased biocomposites: A review. Sustainability 11(1), 281 (2019).
Dias, P. P., Jayasinghe, L. B. & Waldmann, D. Investigation of myceliummiscanthus composites as building insulation material. Results Mater. 10, 100189 (2021).
Fei WANG, Hongqiang LI, Shushuo KANG, Yefei BAI, Guozhen CHENG, and Guoqiang ZHANG. The experimental study of mycelium/expanded perlite thermal insulation composite material for buildings. Science Technology and Engineering, 2016:20, (2016).
CárdenasR, J. P. Thermal insulation biomaterial based on hydrangea macrophylla. In BioBased Materials and Biotechnologies for EcoEfficient Construction, pp 187–201. Elsevier, (2020).
Holt, G. A. et al. Fungal mycelium and cotton plant materials in the manufacture of biodegradable molded packaging material Evaluation study of select blends of cotton byproducts. J. Biobased Mater. Bioenergy 6(4), 431–439 (2012).
Sivaprasad, S., Sidharth Byju, K., Prajith, C., Jithin Shaju, Rejeesh, C.R. Development of a novel mycelium biocomposite material to substitute for polystyrene in packaging applications. Materials Today: Proceedings, (2021).
Mojumdar, A., Behera, H. T., Ray, L. Mushroom myceliabased material: An environmental friendly alternative to synthetic packaging. Microbial Poly. pp https://doi.org/10.1007/9789811600456_6 (2021).
Adamatzky, A., Nikolaidou, A., Gandia, A., Chiolerio, A. & Dehshibi, M. M. Reactive fungal wearable. Biosystems 199, 104304 (2021).
Silverman, J., Cao, H. & Cobb, K. Development of mushroom mycelium composites for footwear products. Cloth. Text. Res. J. 38(2), 119–133 (2020).
Appels, F. V. W. The use of fungal mycelium for the production of biobased materials. PhD thesis, Universiteit Utrecht (2020).
Jones, Mitchell, Gandia, Antoni, John, Sabu & Bismarck, Alexander. Leatherlike material biofabrication using fungi. Nat. Sustain. 4, 1–8 (2020).
Hitchcock, D., Glasbey, C. A. & Ritz, K. Image analysis of spacefilling by networks: Application to a fungal mycelium. Biotechnol. Tech. 10(3), 205–210 (1996).
Giovannetti, M., Sbrana, C., Avio, L. & Strani, P. Patterns of belowground plant interconnections established by means of arbuscular mycorrhizal networks. New Phytol. 164(1), 175–181 (2004).
Fricker, M., Boddy, L., & Bebber, D. Network organisation of mycelial fungi. In Biology of the Fungal Cell. The Mycota (eds Howard, R.J. & Gow, N.A.R.) , vol 8. https://doi.org/10.1007/9783540706182_13 (Springer, Berlin, Heidelberg, 2007).
Fricker, M. D., Heaton, L. L. M., Jones, N. S., & Boddy, L. The mycelium as a network. The Fungal Kingdom, pp 335–367, (2017).
Islam, M. R., Tudryn, G., Bucinell, R., Schadler, L. & Picu, R. C. Morphology and mechanics of fungal mycelium. Sci. Rep. 7(1), 1–12 (2017).
Obert, M., Pfeifer, P. & Sernetz, M. Microbial growth patterns described by fractal geometry. J. Bacteriol. 172(3), 1180–1185 (1990).
Dhananjay Patankar, B., TuanChi, L. & Oolman, T. A fractal model for the characterization of mycelial morphology. Biotechnol. Bioeng. 42(5), 571–578 (1993).
Boddy, L. & Bolton, R. G. Characterization of the spatial aspects of foraging mycelial cord systems using fractal geometry. Mycol. Res. 97(6), 762–768 (1993).
Mihail, J. D., Obert, M., Bruhn, J. N. & Taylor, S. J. Fractal geometry of diffuse mycelia and rhizomorphs of armillaria species. Mycol. Res. 99(1), 81–88 (1995).
Boddy, L., John Wells, M., Culshaw, C. & Donnelly, D. P. Fractal analysis in studies of mycelium in soil. Geoderma 88(3), 301–328 (1999).
Papagianni, M. Quantification of the fractal nature of mycelial aggregation in aspergillus niger submerged cultures. Microb. Cell Fact. 5(1), 5 (2006).
Adamatzky, A. Tegelaar, M., Wosten, H. A. B., Powell, A.L., Beasley, A. E. & Mayne, R. On boolean gates in fungal colony. Biosystems 193, 104138 (2020).
Siccardi, S. & Adamatzky, A. Actin quantum automata: Communication and computation in molecular networks. Nano Commun. Netw. 6(1), 15–27 (2015).
Verstraeten, D., Schrauwen, B., d’Haene, M. & Stroobandt, D. An experimental unification of reservoir computing methods. Neural Netw. 20(3), 391–403 (2007).
Lukoševičius, M. & Jaeger, H. Reservoir computing approaches to recurrent neural network training. Computer Sci. Rev. 3(3), 127–149 (2009).
Dale, M., Miller, J. F., & Stepney, S. Reservoir computing as a model for inmaterio computing. In Advances in Unconventional Computing, pp 533–571. Springer, (2017).
Konkoli, Z., Nichele, S., Dale, M. & Stepney, S. Reservoir Computing with Computational Matter. In: Computational Matter. Natural Computing Series. (eds Stepney, S., Rasmussen, S. & Amos, M.) https://doi.org/10.1007/9783319658261_14 (Springer, Cham, 2018).
Dale, M., Miller, J. F., Stepney, S., & Trefzer, M. A. A substrateindependent framework to characterize reservoir computers. Proceedings of the Royal Society A, 475(2226):20180723, (2019).
Miller, J. F., & Downing, K. Evolution in materio: Looking beyond the silicon box. In Proceedings 2002 NASA/DoD Conference on Evolvable Hardware, pages 167–176. IEEE, (2002).
Miller, J. F., Harding, S. L. & Gunnar Tufte, G. Evolutioninmaterio: Evolving computation in materials. Evolut. Intell. 7(1), 49–67 (2014).
Stepney, S. Codesigning the computational model and the computing substrate. In International Conference on Unconventional Computation and Natural Computation, pp 5–14. Springer, (2019).
Julian Miller, F., Simon Hickinbotham, J., Amos, M. In materio computation using carbon nanotubes. In Computational Matter, pp 33–43. Springer, (2018).
Julian Francis Miller. The alchemy of computation: designing with the unknown. Nat. Comput. 18(3), 515–526 (2019).
Roelofs, G. & Koman, R. PNG: The definitive guide. O’Reilly & Associates, Inc., (1999).
Howard, P. G. The design and analysis of efficient lossless data compression systems. PhD thesis, Citeseer, (1993).
Deutsch, P. & Gailly, J. L. Zlib compressed data format specification version 3.3. Technical report, (1996).
Ziv, J. & Lempel, A. A universal algorithm for sequential data compression. IEEE Trans. Inf. Theory 23(3), 337–343 (1977).
Wolfram, S. Statistical mechanics of cellular automata. Rev. Mod. Phys. 55(3), 601 (1983).
Martínez, G. J., Adamatzky, A. & McIntosh, H. V. Phenomenology of glider collisions in cellular automaton rule 54 and associated logical gates. Chaos Solitons Fract. 28(1), 100–111 (2006).
Martínez, G. J., Adamatzky, A., Stephens, C. R. & Hoeflich, A. F. Cellular automaton supercolliders. Int. J. Modern Phys. C 22(04), 419–439 (2011).
Beasley, A. E., Abdelouahab, M.S., Lozi, R., Powell, A. L. & Adamatzky, A. Memfractive properties of mushrooms. arXiv preprint arXiv:2002.06413, (2020).
Acknowledgements
This project has received funding from the European Union’s Horizon 2020 research and innovation programme FET OPEN “Challenging current thinking” under grant agreement No 858132. We are thankful to reviewers for their constructive comments which helped to improve the paper.
Author information
Authors and Affiliations
Contributions
N.R. and A.A. wrote the main manuscript and both prepared the figures and tables. N.R. was responsible for the experimental proceedures and Boolean gate extraction. A.A. was repsonsible for the cellular automata analysis.
Corresponding author
Ethics declarations
Competing interests
The authors declare no competing interests.
Additional information
Publisher's note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Supplementary Information
Rights and permissions
Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http://creativecommons.org/licenses/by/4.0/.
About this article
Cite this article
Roberts, N., Adamatzky, A. Mining logical circuits in fungi. Sci Rep 12, 15930 (2022). https://doi.org/10.1038/s41598022200803
Received:
Accepted:
Published:
DOI: https://doi.org/10.1038/s41598022200803
This article is cited by

Electrical response of fungi to changing moisture content
Fungal Biology and Biotechnology (2023)
Comments
By submitting a comment you agree to abide by our Terms and Community Guidelines. If you find something abusive or that does not comply with our terms or guidelines please flag it as inappropriate.