Light-programmable mechanical computing via polyaniline composite film

Domain: biology
Published: 2026-03-16
Editorial outcome: major_revision

Abstract
Mechanical computing represents a highly promising paradigm for environment-adaptive information processing. However, existing implementations are generally constrained by limited architectural scalability, and their modes of application in practical scenarios remain insufficiently defined. Here, we develop a light-programmable mechanical computing system that not only performs scalable logic operations but also enables environment-adaptive optical camouflage. The system is based on a polyaniline composite film (PCF) that integrates light-responsive expansion–contraction elements with a flexible conductive layer. Light illumination dynamically modulates the conductive pathways, giving rise to optically controlled single-pole single-throw (SPST) and single-pole double-throw (SPDT) relays that reconfigure signal transmission routes. Interconnecting these relays enables the construction of basic logic gates and 2-bit full-adder circuits, establishing a scalable paradigm for light-programmable mechanical computation. Moreover, we implement an adaptive camouflage function that senses environmental textures and generates matching optical patterns, demonstrating potential for intelligent skin applications capable of environmental interaction. This work establishes a light-programmable, pathway-reconfigurable mechanical computing framework, expanding possibilities for autonomous and adaptive intelligent systems.

Introduction
Mechanical computing has recently gained increasing attention for its potential to operate intelligently in dynamically changing environments1-7. In contrast to conventional electronics-based architectures, mechanical computing systems offer a decentralized, electronics-free approach to information processing8-10, which is inherently immune to electromagnetic interference and can function reliably under extreme conditions such as high temperature, radiation, and corrosion11-13. This emerging concept of mechanical intelligence represents a non-von Neumann computing paradigm in which sensing, actuation, and computation are co-localized within the material itself, 14-17, enabling low-latency and low-power responses to external stimuli 18-26.

Recent advances in mechanical computing have largely focused on controlling material deformation to encode and process information13, 20, 27-57. Mechanical deformation can be directly induced by applied forces, driving mechano-electro-coupling materials to produce electrical or optical outputs for computation13, 27, 39-45. Besides, thermal stimuli have been utilized to trigger deformation-based logic operations in thermally driven mechanical computing systems46-48. Moreover, integrating deformation mechanisms responsive to electrical or magnetic fields with circuit design has expanded the possibilities for multifunctional and reconfigurable mechanical computation28, 49-54. Collectively, these advances highlight that controlling deformation through multiple physical fields is central to advancing mechanically based computation.

Despite this progress, two key challenges persist. First, most existing mechanical computing systems remain limited in computational scalability, as their architectures are typically confined to single-device or few-device demonstrations without an effective scheme for interconnection or expansion of computing capability. Second, the practical application modes of these systems remain insufficiently explored, and how they can leverage environmental stimuli to perform context-specific information processing and achieve functions of practical value has yet to be clearly established. Addressing these limitations requires an alternative class of mechanical computing systems that can be programmed by external stimuli to reconfigure their information processing functions and autonomously perform different tasks in response to dynamic environmental inputs. In this work, we develop a light-programmable mechanical computing system that simultaneously achieves scalable logic operations and environment-adaptive optical camouflage. The system is built upon a polyaniline composite film (PCF) that integrates multiple responsive components into a single deformable platform. Upon illumination, the PCF undergoes optically induced mechanical deformation, dynamically modulating conductive pathways to realize optically controlled single-pole single-throw (SPST) and single-pole double-throw (SPDT) relays capable of reconfiguring signal transmission routes. Building upon this mechanism, we realized not only universal logic gate operations but also more complex combinational logic functions, including 1-bit and 2-bit full adders, thereby demonstrating the scalability of the mechanical computing architecture. Furthermore, we developed an adaptive camouflage module capable of sensing environmental texture features and generating corresponding optical patterns, thereby demonstrating the potential of intelligent skins based on this module for interactive environmental adaptation. This work establishes a light-programmable, pathway-reconfigurable computing framework, addressing key limitations of mechanical computing in both computational scalability and offering a feasible pathway toward practical implementation in real-world scenarios.

Results
The construction of polyaniline composite film for implementing light-programmable mechanical computing

Fig. 1 illustrates the structure of the polyaniline composite film (PCF) and the overall strategy for realizing light-programmable mechanical computing. As shown in Fig. 1a, we fabricated a hierarchically coupled composite composed of three functional layers: a polyaniline–poly(N-isopropylacrylamide) (PANi–PNIPAm) layer, a silver nanowires (Ag NWs) conductive layer, and a polydimethylsiloxane (PDMS) layer (molecular structures in Supplementary Fig. 1, material properties detailed in Supplementary Table 1, synthesis procedures in Methods). By integrating these well-established materials58, 59 into a multilayer composite structure, we created an ideal platform that converts optical stimuli into mechanically reconfigurable conductive pathways.

The light-programmable behavior of the designed PCF originates from a hierarchically coupled photo-thermal-mechanical mechanism. Under optical excitation, the PANi component converts incident light into heat via photothermal effects58, while the PNIPAm component undergoes thermally induced shrinkage once the temperature exceeds its lower critical solution temperature (LCST)60. The generated heat is conducted by the Ag NWs layer to the underlying PDMS layer, which exhibits positive thermal expansion (SEM characterization shown in Supplementary Fig. 2)61, 62. The simultaneous contraction of the PANi–PNIPAm layer and expansion of the PDMS layer drive an out-of-plane bending deformation of the film, as shown in Fig. 1b(i) and Supplementary Movie 1. Although the Ag NWs layer does not exhibit thermal expansion, its intrinsic flexibility allows it to maintain favorable electrical conductivity throughout the deformation process63. As a result, the synthesized PCF can dynamically reconstruct its conductive pathways by modulating its mechanical configuration under light illumination.

Detailed experimental results of this light-thermal-mechanical-electrical transduction characteristics are provided in Supplementary Figs. 3-4. We further demonstrated that the light-induced deformation of the PCF is fully reversible by adjusting the ambient humidity (Supplementary Movie 2, and the mechanism was described in Supplementary Note 1). As shown in Fig. 1b(ii), the film bends upon illumination and recovers its initial state when the humidity is increased. This reversible actuation endows the PCF with dynamically reconfigurable conductive pathways and confirms that the material can repeatedly transition between distinct mechanical states without fatigue.

Building on this light-responsive modulation of conductive pathways, we constructed light-programmable mechanical computing circuits. Following Shannon’s relay-circuit framework64, we designed two types of PCF-based relays to realize mechanical computation, as illustrated in Fig. 1c. The single-pole single-throw (SPST) relay functions as a binary switch that connects or disconnects a transmission path, serving as the fundamental unit for controlling signal on/off states. The single-pole double-throw (SPDT) relay directs the input voltage (Vcc) between two alternative output channels, enabling signal routing. By integrating SPST and SPDT relays, we developed a compact and versatile computing architecture in which light intensity dynamically reconfigures the conductive network, allowing the relays to collectively govern both the switching state and the routing of information transmission pathways. This light-induced pathway reconfiguration establishes a promising paradigm for optically controlled mechanical computing, extending traditional actuator-based logic from isolated mechanical motions65, 66 to programmable and network-level information processing.

Construction of Relays with Light-Programmable Characteristics

We constructed two types of relays based on the polyaniline composite film (PCF) to realize the core physical components of the light-programmable mechanical computing concept. As shown in Fig. 2a, we fabricated a SPST relay using a type-I PCF structure (PCF I: PDMS/Ag NWs/PANi-PNIPAm). This configuration consists of a single silver nanowires (Ag NWs) conductive layer sandwiched between a polydimethylsiloxane (PDMS) substrate and a polyaniline–poly(N-isopropylacrylamide) (PANi-PNIPAm) active layer, forming an isolated conductive channel. The operational mechanism is schematically shown in Fig. 2b. We applied a supply voltage (Vcc) to bottom electrode 1 (BE1), used light intensity at point A as the optical control input, and collected the output signal (O1) from bottom electrode 2 (BE2). Logical inputs were encoded using light stimuli, where illuminated and dark states corresponded to logic 1 and logic 0, respectively. When the light input was set to 0 (Fig. 2b(i)), the PCF remained flat and suspended above BE2, thereby maintaining an open circuit between BE1 and BE2 and yielding an output of O1 = 0, as illustrated in Fig. 2c. Upon switching the light input to 1 (Fig. 2b(ii)), light actuation induced a downward bending of the PCF, bringing it into contact with BE2 and closing the circuit. This transition resulted in an output state of O1 = 1, as also shown in Fig. 2c. The logical operation of the SPST relay and its reset mechanism under varying humidity conditions are demonstrated in Supplementary Movie 3. Through this experiment, we achieved light-programmable on/off switching of a single conductive pathway, thus realizing the SPST relay function.

To extend binary switching toward directional signal routing, we designed and fabricated an SPDT relay based on an enhanced type-II PCF structure (PCF II: Ag NWs/PDMS/Ag NWs/PANi-PNIPAm), as illustrated in Fig. 2d. PCF II incorporates an additional Ag NWs layer atop the PDMS substrate, forming dual conductive channels for bidirectional control. As shown in Fig. 2e, we constructed the SPDT relay with two top electrodes (TE1, TE2) and two bottom electrodes (BE1, BE2). The top electrodes were fabricated using a PDMS/Ag NWs composite (Supplementary Fig. 5), which offered high conductivity and mechanical compliance. This flexible composite electrode deformed synchronously with the PCF during actuation, maintaining stable contact and minimizing interfacial stress or delamination that typically occur with rigid metal contacts. Such mechanical-electrical compatibility ensured robust performance over repeated actuation-recovery cycles. In operation, we applied Vcc to TE1 and BE1 and collected the output signals O1 and O2 from BE2 and TE2, respectively. When the light input was 0 (Fig. 2e(i)), PCF II remained flat and contacted only TE2, thereby activating the upper conductive path (O2 = 1) while keeping the lower path open (O1 = 0), as illustrated in Fig. 2f. Upon illumination (A = 1), the film underwent downward bending, disengaging from TE2 and establishing contact with BE2. This transition activated the lower conductive path (O1 = 1) and simultaneously deactivated the upper path (O2 = 0). These results demonstrate that the SPDT relay achieved bidirectional signal routing and light-controlled path selection.

Through systematic experimental characterization, we demonstrated that the switching dynamics of the relays can be effectively tuned by both illumination intensity and environmental conditions (Supplementary Fig. 6). The switching time is defined as the sum of the response time and the recovery time. Under an illumination intensity of 130 mW/cm2 at 29 ± 1 °C and 83 ± 3% relative humidity, the single-pole single-throw (SPST) relay exhibited a response time of 1.02 s and a recovery time of 2.07 s, corresponding to a total switching time of 3.09 s and an operating frequency of approximately 0.32 Hz. Similarly, the single-pole double-throw (SPDT) relay showed a response time of 1.20 s and a recovery time of 2.05 s, resulting in a switching time of 3.25 s and an operating frequency of about 0.31 Hz (Supplementary Fig. 7). Notably, increasing the illumination intensity to 300 mW/cm2 under the same temperature and humidity conditions significantly reduced the SPST response time to ~0.13 s, while the recovery time remained at 2.4 s. This led to a shorter total switching time of 2.53 s and a correspondingly higher operating frequency of ~0.40 Hz, demonstrating that faster switching can be achieved through optical optimization (Supplementary Fig. 7c). Although the typical switching time remains on the order of seconds, such timescales are well suited for applications including adaptive camouflage, environmental sensing, soft robotics, and low-frequency logic, where reversibility, adaptability, and energy efficiency are more critical than ultrafast response.

The relays also exhibited robust mechanical reversibility and long-term operational stability. To evaluate their robustness under varying humidity, we measured the response and recovery characteristics of the SPST relay (Supplementary Fig. 8a–c). As humidity increased, the response time showed a slight delay, whereas the recovery time was markedly accelerated, confirming stable and reliable recovery behavior across all humidity levels. Moreover, the SPST relay maintained consistent performance over more than 600 continuous actuation–reset cycles without observable fatigue or degradation (Supplementary Fig. 8d). These results collectively demonstrate the high reliability and robustness of the relays, establishing them as ideal building blocks for constructing light-programmable mechanical computing systems.

To further elucidate the underlying mechanism, we quantitatively analyzed the coupled photo-thermal-mechanical-electrical processes based on a thermal conduction model and beam deformation theory (Supplementary Note 2, Supplementary Figs. 9-10). The analysis reveals how light-induced photothermal conversion propagates through heat conduction to actuate mechanical deformation, thereby modulating the conductive pathways and enabling controllable signal transmission. These insights provide theoretical guidance for the design and optimization of light-programmable mechanical computing architectures.

Realization of Scalable Logic Computing

We constructed scalable logic computing circuits by integrating light-programmable SPST and SPDT relays, as shown in Fig. 3. The SPST relay, capable of controlling the on/off state of a single conductive pathway, serves as the fundamental element for basic Boolean operations. As shown in Fig. 3a(i), we fabricated an AND gate by connecting two SPST relays in series (Supplementary Fig. 11), and the corresponding optical image is presented in Fig. 3a(ii). The circuits were fabricated on flexible styrene-ethylene-butylene-styrene (SEBS) substrates, with the fabrication process and testing setup illustrated in Supplementary Note 3 (Supplementary Figs. 12-14). We measured the output response under different input combinations. When both logic inputs A and B were set to 0, both relays remained open, interrupting voltage transmission from the supply (Vcc) to the output and resulting in a low output signal QAND (QAND = 0), as shown in Fig. 3d. When only one input was set to 1, the corresponding relay closed while the other remained open, leaving the circuit incomplete and keeping QAND at a low level (QAND = 0). Only when both inputs were set to 1 did both relays close simultaneously, completing the circuit and producing a high-level output QAND (QAND = 1). This behavior confirms the correct implementation of the AND logic operation (Supplementary Fig. 15 and Supplementary Movie 4-5). We also constructed an OR gate by connecting two SPST relays in parallel, as shown in Fig. 3b(i), and obtained the corresponding optical image shown in Fig. 3b(ii). In this configuration, current conduction occurred when either relay was closed, so the output QOR remained low (QOR = 0) only when both A and B were set to 0. For all other input combinations, the output QOR remained high (QOR = 1), consistent with OR logic behavior (Fig. 3d).

To achieve more complex combinational logic, we implemented SPDT relays to perform bidirectional signal routing. As illustrated in Fig. 3c(i), we constructed an XOR gate by connecting two SPDT relays in parallel (Supplementary Fig. 16), and the optical image of the fabricated circuit is shown in Fig. 3c(ii). We measured the output response under all input combinations and obtained the results summarized in Fig. 3d. When both A and B were 0 or both 1, the corresponding conductive paths were simultaneously connected or disconnected, blocking Vcc from reaching the output and yielding a low QXOR (QXOR = 0). In contrast, when A and B were in opposite logic states, one relay conducted while the other remained open, allowing Vcc to reach the output and generating a high QXOR (QXOR = 1) (Supplementary Fig. 17 and Supplementary Movie 6). The detailed operation mechanism of the XOR logic is presented in Supplementary Fig. 18. Furthermore, we realized an inverter (NOT gate) by slightly modifying the XOR configuration, where the lower PCF film was fixed to BE1 and BE2 with silver paste, and only input A was varied. The resulting output corresponded to the logical NOT operation of A (Supplementary Fig. 19).

We further demonstrated the scalability of the light-programmable mechanical computing system by cascading SPST and SPDT relays to construct combinational logic circuits. As shown in Fig. 3e, we implemented one-bit full adder by integrating basic logic gates (see detailed assembly method in Supplementary Note 3 and Supplementary Movie 7), and the optical images of the fabricated circuits are provided in Supplementary Fig. 20. The cascading operation was achieved by using the output voltage of one logic gate to drive a light source, which optically triggered the subsequent stage. The one-bit full adder comprises three logic inputs: A, B, and Cin, which correspond to two binary values and a carry input. The circuit generates two outputs: QSum and QCout, representing the least significant bit and the carry of the binary addition result, respectively. To visualize the output states, blue and red LEDs integrated into the polyimide flexible circuit board (PI FCB) are used to indicate QSum and QCout, respectively, as shown in Supplementary Fig. 20. Fig. 3f summarizes the output voltage values for all input combinations, with experimental validation provided in Supplementary Movie 8. The detailed operational mechanism of the adder is illustrated in Supplementary Fig. 21. To further validate the scalability of the system for more complex logic computing tasks (Supplementary Note 4), we fabricated a two-bit adder consisting of four inputs (A1, B1, A2, B2) and three outputs (Qcout, S2, S1). The experimental setup, truth table, and detailed operation process are shown in Supplementary Fig. 22. The measured results for all sixteen input combinations matched the theoretical truth table precisely, confirming the correctness, stability, and expandability of the light-programmable mechanical computing architecture.

Finally, to enable autonomous operation of the constructed computing circuits, we implemented an autonomously controlled resetting mechanism that facilitates self-regulated system recovery (Supplementary Note 5). As illustrated in Supplementary Fig. 23, when both optical inputs were off, an integrated humidity-control module was automatically activated to reset the relay, restoring its initial state for subsequent computation. Once the optical inputs resumed, the module was deactivated, allowing normal operation to continue, with experimental validation provided in Supplementary Movie 9. This autonomously controlled strategy ensures autonomous recovery without external intervention, thereby advancing the practical realization of self-sustaining, light-programmable mechanical computing systems.

Environment-interactive camouflage enabled by light-programmable mechanical computing

Building on the demonstrated light-programmable logic computing capability, we developed an adaptive texture camouflage system inspired by cephalopods such as octopuses and cuttlefish, which actively modulate their skin textures to blend into natural surroundings like corals, rocks, and sand. Analogously, our artificial system was designed to sense environmental optical cues and dynamically reconstruct texture patterns, offering potential applications in autonomous underwater vehicles, reconnaissance robots, and other intelligent systems requiring real-time environmental adaptability.

We constructed a 3 × 3 sensing-computation-emission (SCE) unit to realize texture perception and reconstruction on a flexible substrate, as shown in Fig. 4a. In the SCE unit, three single-pole single-throw (SPST) relays detect optical signals (P1, P2, and P3) from a 3 × 3 region of the input image (Fig. 4a(i)) and transmit the sensed information to three AND logic circuits constructed from SPST relays (Fig. 4a(ii)). The circuit generates a total of nine electrical outputs (Q11, Q12, …, Q33), consisting of two signals from each AND logic circuit and three direct outputs from the SPST relay sensors. These signals drive a 3×3 light-emitting array, where the on/off states of the bulbs reproduce the luminance distribution pattern of the input image (Fig. 4a(iii)). Detailed circuit configuration and operation principles are provided in Supplementary Note 6. Experimental testing confirmed the real-time sensing-computation-emission capability of the SCE unit for image perception and reconstruction (Supplementary Fig. 24 and Supplementary Movie 10).

Based on the demonstrated characteristics of the 3 × 3 SCE units, we evaluated the system performance within the field of view containing nine SCE units to demonstrate its texture reconstruction capability. We tested four representative brightness-gradient patterns, including gradients from bottom-left to top-right, from left to right, from bottom-right to top-left, and from bottom to top, and obtained the results shown in Fig. 4b. The reconstructed camouflage patterns (Fig. 4b(v-viii)) accurately replicated the input gradients (Fig. 4b(i-iv)) with high structural fidelity, validating the precise optical-to-mechanical formation of texture patterns. We further experimentally evaluated the adaptability of system under complex natural environmental conditions. To emulate real-world camouflage conditions, we simulated three representative backgrounds inspired by coral (Fig. 4c(i)), rock (Fig. 4c(ii)), and sand (Fig. 4c(iii)), which are typical living scenes of cephalopods. The reconstructed images (Fig. 4c(iv–vi)) successfully reproduced the corresponding environmental textures, demonstrating that the light-programmable mechanical computing architecture can dynamically generate camouflage patterns resembling diverse natural surfaces.

We further analyzed the robustness of system when exposed to environmental disturbances, such as variations in temperature, humidity, and mechanical stress. These factors may induce local failure in individual units, potentially leading to errors in the camouflage output. To assess this effect, environmental perturbations were modeled as random damage to a given proportion of functional units, which consequently lose their emissive capability. Due to the distributed design of the SCE framework, such local failures do not propagate across the system, thereby preserving global functionality. To quantitatively evaluate this robustness, we simulated camouflage performance under increasing levels of unit damage and analyzed image fidelity using a comprehensive texture similarity metric that integrates spatial and frequency-domain descriptors (Supplementary Fig. 25). The analysis reveals that even when a substantial fraction of units becomes nonfunctional, the camouflage images maintain high structural similarity to the target textures. This result highlights the intrinsic fault tolerance and resilience of the proposed design. In addition, we conducted a detailed analysis of the fidelity of the reconstructed camouflage patterns. We note that this fidelity is primarily governed by the relationship between the texture-feature size and the spatial extent of an individual SCE unit’s sensing window. High-fidelity reconstruction is achieved when the texture features are substantially larger than the 3 × 3 sensing area, whereas features approaching this scale result in reduced reconstruction accuracy. A more detailed discussion is provided in Supplementary Note 7 (Supplementary Figs. 26-28).

Beyond functional demonstration, this study highlights a conceptual advance in environment-interactive intelligence enabled by light-programmable mechanical computing. Compared with conventional metamaterial-based mechanical computing, our approach leverages material-level programmability and thin-film integration to achieve higher switching speed, scalability, and multi-stimulus adaptability (see Supplementary Note 8, Tables 2-3). Moreover, the relay-based framework can be seamlessly integrated with electronic systems as an intelligent sensing-computation module. Unlike conventional sensors that merely relay external signals, our distributed mechanical network intrinsically integrates sensing and computation, providing adaptive functionality while maintaining compatibility with digital logic architectures. Collectively, these findings open a promising pathway toward hybrid intelligent materials capable of autonomous environmental perception and reconfigurable information processing.

Methods
Synthesis of PANi-PNIPAm

The synthesis of PANi-PNIPAm suspension follows the authors' previously published articles58.

Synthesis of PNIPAm hydrogel: PNIPAm hydrogel was synthesized via precipitation polymerization. Solution A was prepared by dissolving N-isopropylacrylamide (NIPAm, 2.83 g, 98%, Energy Chemical), N, N'-methylene bisacrylamide (MBAm, 0.283 g, 98%, Energy Chemical), PEG-1000 (0.85 mg, Energy Chemical), and PEG-6000 (0.55 mg, Energy Chemical) in 50 mL ultrapure water, followed by N2 purging (30 min). Solution B, (ammonium persulfate (APS, 98%, Energy Chemical) 0.2 g in 50 mL ultrapure water, N2-purged 10 min) was added to Solution A. The combined solution was maintained at 70 °C for 3 h under continuous N2 atmosphere with constant stirring. The polymerization was quenched by rapid cooling in an ice-water bath. The resulting milky-white PNIPAm hydrogel underwent hydration-induced expansion upon immersion. The swollen hydrogel was then homogenized at 1500 rpm for 1 h to yield a uniform PNIPAm suspension. Synthesis of PANi-PNIPAm:10 mL of hydrochloric acid, 0.93 mL of aniline (98%, TCI), 2.287 g of lithium chloride (99.5%, Energy Chemical), and 2.282 mg of APS (dissolved in 10 mL of ultrapure water) were introduced into the PNIPAm suspension, followed by a 36-hour reaction at -27 ℃. The product was neutralized with Na2CO3 (99.8%, Sinopharm Chemical Reagent Co., Ltd.), washed, concentrated, and lyophilized to yield PANi-PNIPAm powder.

Synthesis of Ag NWs

The synthesis of Ag NWs was performed by the polyol method according to the literature63. Briefly, 0.2 g of polyvinylpyrrolidone (PVP, Mw = 360000, Energy Chemical) was added to 25 mL ethylene glycol (EG, 99.9%, Energy Chemical) under magnetic stirring. Then 0.25 g of AgNO3 (99%,Sigma Aldrich) was added in the mixture to form a homogeneous solution. Finally, 3.5 g of FeCl3 (98%, Energy Chemical) solution was mixed with the above solution. The resulting solution was heated to 130 ℃ for 5 hours to form Ag NWs and then cooled to room temperature. The synthesized Ag NWs solution was purified with acetone, methanol, ethanol, and subsequently redispersed in ethanol for further use.

Preparation of Ag NWs/PANi-PNIPAm/PDMS

PANi-PNIPAm solution: 0.15 g of PANi-PNIPAm powder and 0.03 g of PEG-1000 were dissolved in 1.5 mL anhydrous N-methyl-2-pyrrolidone (NMP) under 6 h stirring to obtain a homogeneous dark-blue solution. PDMS film: The PDMS base and curing agent (Sylgard 184, Dow Corning) were mixed at a 10:1 weight ratio and thoroughly blended. After degassing for 40 minutes to remove bubbles, the mixture was coated onto glass slides and cured at room temperature for 36 hours to obtain strip-shaped PDMS films. PDMS/Ag NWs: Ag NWs suspension was drop-coated onto the PDMS and thermally annealed at 80 °C. Multiple deposition cycles were performed to obtain the target Ag NWs thickness. PDMS/Ag NWs/PANi-PNIPAm: PANi-PNIPAm dispersion was dropped onto the PDMS/Ag NWs layer and thermally cured at 60°C for 12 hours to obtain a uniform PDMS/Ag NWs/PANi-PNIPAm film.

Preparation of Ag NWs/PDMS/Ag NWs/PANi-PNIPAm

The obtained PDMS/Ag NWs/PANi-PNIPAm composite was flipped, and Ag NWs dispersion was drop-coated onto the PDMS surface. Thermal treatment at 80 ℃ for 30 minutes produced the final Ag NWs/PDMS/Ag NWs/PANi-PNIPAm multilayer structure.

Fabrication of Logic Gates

The fabrication process for AND, OR, and XOR gates involves five key steps: (i) Negative Mold Fabrication: Negative molds for AND, OR, and XOR gates were designed using SolidWorks and fabricated via 3D printing (0.01 mm / layer resolution) with photopolymer resin (Creality 3D), followed by UV-cured (1 h). (ii) SEBS Substrate Preparation: SEBS substrates were prepared by dissolving 5 g of styrene-ethylene-butylene-styrene (SEBS, Tuftec H1221) in 28 g of toluene (99.5%, Sinopharm Chemical Reagent Co., Ltd.) under mechanical stirring. The homogeneous solution was then cast onto negative molds (AND/OR/XOR gate) and dried in a transparent acrylic box for 4 days. Freestanding SEBS films were subsequently peeled off from the negative molds. (iii) Gold Electrode Deposition: Au electrodes (60-90 nm thickness) were patterned using electron-beam evaporation (9.8×10-5 Pa, 0.5 Å/s) through custom steel mesh shadow masks. (iv) Bulb Integration: Bulbs were attached to electrodes using silver paste and double-coated adhesive tape. (v) Polyaniline Composite Films (PCFs) Assembly: The PCF (PDMS/Ag NWs/PANi-PNIPAm) was assembled by bonding the Ag NWs side to the electrodes with silver paste.

Fabrication of self-adhesive SEBS Connections

A 15 wt.% SEBS solution (Tuftec H1221, 15 wt.% in toluene) was poured into a 10 × 10 cm2 glass slide, and then placed in a transparent acrylic box with a lid for slow drying. Gold electrodes were patterned via electron-beam evaporation (60-90 nm, 0.5 Å/s) using a laser-cut stainless-steel mesh as a shadow mask. The obtained self-adhesive SEBS connections were stored in a clean box and later segmented with a precision blade.

The source of image data of Fig. 4c

Figure 4(c) (i–iii) show photographs taken by the authors and processed using the built-in dither function in MATLAB. This function converts grayscale images into binary (black-and-white) images while preserving perceived grayscale contrast through a dithering algorithm.

Peer review rounds
[{"round": 1, "reviewer_comments": {"reviewer_1": "In the manuscript “Light-Programmable Mechanical Computing via Polyaniline Composite Film” Xiunan Yan and colleagues present a light-programmable mechanical computing that utilizes polyaniline composite film (PCF). The authors constructed light-programmable mechanical logic circuits with SPST and SPDT relays realize scalable logic operations, including a full-adder circuit. Although this is an interesting work with good results, in the Reviewer's opinion, this manuscript does not seem to provide \"new\" materials nor innovative method to be considered in the journal, and there remain several key issues to be addressed in the manuscript.\n1. There is no novelty in terms of material because PANi - PNIPAm was reported in papers (such as: 10.1021/acsami.2c01549, 10.1039/d3tc00990d) and Ag NWs are also commonly used ones.\n2. Actuator-based mechanical logic circuits have been reported, and from a functional point of view previous studies have similarities with this work, so it is essential to clearly differentiate the core novelty of this study from the previously reported systems such as 10.1016/j.cej.2025.162103, 10.3390/s25072051.\n3. In my opinion, the section “The Realization of Adaptive Texture Camouflage” in the manuscript is more innovative than the rest of the article, but the authors have only given the simulation results in this section, and the actual computational capability has not been further investigated. Also, the authors have not investigated the response error of the system under the complex environment, and these potential errors may have a negative impact on its application. The authors should further investigate the system to enhance the clarity and depth of the study.", "reviewer_2": "In this work, Yan et al. present a novel demonstration of light-programmable mechanical computing using a polyaniline composite film (PCF). By integrating light-responsive expansion and contraction elements with flexible conductive layers, they achieve mechanically reconfigurable conductive pathways that form the basis of light-controlled relays—universal modules for scalable logic circuits. The authors validate their platform with a suite of logic operations, including a full-adder circuit, and further showcase an environment-adaptive optical camouflage system that senses ambient textures and generates matching camouflage patterns. This work skillfully combines photothermal effects, thermally induced deformation, and flexible electronics to fuse mechanical, thermal, optical, and electrical domains into a new paradigm for environment-interactive computing. To my knowledge, it is the first report of mechanical computing applied to real-world environmental interactions, representing a significant conceptual and technical advance. The platform’s simple architecture, clear mechanism, and clear path to scalability make it a timely and impactful contribution to the fields of mechanical metamaterials, unconventional computing, and intelligent adaptive systems. Therefore, I would like to recommend it for publication in Nature Communications. Before publication, I suggest optimizing the following details to further enhance the readability of the article.\n1. I encourage the authors to enrich the discussion around Figure 1 by explicitly explaining the rationale for employing both single-pole single-throw (SPST) and single-pole double-throw (SPDT) relays as the foundational circuit elements. Clarifying how each switch uniquely contributes to signal routing—and how their combined use yields a more versatile, compact architecture—will help readers appreciate the design choices behind this innovative computing paradigm. This additional context would substantially enhance the manuscript’s conceptual clarity.\n2. I suggest the authors briefly clarify the role and material choice for the top electrode shown in Figure 2e. Specifically, is its function purely conductive, or does the composite film impart additional benefits? What factors led to the use of a flexible film rather than a conventional metal contact? Such clarification will guide readers in making informed material and design choices for future studies of similar devices.\n3. The NOT gate represents the most fundamental logic operation, yet its implementation is not addressed in the current manuscript. Could the authors provide a brief rationale for this omission?\n4. To enhance reader comprehension of the more intricate XOR and full-adder circuits, I recommend that the authors include schematic illustrations detailing each circuit’s operational mechanism. Clear, step-by-step diagrams—highlighting relay states and signal flow—would greatly aid in conveying the underlying logic and ensure readers can readily grasp the practical functionality of these complex assemblies.\n5. The video footage indicates that the system’s response time operates on the order of seconds. While high-speed switching is not a primary requirement for mechanical computing, I recommend the authors explicitly quantify this response latency. Providing explicit performance metrics will assist readers in accurately evaluating which real-world application scenarios are best suited to this technology’s characteristics.", "reviewer_3": "Mechanical computation using a photoresponsive polyaniline composite film (PCF). By leveraging photothermal effects to induce mechanical deformation and reconfigure conductive pathways, the authors have constructed SPST and SPDT relays capable of performing logic operations, including a one-bit full adder. Additionally, the authors explore an application in adaptive texture camouflage, positioning their work as a step toward environmentally responsive intelligent systems.\nThe idea of integrating light-controlled logic with mechanical deformation is promising and could inspire new directions in soft robotics, adaptive materials, and non-traditional computing architectures. However, both the novelty and technical rigor fall short of the high standards required for publication in Nature Communications in its current form. Significant improvements in quantitative analysis, scalability, mechanistic understanding, and presentation style are necessary.\nI recommend a major revision with the following specific points for improvement.\n________________________________________\nMajor Points for Revision\n1. Scalability, System Integration, and Practical Relevance\n• The current demonstrations are limited to a 1-bit adder and a 3×3 camouflage display. To strengthen the manuscript’s impact:\no Demonstrate scalability toward multi-bit logic circuits (e.g., 2-bit or 4-bit systems) or simple processors to support the vision of light-driven general-purpose computing materials.\no Evaluate long-term operational stability under varying environmental conditions (light intensity variability, temperature, humidity). Present quantitative data with confidence intervals to validate reproducibility and robustness.\no The need for humidity-induced resetting is a practical limitation. Propose or prototype autonomous control mechanisms (e.g., embedded humidity feedback loops) to enhance practical relevance.\no The manuscript should discuss how the system's switching speeds (currently around 1 second per logic operation) could be optimized or how it could interface with conventional computing systems despite its slow speed.\n2. Quantitative Analysis and Theoretical Modeling\n• The lack of quantitative analysis weakens the manuscript's scientific rigor:\no Provide detailed measurements of light intensity (mW/cm²), power consumption per switching event, and thermal response curves.\no Develop numerical models or simulations that describe the photothermal-to-mechanical-to-electrical transformation. Suggested approaches include:\n  Thermal conduction models combined with beam deformation theories.\n  Dynamic simulations of switching delays, rise times, and potential operating frequency limits.\no Generate multivariate plots correlating light intensity, temperature, curvature, and conductivity to support mechanistic insights.\n3. Comparison with Related Technologies\n• The current comparisons with existing work are largely qualitative and insufficient. Strengthen this section by:\no Including a quantitative benchmark table comparing key performance metrics (e.g., switching time, power consumption, scalability, environmental resilience) with other stimuli-responsive systems (thermal, magnetic, pressure, optical).\no Specifically reference and compare with:\n  El Helou et al., Nat. Commun. 2022\n  Byun et al., Nat. Commun. 2024\n  Mei et al., Nat. Commun. 2021 on mechanical metamaterial computing\n  Recent reviews on mechanical metamaterials (e.g., APL Electronic Devices 2025)\no Discuss the trade-offs between mechanical computing using metamaterials versus the present material-based approach, focusing on:\n  Switching speed and delay\n  Manufacturing complexity and scalability\n  Reconfigurability and environmental responsiveness\n4. Mechanical Durability and Reversibility\n• The claims regarding mechanical reversibility under humidity changes require experimental validation:\no Provide visual documentation (images or videos) and quantitative graphs demonstrating reversibility and mechanical recovery.\no Assess durability over multiple actuation cycles to ensure practical feasibility for repetitive logic operations.\n5. Clarity and Depth in Application Demonstration\n• The adaptive camouflage demonstration is conceptually interesting but technically underdeveloped:\no Clarify whether Figure 4c represents experimental data or simulation.\no Detail the environmental texture sensing mechanism, the source of image data, and the electronic or material response pathway leading to pattern change.\no Expand the camouflage section to provide a coherent use-case scenario and potential performance benchmarks.\n6. Material Selection Justification\n• Provide quantitative rationale for the selection of PANi, PNIPAm, PDMS, and Ag NWs:\no Include photothermal conversion efficiency measurements or references.\no Compare with alternative materials for responsiveness, durability, and energy efficiency to strengthen the materials engineering contribution.\n7. Application Scope and Positioning\n• The manuscript should clearly define the target applications:\n• Given the slow switching speed, traditional computing applications are unlikely. Potential use-cases could include:\n  Adaptive camouflage systems\n  Soft robotic skin\n  Low-frequency adaptive sensing\no Clearly state the performance limitations and position the work accordingly within non-traditional computing.\n8. Manuscript Presentation and Communication Style\n• The current narrative is descriptive and material-focused; for Nature Communications, a sharper, problem-solving storyline is recommended:\no Adopt a “One Figure = One Key Message” approach to improve clarity.\no Refine the Introduction and Conclusion to clearly state:\n  What problem is being solved\n  What new possibilities this enables\no Condense and sharpen key findings to maximize readability and impact.\n________________________________________\nFinal Recommendation\nThis manuscript presents an innovative concept of light-programmable mechanical logic with potential applications in adaptive systems and soft robotics. However, substantial improvements in quantitative rigor, theoretical modeling, durability assessment, and presentation style are required to meet the impact, scientific depth, and clarity expected by Nature Communications.\nI recommend major revision and reassessment upon thorough addressing of the points above. Alternatively, the authors may consider submission to specialized journals in smart materials, soft electronics, or mechanical computing, where the current level of novelty and rigor may be more appropriate.", "reviewer_4": "I co-reviewed this manuscript with one of the reviewers who provided the listed reports. This is part of the Nature Communications initiative to facilitate training in peer review and to provide appropriate recognition for Early Career Researchers who co-review manuscripts."}, "author_response": "Response to Reviewers\nReviewers’ Comments:\nReviewer #1 (Remarks to the Author):\nIn the manuscript “Light-Programmable Mechanical Computing via Polyaniline\nComposite Film” Xiunan Yan and colleagues present a light-programmable\nmechanical computing that utilizes polyaniline composite film (PCF). The authors\nconstructed light-programmable mechanical logic circuits with SPST and SPDT\nrelays realize scalable logic operations, including a full-adder circuit. Although\nthis is an interesting work with good results, in the Reviewer's opinion, this\nmanuscript does not seem to provide \"new\" materials nor innovative method to\nbe considered in the journal, and there remain several key issues to be addressed\nin the manuscript.\nResponse: We respectfully disagree with the reviewer’s comment. The novelty of our\nwork lies in the design of a light-responsive composite film that couples mechanical\ndeformation with electrically reconfigurable pathways, enabling scalable light-\nprogrammable relays. This approach not only supports complex logic such as a 2-bit\nadder but also, for the first time, demonstrates an environment-adaptive camouflage\nsystem, establishing a scalable and application-oriented paradigm for mechanical\ncomputing.\n1. There is no novelty in terms of material because PANi – PNIPAm was reported\nin papers (such as: 10.1021/acsami.2c01549, 10.1039/d3tc00990d) and Ag NWs are\nalso commonly used ones.\nResponse: We respectfully disagree with the reviewer’s comment. While PANi–\nPNIPAm and Ag NWs are established materials, the novelty of our work lies in their\nintegration into a composite that couples light-induced mechanical deformation with\nelectrically reconfigurable pathways. This design enables direct light-programmable\ncircuit reconstruction and scalable logic computation, which has not been\ndemonstrated before.\nTo reflect the reviewers' suggestions, we have added the relevant explanation in the\nrevised manuscript [Please see lines 100-103, page 5].\nBy integrating these well-established materials58,59 into a multilayer composite\nstructure, we created an ideal platform that converts optical stimuli into mechanically\nreconfigurable conductive pathways.\n2. Actuator-based mechanical logic circuits have been reported, and from a\nfunctional point of view previous studies have similarities with this work, so it is\nessential to clearly differentiate the core novelty of this study from the previously\nreported systems such as 10.1016/j.cej.2025.162103, 10.3390/s25072051.\nResponse: We thank the reviewer for this insightful comment. The essential novelty\nof our work lies in establishing a light-induced pathway reconfiguration computing\nparadigm, where light-programmable SPST and SPDT relays regulate not only the\nswitching states but also the routing of information transmission pathways. This\nrepresents a fundamental shift from traditional actuator-based mechanical computing,\nwhich primarily focuses on local actuation or switching at the device level.\nIn contrast to previously reported actuator-based systems (e.g., refs.\n10.1016/j.cej.2025.162103 and 10.3390/s25072051), our work establishes a system-\nlevel computing architecture that enables dynamic reconfiguration of information\npathways, representing a conceptual advance from actuator-level switching toward\narchitecture-level programmability. This distinction provides three main advantages.\nFirst, it enables scalable and hierarchical logic construction beyond basic gate\nfunctions, achieved through the use of light-programmable relays that can be\ninterconnected to realize complex circuits such as XOR and 2-bit adders.\nSecond, it achieves a more efficient and goal-oriented coupling between material\nbehavior and computing function, enabled by a top-down design strategy in which\ncomputational requirements guide the development of relays capable of pathway\nreconfiguration, rather than relying on material-level actuation effects.\nFinally, it extends the applicability of mechanical computing toward real-world,\nenvironment-adaptive systems, as demonstrated by a light-programmable\ncamouflage platform that senses and reproduces ambient textures, showing how\npathway reconfiguration translates into practical, adaptive, and intelligent computing\nfunctionality.\nTo describe the differences between our work and these demonstrations, we have\nadded the relevant discussions and these new references in the revised manuscript\n[Please see lines 137-140, page 6].\nThis light-induced pathway reconfiguration establishes a new paradigm for optically\ncontrolled mechanical computing, extending traditional actuator-based logic from\nisolated mechanical motions65,66 to programmable and network-level information\nprocessing.\n3. In my opinion, the section “The Realization of Adaptive Texture Camouflage”\nin the manuscript is more innovative than the rest of the article, but the authors\nhave only given the simulation results in this section, and the actual computational\ncapability has not been further investigated. Also, the authors have not\ninvestigated the response error of the system under the complex environment, and\nthese potential errors may have a negative impact on its application. The authors\nshould further investigate the system to enhance the clarity and depth of the study.\nResponse: We sincerely thank the reviewer for the insightful comments and for\nrecognizing the conceptual innovation of the adaptive camouflage section. In response,\nwe have supplemented experimental verification to demonstrate the actual\ncomputational capability of the system and quantitatively evaluated its robustness under\ncomplex environmental conditions, as detailed below.\n1) The actual computational capability\nTo evaluate the system’s computational performance in real-world scenarios, we\nconstructed an experimental demonstration of sensing–computation–emission (SCE)\nunit, as illustrated in Figure 4a of the manuscript (Fig R1a). Each SCE unit integrates\nlight perception, logical computation, and pattern reconstruction functionalities. The\nsystem was experimentally tested to reproduce texture camouflage patterns. Figs. R1b,\nd, and f show the original input images and their corresponding schematic camouflage\npatterns generated by the computing circuit, while Fig. R1c, e, and g present the\nexperimental results.\nA demonstration video (Movie 11) further provides direct visual confirmation that\nthe experimentally reconstructed camouflage images closely match the simulated\nresults. These results validate the operational capability of the basic units and confirm\nthat the light-programmable computing system can successfully execute texture\nreconstruction of environment.\n2) The response error of the system under complex environment\nWe analyzed the system’s robustness when exposed to environmental disturbances,\nsuch as variations in temperature, humidity, and mechanical stress. These factors may\ninduce local failure in individual units, potentially leading to errors in the\ncamouflage output. To assess this effect, environmental perturbations were modeled\nas random damage to a given proportion of functional units, which consequently lose\ntheir emissive capability.\nDue to the distributed design of the SCE framework, such local failures do not\npropagate across the system, thereby preserving global functionality. To\nquantitatively evaluate this robustness, we simulated camouflage performance under\nincreasing levels of unit damage and analyzed image fidelity using a comprehensive\ntexture similarity metric that integrates spatial and frequency-domain descriptors (Fig.\nR2).\nThe analysis reveals that even when a substantial fraction of units becomes\nnonfunctional, the camouflage images maintain high structural similarity to the target\ntextures. This result highlights the intrinsic fault tolerance and resilience of the\nproposed design.\nWe agree that further studies incorporating detailed environmental mechanisms and\nexperimental validations are essential, and we envision this as an important direction\nfor our future work.\nImage texture similarity evaluation method\nWe quantitatively assessed image texture similarity using a multi-feature fusion\nstrategy. Images were first preprocessed via grayscale conversion, size alignment, and\nnormalization to ensure comparability. Complementary descriptors were then extracted\nfrom both spatial and frequency domains. In the spatial domain, gray-level co-\noccurrence matrices provided contrast, correlation, energy, and homogeneity metrics,\nwhile local binary pattern histograms captured fine-scale microstructures. In the\nfrequency domain, fast Fourier transforms yielded radial power spectral density and\nangular energy distribution, from which an anisotropy index characterized directional\npreferences. The Wiener–Khinchin theorem was applied to estimate the autocorrelation\nfunction, revealing periodic structures, and structure tensor coherence quantified the\ndirectional order of local gradients. Each descriptor was normalized to [0,1], and a\nweighted average produced the final composite similarity score. By integrating local\nstatistics, spectral features, and directional order, this approach robustly distinguishes\nstructured textures from stochastic noise, providing a reliable measure of image\nsimilarity.\nFig. R1. Experimental validation of the texture camouflage reconstruction unit. a\n(i) sensing–computation–emission (SCE) unit, (ii) The spatial distribution of the sensed\noptical input signals (P , P , and P ) and the corresponding output signals (Q , Q , …,\n1 2 3 11 12\nQ ) in the SCE unit, as well as the logical relationships between the input and output\n33\nsignals. b, d, f Schematic illustrations of the original input images and the\ncorresponding camouflage patterns generated by the computing circuit. c Experimental\nresult corresponding to the camouflage pattern shown in b, where all pixels within the\n3×3 unit remain in the “off” state. e Experimental result corresponding to the\ncamouflage pattern shown in d, where only the upper-left pixel within the 3×3 unit is\nin the “on” state. g Experimental result corresponding to the camouflage pattern shown\nin e, where all pixels within the 3×3 unit are in the “on” state.\nFig. R2. Robustness characteristics of the camouflage system. a Comparison\nbetween original images and camouflaged outputs as the proportion of randomly\ndamaged unit structures increases from 0% to 100%. b Quantitative analysis of image\nsimilarity between original and generated images at different damage levels, with the\nx-axis representing damage proportion and the y-axis showing texture similarity.\nTo reflect the reviewer’s concern, we have added these experimental data and\nrelevant discussions in the revised supplementary information. [Please see\nSupplementary Note 6. The Realization of Adaptive Texture Camouflage]\nWe have also made the following revisions in the revised manuscript.\n[Please see lines 303-305, page 13].\nExperimental testing confirmed the real-time sensing-computation-emission\ncapability of the SCE unit for image perception and reconstruction (Supplementary Fig.\n24 and Movie 11).\n[Please see lines 321-334, page 14].\nWe further analyzed the robustness of system when exposed to environmental\ndisturbances, such as variations in temperature, humidity, and mechanical stress.\nThese factors may induce local failure in individual units, potentially leading to errors\nin the camouflage output. To assess this effect, environmental perturbations were\nmodeled as random damage to a given proportion of functional units, which\nconsequently lose their emissive capability. Due to the distributed design of the SCE\nframework, such local failures do not propagate across the system, thereby preserving\nglobal functionality. To quantitatively evaluate this robustness, we simulated\ncamouflage performance under increasing levels of unit damage and analyzed image\nfidelity using a comprehensive texture similarity metric that integrates spatial and\nfrequency-domain descriptors (Supplementary Fig.25). The analysis reveals that\neven when a substantial fraction of units becomes nonfunctional, the camouflage\nimages maintain high structural similarity to the target textures. This result highlights\nthe intrinsic fault tolerance and resilience of the proposed design.\nReviewer #2 (Remarks to the Author):\nIn this work, Yan et al. present a novel demonstration of light-programmable\nmechanical computing using a polyaniline composite film (PCF). By integrating\nlight-responsive expansion and contraction elements with flexible conductive\nlayers, they achieve mechanically reconfigurable conductive pathways that form\nthe basis of light-controlled relays—universal modules for scalable logic circuits.\nThe authors validate their platform with a suite of logic operations, including a\nfull-adder circuit, and further showcase an environment-adaptive optical\ncamouflage system that senses ambient textures and generates matching\ncamouflage patterns. This work skillfully combines photothermal effects,\nthermally induced deformation, and flexible electronics to fuse mechanical,\nthermal, optical, and electrical domains into a new paradigm for environment-\ninteractive computing. To my knowledge, it is the first report of mechanical\ncomputing applied to real-world environmental interactions, representing a\nsignificant conceptual and technical advance. The platform’s simple architecture,\nclear mechanism, and clear path to scalability make it a timely and impactful\ncontribution to the fields of mechanical metamaterials, unconventional computing,\nand intelligent adaptive systems. Therefore, I would like to recommend it for\npublication in Nature Communications. Before publication, I suggest optimizing\nthe following details to further enhance the readability of the article.\nResponse: We sincerely thank the reviewer for the positive and encouraging evaluation\nof our work. We are very pleased that the reviewer recognizes both the conceptual\nsignificance and the potential impact of our study on mechanical metamaterials,\nunconventional computing, and adaptive intelligent systems. The reviewer’s supportive\ncomments are highly motivating, and we have carefully addressed the suggested\nimprovements to further enhance the clarity and readability of the manuscript.\n1. I encourage the authors to enrich the discussion around Figure 1 by explicitly\nexplaining the rationale for employing both single-pole single-throw (SPST) and\nsingle-pole double-throw (SPDT) relays as the foundational circuit elements.\nClarifying how each switch uniquely contributes to signal routing—and how their\ncombined use yields a more versatile, compact architecture—will help readers\nappreciate the design choices behind this innovative computing paradigm. This\nadditional context would substantially enhance the manuscript’s conceptual\nclarity.\nResponse: We thank the reviewer for this insightful comment. The core principle of\nour computing scheme is to achieve information processing by programming the\ntransmission pathways, which involves both controlling the on/off state of a signal\nchannel and reconfiguring its routing. In this framework, the SPST relay functions as\nthe fundamental element for switching a pathway on or off, while the SPDT relay\nenables the rerouting of signals between alternative channels.\nThe combination of these two types of relays provides a versatile and compact\nfoundation for our system. Specifically, SPST relays are well suited for implementing\nbasic logic operations such as AND and OR, whereas the inclusion of SPDT relays\nallows the efficient realization of more complex combinational logic, including XOR\ngates and multi-bit adders. This pathway-based design principle thus underpins both\nthe simplicity and the scalability of the proposed light-programmable mechanical\ncomputing paradigm.\nTo reflect the reviewer’s concern and provide readers with a clear understanding of\nthe synergistic role of SPST and SPDT relays, we have added the following discussions\nin the revised manuscript. [Please see lines 129-133, page 6]\nThe single-pole single-throw (SPST) relay functions as a binary switch that connects\nor disconnects a transmission path, serving as the fundamental unit for controlling\nsignal on/off states. The single-pole double-throw (SPDT) relay directs the input\nvoltage (V ) between two alternative output channels, enabling signal routing.\ncc\n2. I suggest the authors briefly clarify the role and material choice for the top\nelectrode shown in Figure 2e. Specifically, is its function purely conductive, or does\nthe composite film impart additional benefits? What factors led to the use of a\nflexible film rather than a conventional metal contact? Such clarification will\nguide readers in making informed material and design choices for future studies\nof similar devices.\nResponse: We thank the reviewer for raising this important point. The top electrode in\nFig.2e is composed of Ag nanowires (AgNWs) deposited on a PDMS substrate. This\ndesign first ensures the required electrical conductivity. More importantly, the\nflexible PDMS/AgNW composite provides mechanical compliance with the device’s\ndeformation during actuation and recovery, which helps distribute stress, prevents\ninterfacial damage, and maintains stable electrical contact throughout repeated cycling.\nWe deliberately chose a flexible composite electrode rather than a conventional\nrigid metal contact for two main reasons. First, the flexible electrode provides\nmechanical compatibility, as it can deform in concert with the device and thus ensures\nstable performance over long-term operation. Second, the soft electrode enhances\ninterfacial stability by preventing delamination or cracking, which often occurs at the\ninterface between rigid metals and flexible substrates.\nTo reflect the reviewer’s concern, we have added this clarification to the revised\nmanuscript. [Please see lines 167–173, pages 7-8]\nThe top electrodes were fabricated using a PDMS/Ag NWs composite (Supplementary\nFig. 5), which offered high conductivity and mechanical compliance. This flexible\ncomposite electrode deformed synchronously with the PCF during actuation,\nmaintaining stable contact and minimizing interfacial stress or delamination that\ntypically occur with rigid metal contacts. Such mechanical-electrical compatibility\nensured robust performance over repeated actuation-recovery cycles.\n3. The NOT gate represents the most fundamental logic operation, yet its\nimplementation is not addressed in the current manuscript. Could the authors\nprovide a brief rationale for this omission?\nResponse: We thank the reviewer for highlighting this important point. Indeed, the\nNOT gate is a fundamental logic element and can be realized by modifying the XOR\ncircuit. As shown in Fig. R3a, the XOR circuit structure was modified by fixing the\nlower PCF to BE and BE using silver paste while keeping only input A as a variable.\n1 2\nUnder this configuration, the output terminal produces the inverted state of input\nA, thereby implementing the NOT operation. The schematic in Fig. R3a illustrates\nthe operating principle and signal pathway of this design, while the corresponding logic\ntest results in Fig. R3b confirm its functionality: when input A = “1,” the output is 0;\nwhen input A = “0,” the output is 1.\nIn the initial submission, we did not present the NOT gate separately because its\nlogic functionality was already embedded in the XOR operation. However,\nfollowing the reviewer’s valuable suggestion, we have now explicitly added this\ndemonstration to highlight the completeness of our logic implementation.\nFig. R3. The realization of NOT gate. a Schematic of NOT gate realized by an XOR,\nwith the bottom PCF connected and fixed to BE and BE via silver conductive paint,\n1 2\nleaving A as the sole variable input. Panels (i)-(ii) show relay states, the flow of\nand logic output for the two possible input combinations, with red\nand blue arrows indicating signal direction. b Measured input (A) and output (Q )\nNOT\nvoltage characteristics.\nTo reflect the reviewer’s concern, we have added experimental data of NOT gate in\nthe revised supplementary information. [Please see Supplementary Fig.19]\nWe have also made the following revisions in the revised manuscript. [Please see\nlines 247-251, page 11].\nFurthermore, we realized an inverter (NOT gate) by slightly modifying the XOR\nconfiguration, where the lower PCF was fixed to BE and BE with silver paste, and\n1 2\nonly input A was varied. The resulting output corresponded to the logical NOT\noperation of A (Supplementary Fig. 19).\n4. To enhance reader comprehension of the more intricate XOR and full-adder\ncircuits, I recommend that the authors include schematic illustrations detailing\neach circuit’s operational mechanism. Clear, step-by-step diagrams—highlighting\nrelay states and signal flow—would greatly aid in conveying the underlying logic\nand ensure readers can readily grasp the practical functionality of these complex\nassemblies.\nResponse: We thank the reviewer for this valuable suggestion. To improve clarity and\nassist readers in understanding the operation of the more complex circuits, we have\nadded detailed schematic illustrations for both the XOR and full-adder circuits\n(Figs. R4–R5).\n1) Each figure now includes a structural diagram of the corresponding logic gate, with\nthe open and closed states of individual relays explicitly marked to visualize the\nswitching behavior.\n2) The signal propagation paths are clearly annotated with directional arrows,\nillustrating how input signals traverse the network to generate the final output.\nThese additions, along with expanded figure captions, make the operational\nmechanisms of the intricate circuits more intuitive and enhance the reproducibility of\nthe design.\nTo reflect the reviewer’s concern, we have incorporated these schematics into the\nrevised supplementary information [Please see Supplementary Fig. 18 and Fig. 21] to\nprovide a clearer visualization of the logic operations mechanism and functional\nbehavior of the XOR and full-adder.\nAdditionally, we have added the following presentation in the revised manuscript.\n[Please see lines 246-247 page 11]\nThe detailed operation mechanism of the XOR logic is presented in Supplementary\nFig.18.\n[Please see lines266-267, page 11]\nThe detailed operational mechanism of the adder is illustrated in Supplementary\nFig. 21.\nFig. R4. Schematic of the operational mechanism of XOR gate. Panels a–d show\nrelay states, the flow of electrical signals, and logic output for the four possible input\ncombinations, with red and blue arrows indicating signal direction.\nFig. R5. Schematic of operational mechanism of the 1-bit full-adder circuit. Panels\na–c show relay states, the flow of electrical signals, and logic output for the three\npossible input combinations, with red and blue arrows indicating signal direction.\n5. The video footage indicates that the system’s response time operates on the\norder of seconds. While high-speed switching is not a primary requirement for\nmechanical computing, I recommend the authors explicitly quantify this response\nlatency. Providing explicit performance metrics will assist readers in accurately\nevaluating which real-world application scenarios are best suited to this\ntechnology’s characteristics.\nResponse: We thank the reviewer for raising this important point. To directly address\nthe concern, we quantified the response and recovery times of both SPST and\nSPDT relays under illumination at 130 mW/cm2, 30 °C, and 83 ± 3% RH (Fig. R6).\nThe SPST relay showed a light-driven response time of 1.02 s with a recovery time of\n2.07 s, while the SPDT relay exhibited values of 1.20 s and 2.05 s. Additional\nmeasurements under varied environmental conditions are provided in Fig. R8.\nImportantly, by increasing the illumination intensity to 310 mW/cm2, the SPST relay\nachieved a rapid response of 0.127 s, confirming the potential for substantially faster\nswitching under optimized conditions.\nAlthough the typical operation speed is on the order of seconds, we emphasize that\nthis time scale is well aligned with application scenarios where ultrafast switching is\nnot required, such as low-frequency logic control, environmental sensing, adaptive\ncamouflage, soft robotics, and flexible mechanical logic systems. In these domains,\nthe advantages of environmental adaptability, stability, reversibility, low energy\nconsumption, and scalability are more critical than high speed, underscoring the\npractical significance of our approach.\nFig. R6. Response and recovery times of the SPST and SPDT relays under illumination\nof 130 mW/cm2 at 29 ± 1 °C and 83 ± 3 % RH.\nTo facilitate an accurate assessment of the applicability of this technology, we have\nincorporated the response time measurements of both relay types into the revised\nsupplementary information [Please see Supplementary Fig. 7].\nWe have also added the following statement in the revised manuscript. [Please see\nlines 184-187 page 8]\nUnder an illumination of 130 mW/cm2 at 30 °C and 83 ± 3% relative humidity, the\nSPST relay exhibited a response time of 1.02 s and a recovery time of 2.07 s, while the\nSPDT relay showed corresponding values of 1.20 s and 2.05 s (Supplementary Fig. 7).\nReviewer #3 (Remarks to the Author):\nMechanical computation using a photoresponsive polyaniline composite film\n(PCF). By leveraging photothermal effects to induce mechanical deformation and\nreconfigure conductive pathways, the authors have constructed SPST and SPDT\nrelays capable of performing logic operations, including a one-bit full adder.\nAdditionally, the authors explore an application in adaptive texture camouflage,\npositioning their work as a step toward environmentally responsive intelligent\nsystems. The idea of integrating light-controlled logic with mechanical\ndeformation is promising and could inspire new directions in soft robotics,\nadaptive materials, and non-traditional computing architectures. The idea of\nintegrating light-controlled logic with mechanical deformation is promising and could\ninspire new directions in soft robotics, adaptive materials, and non-traditional\ncomputing architectures. However, both the novelty and technical rigor fall short of\nthe high standards required for publication in Nature Communications in its current\nform. Significant improvements in quantitative analysis, scalability, mechanistic\nunderstanding, and presentation style are necessary. I recommend a major revision\nwith the following specific points for improvement.\nResponse: We thank the reviewer for recognizing the promise of our proposed concept\nand for the positive evaluation of the potential impact of our work. In response to the\nreviewer’s constructive comments, we have carefully revised the manuscript by\naddressing all concerns regarding quantitative analysis, scalability, mechanistic\nunderstanding, and presentation style. A detailed point-by-point response is provided\nbelow.\nMajor Points for Revision\n1. Scalability, System Integration, and Practical Relevance. The current\ndemonstrations are limited to a 1-bit adder and a 3×3 camouflage display. To\nstrengthen the manuscript’s impact:\n1-a Demonstrate scalability toward multi-bit logic circuits (e.g., 2-bit or 4-bit\nsystems) or simple processors to support the vision of light-driven general-purpose\ncomputing materials.\nResponse: We thank the reviewer for this constructive suggestion. In response, we have\nfurther validated the scalability of our system by demonstrating a 2-bit adder. As\nshown in Fig. R7a, the logic diagram of the 2-bit adder comprises four inputs (A , B ,\n1 1\nA , B ) and three outputs (Q , Q , Q ). The corresponding experimental setup and\n2 2 cout S1 S2\ntruth table are presented in Fig. R7b–c. Fig. R7d shows the experimentally measured\noutputs for all 16 input combinations, which match the truth table with complete\naccuracy. These results confirm the scalability of the light-driven mechanical logic\nsystem and provide experimental evidence and design insights for realizing larger-scale,\ngeneral-purpose light-responsive computing materials.\nFig. R7. Demonstration of a 2-bit adder. a Schematic of the 2-bit adder showing four\ninputs (A , B , A , B ) and three outputs (Q , Q , Q ). b Experimental setup of the\n1 1 2 2 cout S1 S2\n2-bit adder comprising three XOR gates, three AND gates, and one OR gate. c Truth\ntable for all 16 possible input combinations. d Measured input voltages and output\nresults for all 16 input combinations.\nTo reflect the reviewer’s concern, we have added these experimental data in the\nrevised supplementary information. [Please see Supplementary Fig.22]\nWe have also added the following statement in the revised manuscript. [Please see\nlines 267-273, pages 11-12].\nTo further validate the scalability of the system for more complex logic computing\ntasks, we fabricated a two-bit adder consisting of four inputs (A , B , A , B ) and three\n1 1 2 2\noutputs (Q , Q , Q ). The experimental setup, truth table, and detailed operation\ncout S1 S2\nprocess are shown in Supplementary Fig. 22. The measured results for all sixteen\ninput combinations matched the theoretical truth table precisely, confirming the\ncorrectness, stability, and expandability of the light-programmable mechanical\ncomputing architecture.\n1-b Evaluate long-term operational stability under varying environmental\nconditions (light intensity variability, temperature, humidity). Present\nquantitative data with confidence intervals to validate reproducibility and\nrobustness.\nResponse: We thank the reviewer for this constructive suggestion. To directly address\nthis point, we systematically measured the long-term stability of our SPST relays\nunder varying light intensity, temperature, and humidity, and we provide\nquantitative results with 95% confidence intervals to validate reproducibility and\nrobustness.\nLight intensity. We varied the illumination from 40 to 310 mW/cm2 while maintaining\n29 ± 1 °C and 83 ± 3% RH. As shown in Fig. R8a, the response time decreased\nmarkedly from 1.04 ± 0.023 s at 130 mW/cm2 to 0.127 ± 0.010 s at 310 mW/cm2,\nwhereas the recovery time increased from 1.93 ± 0.045 s to 3.19 ± 0.133 s.\nTemperature. We next examined temperature effects under 130 mW/cm2 and 83 ± 3%\nRH. As shown in Fig. R8b, higher temperatures accelerated both actuation and recovery.\nAt 10 °C, the response and recovery times were 2.15 ± 0.044 s and 1.38 ± 0.058 s,\nrespectively, while at 30 °C they shortened to 1.04 ± 0.023 s and 1.93 ± 0.045 s. This\nacceleration is attributed to PNIPAm reaching its LCST more rapidly at elevated\ntemperatures.\nHumidity. We then investigated relative humidity effects at 130 mW/cm2and 29 ± 1 °C.\nAs shown in Fig. R8c, higher humidity slightly prolonged the response time but\nsignificantly shortened recovery. This is explained by the slower bond-breaking during\nactuation at higher RH, versus the faster rehydration and hydrogen-bond reformation\nthat accelerate recovery.\nDurability. Finally, we assessed long-term durability under 130 mW/cm2, 30 °C, and\n83 ± 3% RH. As shown in Fig. R8d, both response and recovery times remained stable\nover 600 continuous actuation–reset cycles, with negligible degradation.\nConclusion. Together, these results confirm that our devices deliver reproducible,\nrobust, and durable performance across diverse environmental conditions. This strongly\nsupports their feasibility for practical environment-adaptive computing applications.\nFig. R8. Environmental resilience and cycling stability of the SPST relay. a\nResponse and recovery times as a function of light intensity (40–310 mW/cm2) at 29 ±\n1 °C and 83 ± 3% RH. b Effect of ambient temperature (10–30 °C) on response and\nrecovery under 130 mW/cm2 and 83 ± 3% RH. c Influence of relative humidity (50–\n83% RH) on response and recovery under 29 ± 1 °C and 130 mW/cm2. d Cycling\nendurance test at 130 mW/cm2, 29 ± 1 °C, and 83 ± 3% RH, showing stable operation\nover 600 cycles with negligible degradation.\nTo reflect the reviewer’s concern, we have added these experimental data in the\nrevised supplementary information. [Please see Supplementary Fig.6]\nWe have also added the following statement in the revised manuscript.\n[Please see lines 182-184, page 8]\nThrough systematic experimental characterization, we demonstrated that the switching\ndynamics of the relays can be effectively tuned by both illumination intensity and\nenvironmental conditions (Supplementary Fig. 6).\n[Please see lines 188-190, page 8]\nIncreasing the illumination intensity to 310 mW/cm2 significantly reduced the SPST\nresponse time to 0.127 s, confirming that faster actuation can be achieved through\noptical optimization (Supplementary Fig.6).\n1-c The need for humidity-induced resetting is a practical limitation. Propose or\nprototype autonomous control mechanisms (e.g., embedded humidity feedback\nloops) to enhance practical relevance.\nResponse: We thank the reviewer for raising this important point regarding the need\nfor humidity-assisted resetting. To address this limitation, we designed and\ndemonstrated an autonomous control system. Specifically, a NOR gate was\nintegrated into the input section of signals A and B: when both inputs are “0,”\ncorresponding to the absence of light signals, the humidifier is automatically activated\nto reset the system; when either input is “1,” indicating active computation, the\nhumidifier remains off to avoid interfering with logic operations.\nAs shown in Fig. R9a (schematic) and Fig. R9b (photograph), this self-regulated reset\nstrategy allows the relay to autonomously control its recovery process. Supplementary\nMovie 10 further illustrates the operation of this mechanism during an AND gate\ncomputation, where the system successfully resets without manual intervention. This\ndesign directly addresses the reviewer’s concern by providing a practical pathway\ntoward autonomous control, thereby enhancing the real-world applicability of our light-\nprogrammable mechanical computing platform.\nFig. R9. Humidity control system. a Schematic of the humidity control system. A\nNOR gate is introduced to autonomously activate the humidifier when both input\nsignals (A, B) are “0,” enabling system reset. b Photographs showing the system reset\nprocess when input combinations (1,0), (0,1), and (1,1) transition to (0,0),\ndemonstrating the effectiveness of the autonomously controlled resetting mechanism.\nTo reflect the reviewer’s concern, we have added these experimental data in the\nrevised supplementary information. [Please see Supplementary Fig. 23, and Movie 10]\nWe have also added the following statement in the revised manuscript. [Please see\nlines 274-283, page 12]\nFinally, to enable autonomous operation of the constructed computing circuits, we\nfurther implemented an autonomously controlled resetting mechanism that allows self-\nregulated system recovery. As illustrated in Supplementary Fig. 23, when both optical\ninputs were “off,” an integrated humidity-control module was automatically activated\nto reset the relay, restoring its initial state for subsequent computation. Once the optical\ninputs resumed, the module was deactivated, allowing normal operation to continue,\nwith experimental validation provided in Supplementary Movie 10. This\nautonomously controlled strategy ensures autonomous recovery without external\nintervention, thereby advancing the practical realization of self-sustaining, light-\nprogrammable mechanical computing systems.\n1-d The manuscript should discuss how the system's switching speeds (currently\naround 1 second per logic operation) could be optimized or how it could interface\nwith conventional computing systems despite its slow speed.\nResponse: We thank the reviewer for this insightful suggestion. The switching speed\nof our system can indeed be further optimized through two complementary\nstrategies. First, increasing the input light intensity significantly accelerates relay\nresponse. At ~130 mW/cm2 (comparable to natural sunlight), the relay exhibits a\nresponse speed of ~1 s per operation. When the light intensity is increased to 310\nmW/cm2, the response time is reduced to 0.127 s, as shown in Fig. R8a. Second,\nreducing the height difference between the two electrodes decreases the required\nbending deformation, further enhancing switching speed. In the current setup, the\nelectrode offset is ~0.7 mm, yielding a response time of ~1 s. With advanced MEMS\nfabrication techniques, this offset could feasibly be reduced to ~70 μm, which we\nestimate would shorten the response time to the order of ~100 ms.\nRegarding the potential interface with conventional computing systems, we envision\nour approach serving as an environment-interactive sensing–computing module.\nUnlike traditional sensors, which only transduce signals, our system inherently\nintegrates sensing and computation within a distributed mechanical framework,\nproviding robustness against environmental variability. Such hybrid integration could\ncomplement conventional electronics by enabling intelligent environmental\nperception while maintaining compatibility with established digital architectures.\nTo reflect the reviewer’s concern, we have added the following statement in the\nrevised manuscript [Please see lines 340-344, page 14-15]\nMoreover, the relay-based framework can be seamlessly integrated with electronic\nsystems as an intelligent sensing-computation module. Unlike conventional sensors that\nmerely relay external signals, our distributed mechanical network intrinsically\nintegrates sensing and computation, providing adaptive functionality while maintaining\ncompatibility with digital logic architectures.\n2. Quantitative Analysis and Theoretical Modeling\nThe lack of quantitative analysis weakens the manuscript's scientific rigor:\n2-a Provide detailed measurements of light intensity (mW/cm), power\nconsumption per switching event, and thermal response curves.\nResponse: We thank the reviewer for this valuable suggestion. To strengthen the\nscientific rigor of the manuscript, we performed additional quantitative\nmeasurements and provided detailed analysis of light intensity, power consumption\nper switching event, and thermal response.\n1) Power consumption per switching event.\nThe energy consumption was calculated using the following procedure:\na. The incident light energy 𝐸 was obtained from the product of light intensity\nin\n(I ), illuminated area (A ), and illumination duration (t).\ndensity spot\n𝐸 = 𝐼 ×𝐴 ×𝑡\n𝑖𝑛 𝑑𝑒𝑛𝑠𝑖𝑡𝑦 𝑠𝑝𝑜𝑡\nb. The absorbed light energy 𝐸 was derived from 𝐸 ×(1−10−𝐴), where 𝐴 is\nabs 𝑖𝑛\nthe optical absorbance at 650 nm (0.281 for the PCF)1.\nFor instance, under 130 mW/cm2 illumination with an active area of 0.4 cm × 0.59 cm\nand a response time of 1.04 s, the calculated energy consumption per switching event\nis 15.2 mJ. When the illumination is increased to 310 mW/cm2, the faster response\nreduces the energy per event to 4.23 mJ. A comprehensive summary of the calculated\noptical power consumption across different light power densities is provided in Fig.\nR10a.\n2) Thermal response\nWe further recorded the thermal dynamics of the PCF under continuous illumination\n(Fig. R10b). At 130 mW/cm2, the film temperature exceeded the lower critical solution\ntemperature (LCST) within 0.05 s, reaching 38 °C, and further increased to 48.8 °C at\n1 s. At 310 mW/cm2, heating was more rapid, with temperatures rising to 78.5 °C within\n1 s and reaching 101 °C at 1.65 s.\nThese quantitative results directly address the reviewer’s concern and enhances the\nscientific rigor of the manuscript.\nFig. R10. Power consumption and thermal response of the PCF. a Power\nconsumption per switching event under different light intensities. b Thermal response\nof the PCF (PDMS/Ag NWs/PANi–PNIPAm) under different light power intensities\nwithin 5 s of illumination.\nTo reflect the reviewer’s concern, we have added these experimental data in the\nrevised supplementary information. [Please see Supplementary Figs. 3-4]\nWe have also added the following statement in the revised manuscript. [Please see\nlines 117-119, page 5]\nDetailed experimental results of this light-thermal-mechanical-electrical transduction\ncharacteristics are provided in Supplementary Fig. 3-4.\n2-b Develop numerical models or simulations that describe the photothermal-to-\nmechanical-to-electrical transformation. Suggested approaches include:\n1) Thermal conduction models combined with beam deformation theories.\n2) Dynamic simulations of switching delays, rise times, and potential operating\nfrequency limits.\nResponse: We thank the reviewer for the insightful comments. In response, we\ndeveloped a finite element simulation framework to quantitatively model the\nphotothermal-mechanical-electrical conversion process in our relay. The model\nintegrates two key components: (1) a heat transfer module to capture the spatial–\ntemporal evolution of the temperature field under optical illumination, and (2) a thermo-\nmechanical deformation module based on beam theory to describe light-induced\nbending and electrode contact.\n1) Heat Transfer Model\nFor simplicity, the intermediate microlayer (Ag NWs layer) was neglected in the\nsimulations since its thickness is more than an order of magnitude smaller than that of\nthe upper and lower films (The thicknesses of the PDMS/Ag NWs/PANI-PNIPAm film\nare 70 µm, 5 µm, and 134 µm, respectively). The optical absorption and heat transport\nwere simulated by coupling the Radiation in Absorbing Media and Heat Transfer in\nSolids modules. Optical energy was converted into a volumetric heat source via the\nBeer–Lambert law, and the transient heat conduction equation was solved:\n∂𝑇\n𝜌𝐶 +∇⋅(𝑘∇𝑇) = Q\n𝑝 ∂t\nwhere ρ, C , and k are the density, specific heat capacity, and thermal conductivity,\np\nrespectively.\nThe volumetric heat source 𝑄 is determined by\n𝑄 = 𝜂𝜇 𝐼\n𝑎\nwhere 𝜇 is the optical absorption coefficient, 𝐼 is the light intensity, and 𝜂 is the\n𝑎\nphotothermal conversion efficiency.\n2) Thermo-Mechanical Deformation Model\nThe thermally induced bending was modeled using a fixed-end cantilever beam\napproximation. The beam is treated as an elastic solid, whose deformation and stress\nresponse follow solid mechanics theory. The governing equations consist of the\nequilibrium equation (momentum conservation), the geometric relation (strain–\ndisplacement relation), and the constitutive relation (stress–strain relation with thermal\neffects). The deformation follows linear elasticity theory, governed by the Equilibrium\nequation:\n𝛻 ·𝝈 + 𝑭 = 𝜌 𝜕2𝒖/𝜕𝑡2\n𝑣\nWhere 𝝈 is the stress tensor, 𝑭 is the body force vector (neglected in this model), ρ\nv\nis the material density, and 𝒖 is the displacement vector (m).\nConsidering small deformations, the small-strain assumption is adopted and the\nstrain-displacement relation:\n𝝐 = 1/2 [𝛻𝒖 + (𝛻𝒖)ᵀ]\nwhere 𝝐 is the small strain tensor (dimensionless). The stress–strain relation under\nthermoelastic deformation is written as:\n𝝈 = 𝐂 ∶ (𝝐 − 𝝐 )\n𝑡ℎ\nwhere 𝐂 is the elastic stiffness tensor, which for isotropic materials is characterized by\nthe Young's modulus E and Poisson's ratio ν. 𝝐 is the thermal strain tensor\n𝑡ℎ\n(dimensionless).\nThe thermal strain is given by:\n𝝐 = 𝛼 (𝑇 − 𝑇 ) 𝑰\n𝑡ℎ 𝑟𝑒𝑓\nHere, 𝛼 is the coefficient of thermal expansion, 𝑇 is the current temperature,\n𝑇 is the reference temperature (material's initial temperature), and 𝐈 is the identity\n𝑟𝑒𝑓\ntensor.\n3) Modeling Parameters\nPDMS: Elastic modulus = 2 MPa; Poisson’s ratio = 0.49; thermal conductivity = 0.15\nW·m-1·K-1; density = 970 kg·m-3; specific heat capacity = 1460 J·kg-1·K-1; coefficient\nof thermal expansion = 5.67 × 10-4 K⁻¹.\nPANI–PNIPAm: Elastic modulus = 1 MPa; Poisson’s ratio = 0.49; thermal\nconductivity = 0.6 W·m⁻¹·K⁻¹; density = 1200 kg·m⁻³; specific heat capacity = 2100\nJ·kg⁻¹·K⁻¹; coefficient of thermal expansion = 0 below 32 °C and −1 × 10-6 K⁻¹ above\n32 °C.\nBased on these parameters, finite element simulations were conducted to model\nthe coupled photo–thermal–mechanical–electrical transformation process in the relay,\ncapturing the temperature evolution, induced deformation, and subsequent electrical\ncontact behavior.\nSimulations show that under 130 mW/cm2 illumination, the film temperature\nexceeded the LCST within 0.05 s and reached ~45.7 °C at 1 s (Fig. R11a, Movie 4).\nThe transient temperature rise at the film center is presented in Fig. R11c.\nThe simulated bending profile under 130 mW/cm2 illumination at t = 1 s is shown\nin Fig. R11b, and the corresponding dynamic displacement of the beam end is provided\nin Movie 4. The time-dependent displacement curve in Fig. R11d further confirms that\nelectrode contact occurs after approximately 1 s.\nFig. R11. The simulation results of Heat Transfer Model and Thermo-Mechanical\nDeformation Model. a Simulated temperature distribution across the suspended film\nat t =1s under optical illumination (130 mW/cm2). b Simulated displacement\ndistribution of the beam end under optical illumination (130 mW/cm2), indicating\nbending deformation. c Transient evolution of the center-point temperature of the film,\nshowing heating dynamics under 130 mW/cm2 illumination. d Time-dependent\ndisplacement of the beam end under 130 mW/cm2 illumination, where contact with the\nelectrode occurs after ~1 s.\nDynamic simulations of switching delays, rise times, and potential operating\nfrequency limits.\nResponse: We thank the reviewer for raising this important point. Our analysis shows\nthat the dominant delay arises from thermo-mechanical deformation of the film,\nwhereas the RC delay of the circuit is negligible. Under fixed relay geometry (film\nlength, electrode height difference, and material composition), both experiments and\nsimulations demonstrate a strong dependence of response time on illumination intensity\n(Fig. R12). Experimentally, the response time decreases with increasing light power\nand saturates at ~0.127 s under 310 mW/cm2 illumination, corresponding to a practical\nupper operating frequency of ~7.9 Hz. Finite-element simulations further reveal\nsaturation above ~300 mW/cm2, with a minimum response time of ~0.07 s at 350\nmW/cm2, yielding a theoretical frequency limit of ~14.3 Hz.\nThese results provide clear quantitative benchmarks for the dynamic switching\ncapability of our system. Importantly, the operating speed can be further improved by\noptimizing relay geometry (e.g., reducing film dimensions or electrode height\ndifference) or by employing alternative materials with faster thermo-mechanical\nresponse.\nFig. R12. Simulated and experimental results of response time as a function of input\nlight power density.\nTo reflect the reviewer’s concern, we have added numerical simulations in the revised\nsupplementary information. [Please see Supplementary Note 2, Supplementary Figs.\n9-10, and Movie 4]\nWe have also added the following statement in the revised manuscript. [Please see\nlines 206-213, page 9]\nTo further elucidate the underlying mechanism, we quantitatively analyzed the\ncoupled photo-thermal-mechanical-electrical processes based on a thermal conduction\nmodel and beam deformation theory (Supplementary Note 2, Supplementary Figs.\n9-10, and Movie 4). The analysis reveals how light-induced photothermal conversion\npropagates through heat conduction to drive mechanical deformation, thereby\nmodulating the conductive pathways and enabling controllable signal transmission.\nThese insights provide theoretical guidance for the design and optimization of light-\nprogrammable mechanical computing architectures.\n2-c Generate multivariate plots correlating light intensity, temperature, curvature,\nand conductivity to support mechanistic insights.\nResponse: We thank the reviewer for the constructive suggestion. In response, we\ngenerated multivariate plots that quantitatively correlate light intensity, surface\ntemperature, bending curvature, and electrical conductivity of the polyaniline\ncomposite film (PCF).\nIn the experiments, PCFs were exposed to different light intensities for 5 s. As shown\nin Fig. R10b, increasing light intensity leads to a monotonic rise in surface temperature,\nwhich directly drives photothermal expansion and contraction of the bilayer structure.\nThis temperature rise results in enhanced bending deformation, reflected by smaller\ncurvature radii (Fig. R13). At the same time, bending deformation induces a measurable\ndecrease in electrical conductivity, confirming a strong coupling between mechanical\nand electrical responses.\nThese quantitative correlations provide direct mechanistic evidence for the\nphotothermal-to-mechanical-to-electrical transduction process and establish a solid\nbasis for further device optimization, response-time prediction, and multiphysics\nmodeling.\nFig. R13. Curvature radius and conductivity changes of the PCF after 5 s\nillumination at different light intensities.\nTo reflect the reviewer’s concern, we have added numerical simulations in the revised\nsupplementary information. [Please see Supplementary Fig. 4]\nWe have also added the following statement in the revised manuscript. [Please see\nlines 117-119, page 5]\nDetailed experimental results of this light-thermal-mechanical-electrical transduction\ncharacteristics are provided in Supplementary Fig. 3-4\n3. Comparison with Related Technologies\nThe current comparisons with existing work are largely qualitative and\ninsufficient. Strengthen this section by:\na Including a quantitative benchmark table comparing key performance metrics\n(e.g., switching time, power consumption, scalability, environmental resilience)\nwith other stimuli-responsive systems (thermal, magnetic, pressure, optical).\nb Specifically reference and compare with:\nEl Helou et al., Nat. Commun. 2022\nByun et al., Nat. Commun. 2024\nMei et al., Nat. Commun. 2021 on mechanical metamaterial computing\nRecent reviews on mechanical metamaterials (e.g., APL Electronic Devices 2025)\nc Discuss the trade-offs between mechanical computing using metamaterials\nversus the present material-based approach, focusing on:\nSwitching speed and delay\nManufacturing complexity and scalability\nReconfigurability and environmental responsiveness\nResponse: We sincerely thank the reviewer for the constructive suggestions. To\nstrengthen the comparison section, we prepared a quantitative benchmark table\n(Table R1) that systematically compares the key performance metrics of our material-\nbased system, including switching time, energy consumption, scalability, and\nenvironmental resilience, with representative stimuli-responsive logic platforms such\nas mechanical, magnetic, electrical, thermal, and optical systems. The table also\nincorporates the related works highlighted by the reviewer (El Helou et al., Nat.\nCommun. 2022; Byun et al., Nat. Commun. 2024; Mei et al., Nat. Commun. 2021; and\nrecent reviews on mechanical metamaterials in APL Electronic Devices 2025),\nensuring a direct and transparent quantitative comparison.\nTrade-off analysis:\nTo further clarify the distinction between metamaterial-based mechanical computing\nand our material-based approach, we analyzed the following trade-offs as suggested by\nthe reviewers:\n1) Switching speed and delay.\nMetamaterial systems are slow, whereas material-based systems are\nconsiderably faster and have clear potential for further acceleration.\nMetamaterial logic typically operates on the scale of seconds to minutes (for example,\n2–3 s for rotating blocks2, 3, 5–20 s for hydrogel gates4, approximately 27 s for\nelectrically driven systems5, and up to 80 minutes for thermal adders6). These delays\nare mainly caused by inertia and elastic recovery, which make sub-second operation\nextremely difficult. In contrast, our system leverages light–thermal–mechanical\ncoupling to achieve sub-second switching (0.127 s at 310 mW/cm2, Fig. R8),\nrepresenting at least an order-of-magnitude improvement compared with most\nmetamaterial systems. With further device scaling, the response time could be reduced\nto the millisecond regime.\n2) Manufacturing complexity and scalability.\nMetamaterial approaches allow intuitive prototyping but face serious\nlimitations in scaling, while material-based systems are inherently suitable for\nintegration and large-scale architectures but demand advanced fabrication\nprecision.\nMetamaterials are usually fabricated through 3D printing or modular assembly. This\napproach is convenient for proof-of-concept demonstrations but generally produces\nbulky centimeter-scale arrays with low integration density and limited scalability. Our\nthin-film strategy, in contrast, is intrinsically compatible with miniaturization,\nmultilayer stacking, and wafer-scale integration. For instance, we demonstrated a 2-bit\nadder, highlighting the feasibility of scalable circuit design, although precise fabrication\nand strict material uniformity are still required.\n3) Reconfigurability and environmental responsiveness.\nMetamaterial-based systems offer convenient fabrication but limited\nadaptability due to their reliance on predefined structures, whereas material-\nbased systems enable stimulus-driven reconfigurability with higher adaptability\nat the cost of increased fabrication complexity.\nIn metamaterial systems, reconfigurability is typically achieved through geometric\nmultistability, such as folding, rotation, or compression. Most reported systems rely on\nexternal mechanical resetting, which leads to slow response and poor adaptability to\nmultiple stimuli. In contrast, our material-based devices exploit the intrinsic sensitivity\nof functional materials to light, temperature, and humidity, enabling dynamic\nreconfiguration of information processing behaviors. The devices maintain stable\noperation over more than 600 switching cycles, confirming their reproducibility and\ndurability. Nevertheless, the practical implementation of this technology relies on\ndeveloping highly uniform, responsive composite films and precision mechanical\nfabrication techniques, which remain essential challenges for large-scale applications.\nTo reflect the reviewer’s concern, we have added Table R1 in the revised\nsupplementary information. [Please see Supplementary Note 7, Table 3]\nWe have also added the following statement in the revised manuscript. [Please see lines\n335-340, page 14]\nBeyond functional demonstration, this study highlights a conceptual advance in\nenvironment-interactive intelligence enabled by light-programmable mechanical\ncomputing. Compared with conventional metamaterial-based mechanical computing,\nour approach leverages material-level programmability and thin-film integration to\nachieve higher switching speed, scalability, and multi-stimulus adaptability (see\nSupplementary Note 7, Tables 2-3).\nTable R1. Quantitative Benchmark of Key Performance Metrics for Stimuli-Responsive Logic Systems\nExternal Stimuli Switching Time Power Consumption Scalability Environmental Resilience Ref.\nMechanical force 2 s (movie Zero static power Seven fundamental logic gates: AND, OR, XOR, N/A El Helou2\nestimate) NOT, NAND, NOR, NXOR;\nlogic gate combination OR-NAND, NOR-AND,\nOR-AND, and AND-NAND\nMechanical force 2 s (movie Zero static power Seven fundamental logic gates: AND, OR, XOR, N/A El Helou3\nestimate) NOT, NAND, NOR, NXOR;\n2-bit Adder/Subtractor/Multiplier;\n4-bit Magnitude Comparator\nMechanical force 5 to 20 s (movie Zero static power NOT, AND, OR; N/A Byun4\nestimate) Supports cascaded logic (e.g., 3-level\nAND/OR/NOT networks)\nMechanical force 2 to 3 s (movie Zero static power AND, OR, NOT; Full Adder; Operates at -20°C for >24 hours Wu7\nestimate) Cascading of multiple (7) adders\nMechanical force N/A Self-powered (Power Six basic logic gates (AND, OR, XOR, NAND, N/A Zhang8\ngeneration: 4.35 nW) NOR, XNOR)\nfull adder;\n3-bit ternary computing\nElectromagnet 2 to 3 s (movie Zero static power NOR, NAND, NOT, OR, AND; Half adder; N/A Mei9\nestimate) 3D printable at multiple scales (macro to micro)\nMagnetic 2 to 10 s (movie Zero static power AND, OR Field Strength (B): -85 to 85 mT Pal10\nestimate)\nMagnetic or 1 to 2 s (movie Zero static power AND, OR, NOR, NAND； Compression: Withstands 2.8 kPa Li11\nmechanical estimate) Maximum demonstrated: 30 × 27 unit array pressure at 2% strain\nSolvents 0.6 to 108 s Zero static power AND, OR, NAND; Operates in liquid environments Jiang12\n(toluene and (water/toluene)\nwater) Reusable after 70min drying\nHumidity N/A Zero static power SR Latch, AND, OR; Operates in 0-85% RH range; Treml13\nMajority Gate; 5 cycles\nElectrical 27.2 s 5.5 W (1-bit system) 1-bit (T flip-flop); 2-bit (counter); N/A El Helou5\n7.4 W (8-bit solver) 8-bit (equation solver)\nThermal Time Constant Zero static power NOT, AND, OR, XOR; continuous operation over 1000 min; Chen6\n():160 minutes SR Latch; Full adder Vacuum-compatible\nVibration <1 s delay Zero static power AND, OR, XOR, NOT, NAND, NOR, NXOR; Signal Leakage (OFF state): < 10% of R. Bilal14\nHalf Adder; max signal;\nFull Adder Signal Clarity (ON/OFF difference): >\nmW/cm2)\nLight 12 s (379.7 mW) Zero static power AND, OR, NOT; 500 cycles Wang16\nSoft optical switch array\nLight 1.04 s (130 Zero static power AND, OR, NOT, XOR; Light intensity: 70–310 mW/cm2; This\nmW/cm2) 2-bit Adder; Humidity: 47–86% RH\n0.127 s (310 Temperature: 10–30 °C; Work\nmW/cm2) Cycles: 600\n4. Mechanical Durability and Reversibility\nThe claims regarding mechanical reversibility under humidity changes require\nexperimental validation:\na Provide visual documentation (images or videos) and quantitative graphs\ndemonstrating reversibility and mechanical recovery.\nb Assess durability over multiple actuation cycles to ensure practical feasibility for\nrepetitive logic operations.\nResponse: We sincerely thank the reviewer for this valuable suggestion. To directly\nvalidate the claims of humidity-assisted mechanical reversibility and long-term\ndurability, we conducted additional experiments, summarized as follows:\n1) Direct visualization. Two supplementary movies were added. Movie 2 shows that\nunder 310 mW/cm2 illumination, the PCF actuator bends and then fully recovers in 83\n± 3% RH. Movie 3 demonstrates the SPST relay operation: under 130 mW/cm2\nillumination, the relay bends to switch on a blue LED (“logic 1”) and subsequently\nrecovers under high humidity. These results confirm that humidity accelerates recovery\nand enables fully reversible deformation.\n2) Quantitative analysis. We systematically measured response and recovery times of\nthe SPST relay under 50 ± 3%, 65 ± 3%, and 83 ± 3% RH (Fig. R14a–c). With higher\nhumidity, the response became slightly slower, but recovery was markedly faster.\nFor example, at 50 ± 3% RH, the average response/recovery times were ~0.5 s / 4.9 s,\nwhile at 83 ± 3% RH they shifted to ~1.04 s / 1.92 s (the average of 50 measurements).\nThese results highlight humidity as a key factor governing mechanical reversibility.\n3) Durability. To assess long-term performance, we tested 600 continuous actuation–\nrecovery cycles of the SPST relay at 29 ± 1 °C and 83 ± 3% RH (Fig. R14d). The device\nrelay exhibited stable response and recovery throughout, without detectable fatigue or\nirreversible deformation, demonstrating excellent mechanical durability.\nConclusion. These results provide clear experimental evidence that high humidity\nfacilitates reversible recovery and ensures long-term durability, thereby confirming the\npractical feasibility of the relay for repeated logic operations.\nFig. R14. Humidity-assisted reversibility and cycling stability of the SPST relay.\na–c Response and recovery dynamics at different relative humidity levels for 50 cycles\n(50 ± 3%RH, 65 ± 3%, and 83 ± 3% RH). d Cycling endurance over 600 actuation–\nrecovery cycles under illumination of 130 mW/cm2 at 29 ±1°C and 83 ± 3% RH.\nTo reflect the reviewer’s concern, we have added Movies 2-3 and Fig. R14 in the\nrevised supplementary information. [Please see Supplementary Fig. 8, Movies 2-3]\nWe have also added the following statement in the revised manuscript:\n[Please see lines 119-121, page 5]\nWe further demonstrated that the light-induced deformation of the PCF is fully\nreversible by adjusting the ambient humidity (Supplementary Movie 2, and\nmechanism described in Supplementary Note 1).\n[Please see lines 157-161, page 7]\nThe logical operation of the SPST relay and its reset mechanism under varying humidity\nconditions are demonstrated in Movie 3. Through this experiment, we achieved light-\nprogrammable on/off switching of a single conductive pathway, thus realizing the SPST\nrelay function.\n[Please see lines 195-205, pages 8-9]\nThe relays also exhibited excellent mechanical reversibility and long-term operational\nstability. To evaluate their robustness under varying humidity, we measured the\nresponse and recovery characteristics of the SPST relay (Supplementary Fig. 8a–c).\nAs humidity increased, the response time showed a slight delay, whereas the recovery\ntime was markedly accelerated, confirming stable and reliable recovery behavior\nacross all humidity levels. Moreover, the SPST relay maintained consistent\nperformance over more than 600 continuous actuation – reset cycles without\nobservable fatigue or degradation (Supplementary Fig. 8d). These results collectively\ndemonstrate the high reliability and robustness of the relays, establishing them as ideal\nbuilding blocks for constructing light-programmable mechanical computing systems.\n5. Clarity and Depth in Application Demonstration\nThe adaptive camouflage demonstration is conceptually interesting but technically\nunderdeveloped:\na Clarify whether Figure 4c represents experimental data or simulation.\nb Detail the environmental texture sensing mechanism, the source of image data,\nand the electronic or material response pathway leading to pattern change.\nc Expand the camouflage section to provide a coherent use-case scenario and\npotential performance benchmarks.\nResponse: We sincerely thank the reviewer for the insightful comments. Our responses\nare as follows:\n1) Clarification of Figure 4c\nFigure 4c presents simulation results based on experimentally characterized\ndevice behavior rather than direct experimental measurements. Large-scale texture\nacquisition under real environmental conditions remains experimentally challenging;\nnevertheless, the simulation faithfully reproduces the system’s measured response. To\nfurther substantiate the capability of environmental texture perception and camouflage\nimage generation demonstrated in Figure 4 of the manuscript, we have supplemented\nexperimental fabrication and testing of the designed unit, validating its functional\noperation as designed, as shown in Fig. R1.\n2) Environmental texture sensing and response mechanism\nImage source: The environmental images were generated by artificial intelligence for\nsimulation purposes. These images were subsequently converted into binary patterns\nusing the Floyd–Steinberg dithering algorithm. This algorithm distributes the grayscale\nintensity across neighboring pixels such that the local density of pixels with a value of\n1 effectively represents the original grayscale level in that region. As a result, local\nintensity variations are preserved, enabling our binary sensing units to capture the\nessential spatial features of the images while operating in a fully binary framework.\nSensing–Computation–Emission (SCE) Process: In the SCE unit, three single-pole\nsingle-throw (SPST) relays detect optical signals from a 3×3 region of the input image\n(Fig. R15 a(i)) and transmit the sensed information to three AND logic circuits\nconstructed from SPST relays (Fig. R15 a(ii)). The circuit generates a total of nine\nelectrical outputs, consisting of two signals from each AND logic circuit and three\ndirect outputs from the SPST relay sensors. These signals drive a 3×3 light-emitting\narray, where the on/off states of the bulbs reproduce the luminance distribution pattern\nof the input image (Fig. R15 a(iii)). Fig. R15b presents the spatial distribution of the\nsensed optical input signals (P , P , and P ) and the corresponding output signals(Q ,\n1 2 3 11\nQ , …, Q ) within the SCE unit, along with the logical relationships linking the inputs\n12 33\nto their respective outputs. In this way, the 3 × 3 light array reproduces the local optical\npattern detected by the SPST-based photoreceptive units, completing the sensing-\ncomputation-emission cycle.\nFig. R15. The illustration of the sensing-computation-emission (SCE) process. a\nProcess of texture camouflage: The optical information is sensed by single-pole single-\nthrow (SPST) relays (i) within the SCE unit (ii) and subsequently processed through an\nAND logic operation to generate control signals that drive a 3 × 3 light bulb array (iii).\nb The spatial distribution of the sensed optical input signals (P , P , and P ) and the\n1 2 3\ncorresponding output signals (Q , Q , …, Q ) in the SCE unit, as well as the logical\n11 12 33\nrelationships between the input and output signals.\n3) Application scenario and performance benchmarks\nApplication scenario: Our adaptive camouflage system is inspired by the dynamic\ntexture changes of cephalopod skin. For instance, octopuses adjust their skin patterns\nin response to coral, rock, or sand backgrounds to evade predators and capture\nprey. Similarly, our system could be applied to underwater autonomous vehicles,\njungle camouflage vehicles, or other devices requiring real-time environmental\nadaptation.\nperformance benchmarks: In practical applications, variations in temperature,\nhumidity, or external mechanical damage may result in local failure of individual units,\nwhich could potentially impair camouflage fidelity. To provide an initial assessment\nwithin the scope of this work, we introduced a simplified assumption: environmental\nperturbations are modeled as random damage to a certain percentage of\nfunctional units, causing them to lose their emissive capability. Benefiting from the\ndistributed nature of sensing-computation-emission in our design, such localized\nfailures do not propagate to the system level.\nTo verify this assumption, we simulated camouflage patterns under progressively\nincreasing damage ratios and quantitatively assessed their fidelity using a robust\ntexture similarity metric that combines frequency-domain feature comparison with\nstructural similarity evaluation (Fig. R16). The results demonstrate that even when a\nconsiderable fraction of units fail, the camouflage images retain a high degree of\nsimilarity to the target textures, highlighting the inherent robustness of the approach.\nWe agree that further studies incorporating detailed environmental mechanisms and\nexperimental validations are essential, and we envision this as an important direction\nfor our future work.\nFig. R16. Robustness characteristics of the camouflage system. a Comparison\nbetween original images and camouflaged outputs as the proportion of randomly\ndamaged unit structures increases from 0% to 100%. b Quantitative analysis of image\nsimilarity between original and generated images at different damage levels, with the\nx-axis representing damage proportion and the y-axis showing texture similarity. We\nmeasured the similarity between the original environmental texture and the generated\ncamouflaged image using a multi-feature metric that integrates spatial descriptors\n(gray-level co-occurrence matrices, local binary patterns) and frequency-domain\ndescriptors (radial power spectral density, angular energy distribution). Each descriptor\nis normalized and combined to produce a composite similarity score ranging from 0 (no\nsimilarity) to 1 (identical).\nTo address the reviewer’s concern, we have added a detailed description of texture\nsensing and response mechanism in the revised supplementary information. [Please see\nSupplementary Note 6]. Additionally, we have added Fig. R16 in the revised\nsupplementary information. [Please see Supplementary Fig. 25]\nWe have also added the following statement in the revised manuscript.\n[Please see lines 294-303, page 13]\nIn the SCE unit, three single-pole single-throw (SPST) relays detect optical signals from\na 3×3 region of the input image (Fig. 4a(i)) and transmit the sensed information to\nthree AND logic circuits constructed from SPST relays (Fig. 4a(ii)). The circuit\ngenerates a total of nine electrical outputs, consisting of two signals from each AND\nlogic circuit and three direct outputs from the SPST relay sensors. These signals drive\na 3×3 light-emitting array, where the on/off states of the bulbs reproduce the luminance\ndistribution pattern of the input image (Fig. 4a(iii)). Detailed circuit configuration and\noperation principles are provided in Supplementary Note 6.\n[see lines 321-334, page14]\nWe further analyzed the robustness of system when exposed to environmental\ndisturbances, such as variations in temperature, humidity, and mechanical stress.\nThese factors may induce local failure in individual units, potentially leading to errors\nin the camouflage output. To assess this effect, environmental perturbations were\nmodeled as random damage to a given proportion of functional units, which\nconsequently lose their emissive capability. Due to the distributed design of the SCE\nframework, such local failures do not propagate across the system, thereby preserving\nglobal functionality. To quantitatively evaluate this robustness, we simulated\ncamouflage performance under increasing levels of unit damage and analyzed image\nfidelity using a comprehensive texture similarity metric that integrates spatial and\nfrequency-domain descriptors (Supplementary Fig.25). The analysis reveals that\neven when a substantial fraction of units becomes nonfunctional, the camouflage\nimages maintain high structural similarity to the target textures. This result highlights\nthe intrinsic fault tolerance and resilience of the proposed design.\n6. Material Selection Justification\nProvide quantitative rationale for the selection of PANi, PNIPAm, PDMS, and Ag\nNWs:\n6-a Include photothermal conversion efficiency measurements or references.\nResponse: We thank the reviewer for the valuable suggestion. To clarify the rationale\nbehind our material selection, we provide a quantitative justification for each\ncomponent in the PANi–PNIPAm/PDMS–Ag NWs hybrid system (summarized in\nTable R2). These materials were deliberately chosen to ensure efficient photothermal-\nto-mechanical transduction, environmental adaptability, and robust device performance.\nPANi was selected as the photoresponsive element because it efficiently absorbs red\nlight at 650 nm and achieves a photothermal conversion efficiency of 49.6%, enabling\neffective light-to-heat energy conversion.\nPNIPAm functions as the thermo-responsive layer17: below its LCST (32 °C),\nhydrogen bonding with water molecules maintains hydrated, swollen chains, whereas\nabove the LCST, dehydration and chain collapse occur due to hydrophobic interactions,\nleading to a discontinuous volume phase transition. Reported shrinkage ratios reach 7–\n10% (V/V₀)18, and rehydration under ambient humidity ensures reversibility after\nillumination is removed.\nAg NWs were incorporated to provide highly conductive pathways (electrical\nconductivity of 6.25 × 107 S/m)19 and strong thermal transport (thermal conductivity of\nheating.\nPDMS was selected for its relatively high thermal expansion coefficient (2.6-9.07 × 10-\nexpansion mechanically compensates the contraction of PNIPAm, stabilizing the\noverall deformation and ensuring controlled bending.\nCollectively, these components form a synergistic hybrid structure in which PANi\nensures efficient photothermal conversion, PNIPAm provides dynamic phase transition\nand environmental responsiveness, Ag NWs guarantee robust electrical conduction and\nheat dissipation, and PDMS contributes thermal expansion and mechanical stability.\nUnlike single-component systems, this rational integration enables both efficient\nenergy transduction and robust cycling stability, which are essential for advancing light-\nprogrammable mechanical computing.\nTo reflect the reviewer’s concern, we have added Table R2 in the revised\nsupplementary information. [Please see Supplementary Section Note 1, Table 1]\nAdditionally, we have also added the following statement in the revised manuscript.\n[Please see lines 99-100, page 5]\n(molecular structures in Supplementary Fig. 1; material properties detailed in\nSupplementary Table 1, synthesis procedures in Methods).\nTable R2. Quantitative justification for the material selection in the Ag\nNWs/PDMS/Ag NWs/PANi-PNIPAm hybrid system.\nThis table highlights the complementary roles of each component in ensuring efficient\nphotothermal-to-mechanical transduction, environmental responsiveness, and device\nstability. Importantly, the integration of these materials provides synergistic advantages\nthat conventional single-material systems cannot achieve, thereby enabling a robust\nplatform for light-programmable mechanical computing.\nMaterial Functionality Properties Reference\nPANi Light-responsive / photothermal 650 nm; Photothermal conversion Ref1\nconversion efficiency (): 49.6%\nPNIPAm Thermal contraction (phase- LCST = 32 ℃ Ref17, 18\nchange) phase-change temperature\nHumidity-Induced Swelling Volume shrinkage: 7%-10%\nAg NWs Conductive layer and heat- Electrical conductivity: 6.25 × 10⁷ Ref19, 20\nconductive layer S/m; Thermal conductivity: 429\nW/(m·K)\nPDMS Thermal expansion Thermal expansion coefficient: 2.6- Ref21, 22\n9.07 × 10-4 K-1\n6-b Compare with alternative materials for responsiveness, durability, and energy\nefficiency to strengthen the materials engineering contribution.\nResponse: We sincerely thank the reviewer for this valuable suggestion. To emphasize\nthe materials engineering contribution of our work, we conducted a comparative\nanalysis between our PCF (PDMS/Ag NWs/PANi–PNIPAm) actuator and\nrepresentative light-responsive actuating materials reported in the literature (Table R3).\nThe comparison is presented in terms of (1) responsiveness, (2) durability, and (3)\nenergy efficiency, as detailed below.\n1) Responsiveness\nMost previously reported photothermal actuators require tens of seconds to minutes\nto complete a single switching event (e.g., 2 min for CdS QDs15, ~40 s for fluorophore-\ngrafted PNIPAm23, and ~20 s for graphene QDs–PNIPAm²⁴). Even advanced\nnanocomposite systems such as CNT–LCE and MXene/PEDOT:PSS achieve response\ntimes of ~11–12 s16,25, but only under high light intensities.\nIn contrast, our PCF actuator exhibits a significantly accelerated response,\nachieving a rapid actuation time of 1.04 s under 130 mW cm-2 and an ultrafast\nresponse of 0.127 s under 310 mW cm-2. This represents an improvement of over two\norders of magnitude compared with state-of-the-art photothermal systems, confirming\nthe exceptional responsiveness of our materials design.\n2) Durability\nReported photothermal actuators typically demonstrate limited operational lifetimes,\nwith stable performance over 5–500 cycles before mechanical fatigue or irreversible\ndegradation occurs15, 16, 23, 24, 25. In comparison, our actuator maintains stable\nperformance over 600 cycles without notable performance decay, indicating superior\nmechanical robustness and excellent material durability.\n3) Energy Efficiency\nOur PCF system demonstrates a photothermal conversion efficiency (η) of 49.6%,\ndefined as the ratio between absorbed optical energy (E ) and the energy converted to\nabs\nheat (E ). While previous studies did not report η values, the incident energy density\nheat\n(Ed ) can be estimated from the light intensity and response time of each system.\nin\nEarlier photothermal actuators generally require very high light intensities (up to 5\nW/cm2)23 and large energy density inputs (>10 J cm-2, occasionally exceeding 100 J\ncm-2 per switching event)15, 23, 24. In sharp contrast, our system requires only 39.4 mJ\ncm-2 per switching event, which is several orders of magnitude lower than most\nreported systems, underscoring its outstanding energy efficiency.\nIn summary, these comparative analyses highlight the advantages of our materials\nengineering strategy, which synergistically combines PANi as a photothermal\ntransducer, PNIPAm for rapid and reversible phase transition, and PDMS for\nmechanical actuation. This integrated design achieves a unique combination of\nultrafast responsiveness, exceptional durability, and high energy efficiency,\nestablishing our PCF as a promising platform material for light-driven mechanical\ncomputing and adaptive intelligent devices.\nTo reflect the reviewer’s concern, we have added Table R3 in the revised\nsupplementary information. [see Supplementary Section Note 7, Table 2]\nTable R3. Comparison of selected materials with representative alternatives\nAlternatives Responsiveness Durability Incident Energy References\nenergy Efficiency\ndensity Ed\nin\nCdS QDs 2 min (100 mW/cm2 for 10 cycles 12-14.4 J/cm2 N/A Ref15\n365 nm;120 mW/cm2 for\n600-1200 nm）\nFluorophore-grafted 40 s (0.15-0.2 W/ cm2, 6 cycles 6-8 J/cm2 N/A Ref25\nP(NIPAM-co- 405/502/638 nm)\nallylamine)\nGraphene QDs- 20 s（5 W/ cm2, 808 nm) 5 cycles 100 J/cm2 N/A Ref23\nPNIPAm\nCNT-LCE 12 s (370.7 mW,1545 500 cycles 4.45 J/ cm2 N/A Ref16\nnm)\nMXene/PEDOT:PSS- 11.3 s (0.9 W/cm2 ,808 300 cycles 10.2 J/cm2 N/A Ref24\nIntegrated NIPAAM nm)\nPDMS/AgNWs/PANi– 1.04 s (130 mW/cm2, 650 600 cycles 39.4 mJ/ cm2 49.6% This work\nPNIPAm nm);\n0.127s (310 mW/cm2)\n7. Application Scope and Positioning The manuscript should clearly define the\ntarget applications:\na Given the slow switching speed, traditional computing applications are unlikely.\nPotential use-cases could include: Adaptive camouflage systems\nSoft robotic skin\nLow-frequency adaptive sensing\nb Clearly state the performance limitations and position the work accordingly\nwithin non-traditional computing.\nResponse: We thank the reviewer for the valuable comments on clarifying the\napplication scope and positioning of our work. We fully agree that the proposed\nplatform is not intended for traditional high-speed computing. Instead, its strengths lie\nin non-traditional computing scenarios where adaptability, environmental\nresponsiveness, and robustness are more critical than switching speed.\nAs the reviewer suggested, representative application domains include adaptive\ncamouflage systems, soft robotic skins, and low-frequency adaptive sensing. In fact,\nwe explicitly demonstrate an adaptive camouflage system in Fig. 4, where the relay\nautonomously senses ambient texture features and generates corresponding camouflage\npatterns. This proof-of-concept highlights the potential of our system to function as the\n\"skin\" of an intelligent agent that can perceive and adapt to diverse environmental\nconditions.\nAlthough the switching speed of our system is slower than that of conventional\nelectronic logic, such applications are inherently tolerant to response times on the order\nof seconds. The key challenges for future development lie not in speed but in\nenhancing operational stability and robustness in open environments, and in\nimproving the fidelity of texture reproduction for realistic camouflage.\nBy clearly positioning our work within the framework of environment-adaptive, non-\ntraditional computing, we aim to emphasize its relevance to emerging application areas\nthat demand distributed sensing-actuation-computation integration rather than\nultrafast performance.\nWe have followed the reviewer’s suggestion to add more discussion about application\nscope and positioning in the revised manuscript. For ease of reviewing, we have\nprovided the revision below:\n[Please see lines 190-194, page 8].\nAlthough the typical switching times remain on the order of seconds, such timescales\nare well suited for adaptive camouflage, environmental sensing, soft robotics, and low-\nfrequency logic applications, where reversibility, adaptability, and energy efficiency are\nprioritized over ultrafast response.\n[Please see lines 286-293, page 12].\nBuilding on the demonstrated light-programmable logic computing capability, we\ndeveloped an adaptive texture camouflage system inspired by cephalopods such as\noctopuses and cuttlefish, which actively modulate their skin textures to blend into\nnatural surroundings like corals, rocks, and sand. Analogously, our artificial system\nwas designed to sense environmental optical cues and dynamically reconstruct texture\npatterns, offering potential applications in autonomous underwater vehicles,\nreconnaissance robots, and other intelligent systems requiring real-time environmental\nadaptability.\n8. Manuscript Presentation and Communication Style The current narrative is\ndescriptive and material-focused; for Nature Communications, a sharper,\nproblem-solving storyline is recommended:\na. Adopt a “One Figure = One Key Message” approach to improve clarity.\nb. Refine the Introduction and Conclusion to clearly state:\nWhat problem is being solved?\nWhat new possibilities this enables?\nc. Condense and sharpen key findings to maximize readability and impact.\nResponse: We thank the reviewer for this valuable suggestion. In the revision, we\nreorganized the figures following a “one figure = one key message” principle and\nrefined both the Introduction and Conclusion to explicitly state the problem addressed,\nthe new possibilities enabled, and the key findings in a more concise and impactful\nmanner. These changes substantially improve clarity and align the manuscript with the\ncommunication style of Nature Communications.\nFinal Recommendation\nThis manuscript presents an innovative concept of light-programmable\nmechanical logic with potential applications in adaptive systems and soft robotics.\nHowever, substantial improvements in quantitative rigor, theoretical modeling,\ndurability assessment, and presentation style are required to meet the impact,\nscientific depth, and clarity expected by Nature Communications. I recommend\nmajor revision and reassessment upon thorough addressing of the points above.\nAlternatively, the authors may consider submission to specialized journals in\nsmart materials, soft electronics, or mechanical computing, where the current level\nof novelty and rigor may be more appropriate\nResponse: We sincerely thank the reviewer for the constructive evaluation and\nthoughtful recommendation. We fully acknowledge the importance of enhancing\nquantitative rigor, theoretical modeling, durability analysis, and presentation style. In\nthe revised manuscript, we have carefully addressed each of these aspects by adding\nsystematic experimental data, comprehensive finite-element simulations, long-term\ncycling tests, and a more problem-driven narrative structure. While further\nimprovements in speed optimization and large-scale integration remain valuable\ndirections for future research, we believe the current revisions significantly strengthen\nboth the scientific depth and clarity of the work, and position it as a meaningful\ncontribution to Nature Communications.\nReviewer #4 (Remarks to the Author):\nI co-reviewed this manuscript with one of the reviewers who provided the listed\nreports. This is part of the Nature Communications initiative to facilitate training\nin peer review and to provide appropriate recognition for Early Career\nResearchers who co-review manuscripts.\nResponse: We sincerely thank the reviewer and the co-reviewer for their constructive\nevaluation and thoughtful feedback. We highly appreciate the effort dedicated to this\njoint review and recognize its value for both rigorous assessment and training purposes.\nFollowing the reviewers’ suggestions, we have substantially improved the manuscript\nby strengthening quantitative analyses, refining theoretical modeling, expanding\ndurability assessments, and sharpening the overall presentation. We believe these\nrevisions have considerably enhanced the quality, clarity, and impact of our work.\nReferences\n1. Yan X, Chen Q, Huo Z, Zhang N, Ma M. Programmable Multistimuli-Responsive and\nMultimodal Polymer Actuator Based on a Designed Energy Transduction Network.\nACS Appl. Mater. Interfaces 14, 13768–13777 (2022).\n2. El Helou C, Buskohl PR, Tabor CE, Harne RL. Digital logic gates in soft,\nconductive mechanical metamaterials. Nat. Commun. 12, 1633 (2021).\n3. El Helou C, Grossmann B, Tabor CE, Buskohl PR, Harne RL. Mechanical integrated\ncircuit materials. Nature 608, 699–703 (2022).\n4. Byun J, Pal A, Ko J, Sitti M. Integrated mechanical computing for autonomous\nsoft machines. Nat. Commun. 15, 2933 (2024).\n5. El Helou C, Hyatt LP, Buskohl PR, Harne RL. Intelligent electroactive material\nsystems with self-adaptive mechanical memory and sequential logic. Proc. Natl.\nAcad. Sci. 121, e2317340121 (2024).\n6. Chen H, et al. Thermal Computing with Mechanical Transistors. Adv. Funct.\nMater. 34, 2401244 (2024).\n7. Wu L, et al. Mechanical Metamaterials for Handwritten Digits Recognition. Adv.\nSci. 11, e2308137 (2024).\n8. Zhang Q, et al. Meta-mechanotronics for self-powered computation. Mater. Today\n65, 78–89 (2023).\n9. Mei T, Meng Z, Zhao K, Chen CQ. A mechanical metamaterial with reprogrammable\nlogical functions. Nat. Commun. 12, 7234 (2021).\n10. Pal A, Sitti M. Programmable mechanical devices through magnetically tunable\nbistable elements. Proc. Natl. Acad. Sci. 120, e2212489120 (2023).\n11. Yanbin Li SY, Haitao Qing, Yaoye Hong, Yao Zhao, Fangjie Qi, Hao Su*, Jie\nYin*. Reprogrammable and reconfigurable mechanical computing metastructures\nwith stable and high-density memory. Sci. Adv. 10, eado6476 (2024).\n12. Jiang Y, Korpas LM, Raney JR. Bifurcation-based embodied logic and autonomous\nactuation. Nat. Commun. 10, 128 (2019).\n13. Treml B, Gillman A, Buskohl P, Vaia R. Origami mechanologic. Proc. Natl. Acad.\nSci. 115, 6916–6921 (2018).\n14. Bilal OR, Foehr A, Daraio C. Bistable metamaterial for switching and cascading\nelastic vibrations. Proc. Natl. Acad. Sci. 114, 4603–4606 (2017).\n15. Peng X, Li H, Xu J, Lan C, Liu J, Wu B. Reprogrammable shape morphing hydrogel\nmodulated by synergistic photochromism and photoactuation. Chem. Eng. J. 511,\n162103 (2025).\n16. Wang C, Wu H, Niu Q, Yan X, Wang X. Light-Controlled Soft Switches for Optical\nLogic Gate Operations. Sensors 25, 2051 (2025).\n17. Das A, Babu A, Chakraborty S, Van Guyse JFR, Hoogenboom R, Maji S. Poly(N-\nisopropylacrylamide) and Its Copolymers: A Review on Recent Advances in the\nAreas of Sensing and Biosensing. Adv. Funct. Mater. 34, 2402432 (2024).\n18. Toshikazu TAKIGAWA TY, KatsunOri TAKAHASHI,and Toshiro MASUDA. Deswelling\nKinetics of Poly(N-isopropylacrylamide) Gels atVolume-Phase Transition. Polym.\nJ. 31, 595–598 (1999).\n19. Yang C, et al. Silver Nanowires: From Scalable Synthesis to Recyclable\nFoldable Electronics. Adv. Mater. 23, 3052–3056 (2011).\n20. Zhu D, Huang G, Zhang L, He Y, Xie H, Yu W. Silver Nanowires Contained\nNanofluids with Enhanced Optical Absorption and Thermal Transportation\nProperties. Energy Environ. Mater. 2, 22–29 (2019).\n21. Ogieglo W, et al. n-Hexane induced swelling of thin PDMS films under non-\nequilibrium nanofiltration permeation conditions, resolved by spectroscopic\nellipsometry. J. Membrane Sci. 437, 313–323 (2013).\n22. Tian K, et al. Stretchable Multifunctional Polydimethylsiloxane Composites\nwith Cage-Like Conductive Architecture for Integrated Thermosensitive and\nElectromagnetic Interference Shielding Performance. Adv. Funct. Mater. 34,\n2400288 (2024).\n23. Wang Y, Zhang Z, Chen H, Zhang H, Zhang H, Zhao Y. Bio-inspired shape-memory\nstructural color hydrogel film. Sci. Bull. 67, 512–519 (2022).\n24. Xue P, et al. Highly Conductive MXene/PEDOT:PSS‐Integrated Poly(N‐\nIsopropylacrylamide) Hydrogels for Bioinspired Somatosensory Soft Actuators.\nAdv. Funct. Mater. 33, 2214867 (2023).\n25. Koo HB, Yeon H, Bin Yoon Y, Lee TJ, Chang YT, Chang JB. Rewritable wavelength-\nselective hydrogel actuators grafted with fluorophores. Mater. Horiz. 12,\n2255–2266 (2025)."}, {"round": 2, "reviewer_comments": {"reviewer_1": "After carefully reading the response to reviewers point by point, I changed my original mind of rejection. The novelty of this work is to design a light-responsive composite film that couples mechanical deformation with electrically reconfigurable pathways. This supports complex logic such as a 2-bit adder, exhibiting an environment-adaptive camouflage system, enabling to establish a scalable and application-oriented paradigm for mechanical computing. This work represents a fundamental shift from traditional actuator-based mechanical computing, which primarily focuses on local actuation or switching at the device level.\nBesides, supplemented experimental has been performed to demonstrate the actual computational capability of the system and quantitatively evaluated its robustness under complex environmental conditions.\nI suggest acceptance of the revised manuscript. The only suggested revision to about Figure 1. Data scale should be provided in Figure 1b(ii)", "reviewer_2": "I thank the authors for the prompt responses which have well addressed my ealry concerns. I thus recommend it for publication as is.", "reviewer_3": "The co-reviewer and I commend the authors for their thorough and appropriate response to the majority of the reviewers' requested revisions and questions. However, we remain concerned that the authors should address the following critical issues to clarify the novelty of this research. So, we decided that this article should be majorly revised again.\n1. Misuse of “switching time” and incorrect definition of operating frequency\nThe manuscript emphasizes device speed using response-time–based statements, such as “sub-second switching” and operating frequency estimated as f = 1/tresponse. However, in this system, a complete switching event requires both response and recovery. As shown in Fig. R8, the recovery time is consistently ≥ 1 s across all reported conditions.\nTherefore, the actual 1-cycle switching time necessarily lies in the multi-second regime.\nFor scientific accuracy, the reviewer requests that the authors redefine switching time as the full cycle,\ntswitching=tresponse+trecovery, and base all speed-related descriptions, including operating frequency, on this cycle-level definition rather than on response-only values. This clarification is also essential for fair comparison with metamaterial-based mechanical logic: relying solely on response time systematically overestimates the performance of the present system, whereas the cycle-level behavior provides an accurate, unbiased basis for evaluating switching dynamics.\nThe reviewer requests to revise all mentions of switching time, operating frequency, and speed comparisons to explicitly reflect cycle-based switching and adjust any “sub-second” or “high-frequency” claims accordingly.\n2. Redundant Qij outputs due to AND-only logic, reducing degrees of freedom in the camouflage system\nIn the adaptive camouflage demonstration, the 3 × 3 outputs Qij are generated exclusively through AND-type logical combinations of the three sensing inputs. However, based on the sensing/computation circuitry described in the manuscript and supplementary materials, several outputs (e.g., Q12 and Q13) are produced by identical logical expressions. These pixels will therefore always assume the same value, meaning they are not independent degrees of freedom.\nAs a result, the effective dimensionality of the 3 × 3 camouflage pattern is intrinsically less than nine, even under ideal conditions. This structural limitation is not discussed in the manuscript, despite its direct impact on the achievable texture reconstruction fidelity and the expressive capability of the camouflage system.\nThe reviewer requests that the authors:\n  Discuss how this reduction in independent output limits the expressibility and achievable fidelity of the camouflage pattern\n  Clarify whether such redundancy is intentional, a constraint inherent to the present circuitry, or something that could be eliminated by incorporating additional logic operations (e.g., OR, NOT, or mixed logic)\n  Clarifying this structural issue is important for an accurate assessment of the system’s adaptive camouflage capabilities.", "reviewer_4": "I co-reviewed this manuscript with one of the reviewers who provided the listed reports. This is part of the Nature Communications initiative to facilitate training in peer review and to provide appropriate recognition for Early Career Researchers who co-review manuscripts."}, "author_response": "Response to Reviewers\nReviewers’ Comments:\nReviewer #1 (Remarks to the Author):\nAfter carefully reading the response to reviewers point by point, I changed my\noriginal mind of rejection. The novelty of this work is to design a light-responsive\ncomposite film that couples mechanical deformation with electrically\nreconfigurable pathways. This supports complex logic such as a 2-bit adder,\nexhibiting an environment-adaptive camouflage system, enabling to establish a\nscalable and application-oriented paradigm for mechanical computing. This work\nrepresents a fundamental shift from traditional actuator-based mechanical\ncomputing, which primarily focuses on local actuation or switching at the device\nlevel. Besides, supplemented experimental has been performed to demonstrate the\nactual computational capability of the system and quantitatively evaluated its\nrobustness under complex environmental conditions.\nI suggest acceptance of the revised manuscript. The only suggested revision to\nabout Figure 1. Data scale should be provided in Figure 1b(ii)\nResponse: We sincerely thank the reviewer for thorough evaluation of our revised\nmanuscript and their recognition of the novelty and potential of our work in advancing\nmechanical computing and establishing a new computational paradigm.\nIn response to the reviewer’s suggestion regarding the data scale in Figure 1b(ii),\nwe have added the requested scale bar and provided a corresponding description in the\nfigure legend (as shown in Fig. R1). Additionally, we have thoroughly reviewed the\nentire manuscript and supplementary material, and have added scale bars to the\nfollowing figures: Fig. 2a, Fig. 2d, Fig. 3a(ii), Fig. 3b(ii), Fig. 3c(ii) in the revised\nmanuscript, and Fig. 5, Fig. 13-15, Fig. 17, Fig. 20, and Fig. 22-24 in the revised\nsupplementary information. Descriptions of the scale bars have been appropriately\nincluded in the respective figure legends.\nFig. R1. The construction of polyaniline composite film for implementing light-\nprogrammable mechanical computing. a Schematic representation of the typical\npolyaniline composite film (PCF) structure, consisting of three layers: a polyaniline-\npoly(N-isopropylacrylamide) (PANi-PNIPAm) layer, a silver nanowires (Ag NWs)\nlayer, and a polydimethylsiloxane (PDMS) layer. b (i) The reversible bending\ndeformations of the PCF, induced by variations in light and humidity, result in the\ndeformation of the conductive pathways. (ii) The corresponding optical images of the\nabove process. Scale bar: 3 mm. c The operating mechanism of light-programmable\nmechanical computing. The terms SPST and SPDT refer to single-pole single-throw\nand single-pole double-throw relays, respectively.\nReviewer #2 (Remarks to the Author):\nI thank the authors for the prompt responses which have well addressed my ealry\nconcerns. I thus recommend it for publication as is.\nResponse: We sincerely thank the reviewer for recommending the publication of our\nwork in Nature Communications.\nReviewer #3 (Remarks to the Author):\nThe co-reviewer and I commend the authors for their thorough and appropriate\nresponse to the majority of the reviewers' requested revisions and questions.\nHowever, we remain concerned that the authors should address the following\ncritical issues to clarify the novelty of this research. So, we decided that this article\nshould be majorly revised again.\nResponse: We sincerely thank the reviewer and co-reviewer for their careful evaluation\nof our revised manuscript and for acknowledging our efforts in addressing the reviewers’\ncomments. We appreciate the additional nice suggestion regarding the clarification of\nthe work’s novelty. We have carefully considered all remaining concerns and provided\ndetailed, point-by-point responses in the sections below.\n1. Misuse of “switching time” and incorrect definition of operating frequency\nThe manuscript emphasizes device speed using response-time–based statements,\nsuch as “sub-second switching” and operating frequency estimated as f = 1/t\nresponse. However, in this system, a complete switching event requires both\nresponse and recovery. As shown in Fig. R8, the recovery time is consistently ≥ 1 s\nacross all reported conditions. Therefore, the actual 1-cycle switching time\nnecessarily lies in the multi-second regime.\nFor scientific accuracy, the reviewer requests that the authors redefine switching\ntime as the full cycle, t =t +t , and base all speed-related\nswitching response recovery\ndescriptions, including operating frequency, on this cycle-level definition rather\nthan on response-only values. This clarification is also essential for fair\ncomparison with metamaterial-based mechanical logic: relying solely on response\ntime systematically overestimates the performance of the present system, whereas\nthe cycle-level behavior provides an accurate, unbiased basis for evaluating\nswitching dynamics.\nThe reviewer requests to revise all mentions of switching time, operating frequency,\nand speed comparisons to explicitly reflect cycle-based switching and adjust any\n“sub-second” or “high-frequency” claims accordingly.\nResponse: We thank the reviewer for nice suggestion regarding clarifying the\ndefinition of switching time and operating frequency. By following the reviewer’s\nrecommendation, we have redefined the switching time as a full switching cycle,\nt = t + t , rather than using the response time alone in the revised\nswitching response recovery\nmanuscript and supplementary materials. Based on this cycle-level definition, we have\nre-evaluated device performance under all experimental conditions. The fastest\nswitching cycle was measured under an illumination intensity of 300 mW/cm2\n(temperature 29 ± 1 °C, relative humidity 83%), yielding t = 2.55 s (t = 0.13\nswitching response\ns, t = 2.42 s) corresponding to an operating frequency of f = 1/t ≈ 0.4 Hz, as\nrecovery switching\nshown in Fig. R2.\nFig. R2. Environmental effects on switching performance of the SPST relay. a\nSwitching times and operating frequency as a function of light intensity (40–310\nmW/cm2) at 29 ± 1 °C and 83 ± 3% RH. Each dataset is based on 50 measurements for\nthe respective conditions.\nAccordingly, we have explicitly defined switching time, response time, and recovery\ntime in both the manuscript and the supplementary information, providing a precise\ndescription of these parameters. The revision clarifies that the term “sub-second”\nrefers exclusively to the response time. In particular, Supplementary Table 3 has been\ncomprehensively updated (see Table R1) to include four metrics wherever data are\navailable: response time, recovery time, switching time per cycle, and operating\nfrequency. For most literature reports, only the response time was provided, and some\nof these values were estimated from published videos, which have been clearly\nindicated in the table. Information on recovery time is reported in only 2 prior work,\nand the corresponding entries are marked as “not applicable” (N/A) for all other\ncases.\nTo reflect the reviewer’s suggestion, we have made the following revisions in the\nrevised manuscript. [Please see lines 183-196, pages 8-9].\n“The switching time is defined as the sum of the response time and the recovery time.\nUnder an illumination intensity of 130 mW/cm2 at 29 ± 1 °C and 83 ± 3% relative\nhumidity, the single-pole single-throw (SPST) relay exhibited a response time of 1.02 s\nand a recovery time of 2.07 s, corresponding to a total switching time of 3.09 s and an\noperating frequency of approximately 0.32 Hz. Similarly, the single-pole double-throw\n(SPDT) relay showed a response time of 1.20 s and a recovery time of 2.05 s, resulting\nin a switching time of 3.25 s and an operating frequency of about 0.31 Hz\n(Supplementary Fig. 7). Notably, increasing the illumination intensity to 300 mW/cm2\nunder the same temperature and humidity conditions significantly reduced the SPST\nresponse time to ~0.13 s, while the recovery time remained at 2.4 s. This led to a shorter\ntotal switching time of 2.53 s and a correspondingly higher operating frequency of\n~0.40 Hz, demonstrating that faster switching can be achieved through optical\noptimization (Supplementary Fig. 7c).”\nWe have added Fig. R2 in the revised supplementary information. [Please see\nSupplementary Fig.7c]\nAdditionally, we have thoroughly updated the sections on switching time and\noperating frequency in the revised supplementary information. [Please see\nSupplementary Note 8 and Supplementary Table 3]\n“Metamaterial logic typically operates on the scale of seconds to minutes (for\nexample, 2–3 s response time for rotating blocks (with no recovery time reported)13, 14,\n5–20 s response time for hydrogel gates (with no recovery time reported)15,\napproximately 27 s switching time for electrically driven systems16, and up to 80\nminutes response time for thermal adders (with no recovery time reported) 17). These\ndelays are mainly caused by inertia and elastic recovery, which make sub-second\nresponse time extremely difficult. In contrast, our system achieves a significantly\naccelerated switching performance. Under 300 mW/cm2 illumination, the response\ntime of 0.13 s (Supplementary Fig. 6a) is over an order of magnitude faster than that\nof most existing systems. This improvement stems from the light–thermal–mechanical\ncoupling mechanism. The system's overall switching time is less than 3 s, enabling\nstable operation at a practical frequency of approximately 0.3–0.4 Hz, outperforming\nprevious studies systems9, 16, 18. With further miniaturization, the switching time is\nexpected to decrease further, enabling even faster logic operations.”\nTable R1. Quantitative Benchmark of Key Performance Metrics for Stimuli-Responsive Logic Systems\nExternal Recovery Switching Operating Power Environmental\nResponse Time Scalability Ref.\nStimuli Time Time frequency Consumption Resilience\nSeven fundamental logic gates:\nAND, OR, XOR, NOT, NAND,\nSecond-level\nMechanical Zero static NOR, NXOR; El\n(Estimated from the N/A N/A N/A N/A\nforce power logic gate combination OR-NAND, Helou13\nmovie) NOR-AND, OR-AND, and AND-\nNAND\nSeven fundamental logic gates:\nSecond-level AND, OR, XOR, NOT, NAND,\nMechanical Zero static El\n(Estimated from the N/A N/A N/A NOR, NXOR; N/A\nforce power Helou14\nmovie) 2-bit Adder/Subtractor/Multiplier;\n4-bit Magnitude Comparator\nSecond-level NOT, AND, OR;\nMechanical Zero static\n(Estimated from the N/A N/A N/A Supports cascaded logic (e.g., 3- N/A Byun15\nforce power\nmovie) level AND/OR/NOT networks)\nSecond-level\nMechanical Zero static AND, OR, NOT; Full Adder; Operates at -20°C\n(Estimated from the N/A N/A N/A Wu19\nforce power Cascading of multiple (7) adders for >24 hours\nmovie)\nSelf-powered Six basic logic gates (AND, OR,\nMechanical N/A N/A (Power XOR, NAND, NOR, XNOR)\nN/A N/A N/A Zhang20\nforce generation: 4.35 full adder;\nnW) 3-bit ternary computing\nNOR, NAND, NOT, OR, AND;\nSecond-level\nElectromagn Zero static Half adder;\n(Estimated from the N/A N/A N/A N/A Mei21\net power 3D printable at multiple scales\nmovie) (macro to micro)\nSecond-level\nZero static Field Strength (B): -85\nMagnetic (Estimated from the N/A N/A N/A AND, OR Pal22\npower to 85 mT\nmovie)\nSecond-level Zero static AND, OR, NOR, NAND； Compression:\nMagnetic or\n(Estimated from the N/A N/A N/A power Maximum demonstrated: 30 × 27 Withstands 2.8 kPa Li23\nmechanical\nmovie) unit array pressure at 2% strain\nOperates in liquid\nSolvents Zero static environments\n420.6 to 0.0019 to 0.0024\n(toluene and 0.6 to 108 s 70 min power AND, OR, NAND; (water/toluene) Jiang18\n528 s Hz\nwater) Reusable after 70min\ndrying\nOperates in 0-85% RH\nZero static SR Latch, AND, OR;\nHumidity N/A N/A N/A N/A range; Treml24\npower Majority Gate;\n5 cycles\n5.5 W (1-bit\nsystem) 1-bit (T flip-flop); 2-bit (counter); El\nElectrical N/A N/A 27.2 s 0.0368 Hz N/A\n7.4 W (8-bit 8-bit (equation solver) Helou16\nsolver)\nTime Constant continuous operation\nZero static NOT, AND, OR, XOR;\nThermal ():160 minutes; 0.5 N/A N/A N/A over 1000 min; Chen17\npower SR Latch; Full adder\n (full adder) Vacuum-compatible\nSignal Leakage (OFF\nAND, OR, XOR, NOT, NAND, state): < 10% of max\nZero static\nNOR, NXOR;\nsignal;\nVibration N/A N/A N/A N/A power R. Bilal25\nHalf Adder;\nSignal Clarity\nFull Adder (ON/OFF\ndifference): > 10\n2 min (120 Zero static\nLight N/A N/A N/A AND, NOT; 100 mW to 397.7 mW Peng8\nmW/cm2) power\nZero static\n27 s 0.037 Hz AND, OR, NOT;\nLight 12 s (379.7 mW) 15 s power 500 cycles Wang9\nSoft optical switch array\nLight intensity: 70–310\n~1.04 s (130 ~1.93 s (130 ~2.97 s (130 ～0.3 Hz (130 mW/cm2;\nmW/cm2) mW/cm2) mW/cm2) mW/cm2) Zero static AND, OR, NOT, XOR; Humidity: 47–86% RH This\nLight power\n~0.13 s (300 ~2.4 s (300 ~2.53 s (300 ～0.4 Hz (300 2-bit Adder; Temperature: 10– Work\nmW/cm2) mW/cm2) mW/cm2) mW/cm2) 30 °C;\nCycles: 600\n(The data for our work in the table are derived from the averaged values shown in Supplementary Fig. 6a.)\n2. Redundant Q outputs due to AND-only logic, reducing degrees of freedom in\nij\nthe camouflage system. In the adaptive camouflage demonstration, the 3 × 3\noutputs Q are generated exclusively through AND-type logical combinations of\nij\nthe three sensing inputs. However, based on the sensing/computation circuitry\ndescribed in the manuscript and supplementary materials, several outputs (e.g.,\nQ and Q ) are produced by identical logical expressions. These pixels will\n12 13\ntherefore always assume the same value, meaning they are not independent\ndegrees of freedom. As a result, the effective dimensionality of the 3 × 3 camouflage\npattern is intrinsically less than nine, even under ideal conditions. This structural\nlimitation is not discussed in the manuscript, despite its direct impact on the\nachievable texture reconstruction fidelity and the expressive capability of the\ncamouflage system. The reviewer requests that the authors:\nResponse: We thank the reviewer for this insightful comment regarding the redundancy\namong certain 𝑄 outputs and its implications for the expressibility of the adaptive\n𝑖𝑗\ncamouflage system. Our responses to the individual comments are provided below.\n(1) Discuss how this reduction in independent output limits the expressibility and\nachievable fidelity of the camouflage pattern\nOverall impact on expressibility and achievable fidelity\nWe thank the reviewer for the insightful comments. In our system, the representational\ncapacity and achievable fidelity of the camouflage patterns are primarily governed by\nthe relationship between the characteristic feature size of the target texture and the\nspatial sampling area of a single sensing-computation-emission (SCE) unit (3 × 3\npixels). When the size of texture features is substantially larger than the sensing window\nsize, the reconstructed patterns maintain global continuity and exhibit high visual\nfidelity. In contrast, when the feature size approaches the 3 × 3 sensing scale, the unit\ncan no longer resolve the underlying texture variations, leading to reduced\nreconstruction accuracy and diminished expressive capability.\nUnderlying mechanism of the camouflage pattern\nThis behavior arises directly from the operating principle of each SCE unit. Each unit\nsamples local intensity variations by using three spatially distributed sensing nodes and\nreconstructs a representative local gradient direction through an AND-based logic\npathway, as shown in Fig. R3a. This mechanism yields a clean abstraction of texture\nfeatures by emphasizing coarse spatial trends such as prominent edges and stripe\nboundaries, while intentionally omitting fine-scale variations within a 3 × 3 region.\nAccordingly, the reconstruction fidelity is determined by the relationship between the\ntexture feature size and the spatial sampling window of the SCE unit. When the texture\nfeatures extend beyond the sampling region, the unit effectively captures the underlying\ngradient variations and consequently achieves high-fidelity reconstruction of local\ntexture patterns.\nValidation of the fidelity of the camouflage patterns\nTo further quantify this effect, we carried out systematic simulations using zebra-stripe\ntextures with different feature sizes, with the corresponding results shown in Fig. R4a.\nReconstruction quality was assessed using the pixel mismatch rate between the input\nand reconstructed images, defined as the ratio of pixels with inconsistent brightness to\nthe total number of pixels (Fig. R5). When the average stripe width in the input image\nexceeds approximately four mapped pixels, the mismatch rate remains below 15%,\nindicating that the system maintains camouflage-level fidelity. As the stripe width\nfurther decreased to approximately 2 pixels, approaching the scale of the 3 × 3 sensing\nwindow, a reduction in reconstruction fidelity emerged. This behavior is fully\nconsistent with the expected operating mechanism\nFig. R3. Circuit diagrams of the SCE unit for reconstruction schemes based on AND\nlogic (a), OR logic (b), and the combined AND/OR logic configuration (c), together\nwith the spatial distributions of the sensed optical input signals (P , P , and P ) and the\n1 2 3\ncorresponding output signals (Q , Q , …, Q ) within the SCE unit. In panels (a) and\n11 12 33\n(b), two pixels emit identical signals, specifically Q = Q , Q = Q , and Q = Q .\n12 13 21 22 32 33\nIn contrast, in panel (c), the signals emitted by different pixels are not identical, and all\nnine output signals are mutually independent.\nFig. R4. Image reconstruction results obtained using AND logic (a), OR logic (b), and\nthe combined AND/OR logic configuration (c) for textures with different average\nzebra-stripe widths. For an input resolution of 1024 × 1024, the average stripe width\ncorresponds to approximately 32 pixels; for 512 × 512, approximately 16 pixels; for\n256 × 256, approximately 8 pixels; for 128 × 128, approximately 4 pixels; for 64 × 64,\napproximately 2 pixels; and for 32 × 32, approximately 1 pixel.\nFig. R5. Pixel-level differences between the original and reconstructed images for\nzebra-stripe textures of varying average widths, using reconstruction schemes based on\nAND logic (Fig. R4a), OR logic (Fig. R4b), and the combined AND/OR logic\nconfiguration (Fig. R4c). Here, pixel mismatch rate between the original and\nreconstructed images is defined as the ratio of pixels with inconsistent brightness to\nthe total number of pixels.\n(2) Clarify whether such redundancy is intentional, a constraint inherent to the\npresent circuitry, or something that could be eliminated by incorporating\nadditional logic operations (e.g., OR, NOT, or mixed logic)\nWe thank the reviewer for the insightful comments.The redundancy in the current\nlogic architecture is an intentional design choice rather than an intrinsic limitation of\nthe circuitry. Our guiding principle aims to achieve the required camouflage\nperformance using the minimal amount of sensing and computational resources. We\ntherefore adopted an image reconstruction scheme based on AND gates because it\nalready provides sufficient capability to reconstruct the spatial light–dark gradient\nfeatures extracted from the sensing units, without necessitating additional logic\nfunctions.\nTo further substantiate this point, we evaluated the reconstruction performance of\nalternative logic operations. We found that using OR logic alone (Fig. R3b) or in\ncombination with AND logic (in this case, each pixel within the 3 × 3 SCE output\nregion encodes independent information; Fig. R3c) can produce camouflage patterns\nwhich are essentially identical to those generated by AND logic in terms of\nrepresentational capacity and fidelity (Fig. R4b and Fig. R4c). In all cases, the\nperformance is governed by the same fundamental factor: the relative scale between the\ntexture-feature size and the spatial extent of the image perceived by a 3 × 3 SCE unit\n(Fig. R5). High-fidelity reconstruction is achieved only when the texture feature size is\nconsiderably larger than the effective spatial coverage of the sensing window, and this\nconclusion holds irrespective of whether an AND-gate or OR-gate logic is employed.\nIn contrast, logic operations involving inversion (e.g., NOT, NAND, NOR) are\ninappropriate because the negation operation reverses the local intensity-gradient\npolarity, converting bright regions to dark and vice versa, and thus introduces large\nperceptual errors in the reconstructed patterns.\nThese observations demonstrate that the use of AND logic reflects a deliberate and\nefficient architectural choice rather than a functional constraint. It minimizes hardware\nresource consumption while still offering adequate representational capacity for global\ntexture reconstruction.\n(3) Clarifying this structural issue is important for an accurate assessment of the\nsystem’s adaptive camouflage capabilities.\nWe appreciate the reviewer’s emphasis on this structural consideration, as it is\nessential for accurately evaluating the system’s adaptive camouflage capability. In our\narchitecture, the fidelity of reconstructed camouflage patterns is primarily governed by\nthe relationship between the characteristic texture size and the spatial region perceived\nby an individual SCE unit. High-fidelity reconstruction is achieved when the texture\nfeatures are substantially larger than the effective sensing window of the SCE unit.\nWhen the feature size approaches the spatial scale sampled by the unit, the\nreconstruction fidelity is necessarily affected. This behavior follows directly from the\noperating principle of the SCE, which is designed to resolve spatial intensity gradients\nthat extend beyond the 3 × 3 sampling window.\nThe redundancy introduced by the use of pure AND logic is an intentional design\nchoice rather than a circuit limitation. AND logic is sufficient to extract the brightness-\ngradient information required for camouflage reconstruction, and replacing it with OR\nlogic or a hybrid OR/AND configuration does not yield additional representational\nbenefits. Logic operations involving inversion (such as NOT, NAND, or NOR) are not\nappropriate in this context because they reverse the local contrast polarity, resulting in\nsubstantial perceptual distortion in the reconstructed patterns. Taken together, these\nconsiderations define a minimal yet fully sufficient logic scheme that is optimized for\nresource-efficient operation.\nSimulations based on zebra-stripe textures quantitatively support this conclusion.\nWhen the stripe width exceeds approximately four pixels, the pixel mismatch rate\nremains below ~15%. As the feature size is further reduced to become comparable to\nthe 3 × 3 sensing region, the mismatch rate increases, and the reconstructed images\ngradually lose their texture-camouflage capability.\nOverall, these results show that the architecture follows a lightweight design\nphilosophy consistent with hardware efficiency considerations, and that its operational\nrange and limitations can be reliably assessed through the relative scale between scene\ntexture features and the effective sensing area of the SCE unit.\nTo reflect the reviewer’s concern and provide readers with a clear understanding of\nthe design architecture and performance characteristics, we have added these results\nand relevant discussions in the revised supplementary information. [Please see\nSupplementary Note 7. The achievable texture reconstruction fidelity and the\nexpressive capability of the camouflage system]\nWe have also added the following discussions in the revised main text. [Please see\nlines 340-347, pages 14-15].\n“In addition, we conducted a detailed analysis of the fidelity of the reconstructed\ncamouflage patterns. We note that this fidelity is primarily governed by the relationship\nbetween the texture-feature size and the spatial extent of an individual SCE unit’s\nsensing window. High-fidelity reconstruction is achieved when the texture features are\nsubstantially larger than the 3 × 3 sensing area, whereas features approaching this scale\nresult in reduced reconstruction accuracy. A more detailed discussion is provided in\nSupplementary Note 7 (Supplementary Figs. 26-28).”\nReviewer #4 (Remarks to the Author):\nI co-reviewed this manuscript with one of the reviewers who provided the listed\nreports. This is part of the Nature Communications initiative to facilitate training\nin peer review and to provide appropriate recognition for Early Career\nResearchers who co-review manuscripts.\nResponse: We sincerely thank the reviewer and the co-reviewer for their constructive\nevaluation and thoughtful feedback. We highly appreciate the effort dedicated to this\njoint review and recognize its value for both rigorous assessment and training purposes."}, {"round": 3, "reviewer_comments": {"reviewer_3": "The authors have carefully revised the manuscript and have satisfactorily responded to our comments, including those related to quantitative evaluation. In light of these revisions, we recommend that the manuscript be accepted for publication in Nature Communications.", "reviewer_4": "I co-reviewed this manuscript with one of the reviewers who provided the listed reports. This is part of the Nature Communications initiative to facilitate training in peer review and to provide appropriate recognition for Early Career Researchers who co-review manuscripts."}, "author_response": ""}]

Decision letter