Microscopic strain mapping in polymers equipped with non-covalent mechanochromic motifs

The mechanical failure of polymers remains challenging to understand and predict, as it often involves highly localised phenomena that cannot be probed with bulk characterisation techniques. Here, we present a generalisable protocol based on optical microscopy, tensile testing, and image processing that permits the spatially resolved interrogation of mechanical deformation at the molecular level around defects in mechanophore-containing polymers. The approach can be applied to a broad range of polymeric materials, mechanophores, and deformation scenarios.

were based on the fluorescence microscopy images recorded through green and red filters shown in Figure S3, following the analysis protocol described in the main manuscript. Note that the fact that the slopes of the linear fits through the data shown in (b) and (c) (0.0013 and 0.0018, respectively) are nearly identical is serendipitous, as these functions depend on the specific acquisition parameters, such as the specific wavelengths and -ranges at which I M and I E are determined. Nevertheless, the fact that I M /I E and strain are linearly correlated in both cases reflects that macroscopic spectroscopic measurements can be substituted by imaging techniques that additionally provide spatial resolution. Figure S5. Stress-strain curves samples of Loop-PU containing a macroscopic circular hole. Samples of Loop-PU were stretched with a strain rate of 50% min -1 . The measurements were stopped at ~29 %, 51 %, 100 %, 153%, and 200 % applied strain to record microscopy images.
The sample was inflicted with a hole (filled black circle or ellipse) and is shown in the unstretched (0% applied strain) and stretched (ca. 29%, 51%, 100%, 153%, and 200% applied strain) state. The black lines indicates the trace along which the I M /I E around the hole were analysed. I M /I E profiles acquired for Loop-PU at an externally applied strain of (b) 0% and 29% and (c) 51%, 100%, 153%, and 200% along the black traces shown in (a) are plotted against the polar angle from the center of the hole. Figure S7. I M /I E maps of tOPV/PU samples at applied strains between 0% and 349%. The samples were stretched at a strain rate of 50% min -1 and the application of strain was stopped at intervals of 25% applied strain to record microscopy images with a green (λ ex : 480/40 nm; λ em :535/50 nm) and a red filter (λ ex : 469/35 nm; λ em : 620/52 nm). Details of the procedure used to obtain the I M /I E maps are given in the MATLAB Analysis section (vide infra).

Supporting
8 Supporting Figure S8. (a) Stress-strain curve for a sample of tOPV/PU. The sample of tOPV/PU was stretched with a strain rate of 50% min -1 . The measurement was stopped at intervals of 25% applied strain to record microscopy images and plot calibration curves (b) correlating I M /I E to externally applied macroscopic strain.
9 Supporting Figure S9. Fluorescence intensity maps of Rot-PU samples stretched to applied strains between 0% and 350%. The sample was stretched at a strain rate of 1000 µm/s and the application of strain was stopped at intervals of 25% applied strain to record microscopy images under UV excitation (λ ex = 330-385 nm; λ em = 420-900 nm). Details of the procedure used to obtain the intensity maps are given in the MATLAB Analysis section (vide infra).
10 Supporting Figure S10. Stress-strain curve for a sample of (a) Rot-PU. The samples of Rot-PU were stretched with a strain rate of 50% min -1 . The measurement was stopped at intervals of 25% applied strain to record microscopy images and plot calibration curves (b) correlating average intensity to externally applied macroscopic strain.
Supporting Figure S11. Stress-strain curve of a sample of tOPV/PU containing a macroscopic circular hole. The sample of tOPV/PU was stretched with a strain rate of 50% min -1 . The measurement was stopped at 32 %, 54 %, 99 %, 147%, and 201 % applied strain to record microscopy images.
Supporting Figure S12. Stress-strain curve of Rot-PU containing a macroscopic circular hole. The sample of Rot-PU was stretched with a strain rate of 50% min -1 . The measurement was stopped at 32%, 45%, 97%, 149%, and 203% applied strain to record microscopy images.  Loop-PU films were compression molded at 150 °C for 3 min at 4 tons and slowly cooled to room temperature. The as-prepared samples were cut into films with dimensions of 40 × 5.5 × 0.2 mm (length × width × thickness). A hole was cut into the film using a 1 mm disposable biopsy punch with plunger (Integra Miltex). Pristine samples, not containing a hole, were used for the calibration curve.
tOPV was synthesised as previously reported. 2 Blends with Texin 985 (Covestro; Mn = 111 kDa, Ð = 2.0) and tOPV were prepared as previously reported. 3 Films with a concentration of 0.2 wt% tOPV were cut into strips with dimensions of 40 × 5.5 × 0.2 mm (length × width × thickness). A hole was cut into the film with a 1 mm disposable biopsy punch with plunger (Integra Miltex). Pristine samples, not containing a hole, were used for the calibration curve.
Rot and Rot-PU were synthesised and films were prepared as previously reported. 4 A hole was cut into the film with a 1 mm disposable biopsy punch with plunger (Integra Miltex). Pristine samples, not containing a hole, were used for the calibration curve.

Measurement conditions for widefield fluorescence microscopy.
Loop-PU and tOPV/PU. Fluorescence microscopy images were recorded with a 5x air objective and the exposure times were kept constant throughout the experiment. One image was recorded with a green filter (λ ex : 480/40 nm; λ em : 535/50 nm) and a second image with a red filter (λ ex : 469/35 nm; λ em : 620/52 nm). A MATLAB script was used to divide the arrays of grayscale intensities corresponding to the green and red fluorescence images element-wise to produce an I M /I E map, and to analyse I M /I E along a line around the defect (for further details, see MATLAB Analysis section). The same procedure was repeated on pairs of images taken at various externally applied strains that were stretched with a strain rate of 50 % min -1 between the strain-points.

Rot-PU.
Fluorescence microscopy images were recorded with a 5x air objective and the exposure times were kept constant throughout the experiment. One image was recorded with a UV filter. In order to correct for non-uniform fluorescence intensity, a MATLAB script was used to divide the array of grayscale intensities corresponding to the recorded image by a second array corresponding to the fluorescence intensity recorded from a pristine sample at 0% applied strain. As for Loop-PU and tOPV/PU, a MATLAB script was also used to define the hole and subsequently calculate the intensity along a line around the notch in a spatially resolved manner (for further details, see MATLAB Analysis section). The same procedure was repeated on pairs of images taken at various externally applied strains that were stretched with a strain rate of 345 % min -1 (1000 µm s -1 ) between the strain-points.

Measurement conditions for confocal microscopy.
Channel 1 was recorded using laser excitation at 458 nm and emission was recorded between 508 and 530 nm. Channel 2 was recorded using laser excitation at 458 nm and emission was recorded between The hole is defined by drawing an ellipse manually on the strain map (drawellipse). The elliptical path along which a local strain profile is extracted is defined geometrically as having the same aspect ratio as the ellipse corresponding to the hole, with its major vertices fixed at a distance corresponding to 200 µm away from those of the hole. In order to generate the profile, a mask is first applied to the image, in which all the pixels contained within the elliptical path are defined as '1', and those outside as '0' (createMask). The (x,y)-coordinates of the pixels on the boundary between the two regions are then extracted (bwboundaries). These coordinates are then used to obtain the values of the specific pixels in the local strain map. The (x,y)-coordinates are converted to vectors from the center point of the hole by subtracting the coordinates of the center point, then to polar coordinates (cart2pol). The values of the angle θ, which is angle between the line from the center of the ellipse to the pixel and the line from the center of the ellipse to the major vertex, are sorted from -π to π (sort). In the case of externally applied strains less than 50%, an angle of 0° is obtained from the line drawn from the center to the right-hand major vertex; at applied strains greater than 50%, only one major vertex is visible in the micrograph, and the 0° point is defined there. The profile is traced in a counter-clockwise direction. The θ-values are paired with the corresponding local strain values and the local strain vs. θ profiles can be plotted. At externally applied tensile strains greater than 50%, the hole became too large to be recorded entirely within a single micrograph. In these cases, the same analytical approach is employed, but with the additional step of extending the strain map with an area of 1300 × 1024 pixels that have a value of '0' (padarray). The hole can then be defined and the local strain profile extracted as above (the strain profile contains 0-values for the part of the sample not shown in the micrographs, but this part is removed). To generate the strain maps showing the elliptical paths (e.g., Figure 3a), the "padding" pixels are removed.
For results with Rot, local strain maps are generated from single micrographs of mechanically activated fluorescence intensity. The images are read in, converted to grayscale and converted to double precision arrays, as before. They are then corrected for uneven illumination intensity (the microscope images appear darker in the corners). In order to do this, the arrays corresponding to the images of the samples containing a hole are divided element-wise by the array corresponding to the image taken of the calibration sample at an externally applied strain of 0%. Prior to this operation, the calibration image is smoothed with a 2D Gaussian filter, in order to avoid introducing additional noise in the strain map (imgaussfilt). The local strain is calculated from the array of corrected intensity values element-wise using the following equation obtained from the exponential fit on the calibration data: ε local = log((I corry 0,calib )/A calib )/R 0,calib . Once the array of local strain values is obtained, two corrections are applied. Firstly, the value of I corr in some of the array elements is less than the y 0 -value obtained from the calibration.
This means that the script calculates the log of a negative number, resulting in a strain value that is a complex number. An operation is performed to set these elements to "NaN", which allows them to be disregarded in the analysis routine, while maintaining the dimensions of the array. Secondly, a local strain value of less than 0 is sometimes obtained. These elements are also disregarded in the analysis, as the calibration was performed in tension only, and it cannot be assumed that a similar log relationship between intensity and applied strain exists in compression. From this point on in the script, the calculation of the local strain profile is the same as for the tOPV and Loop samples.
The micrographs obtained from the confocal microscope are grayscale 16-bit 1024 × 1024 two-page tiff stacks. The first page in the tiff stack corresponds to the micrograph taken with the green filter, and the second to the micrograph taken with the red filter. These are first read into MATLAB (imread), and converted to a numerical array with double precision which is necessary for the following numerical manipulation (im2double). As for the Loop data obtained with the widefield fluorescence microscope, the array corresponding to the green fluorescence micrograph is divided element-wise by the array corresponding to red fluorescence micrograph (bsxfun). The I M /I E ratios obtained in each pixel of this array are then used to calculate local strain values, using the parameters obtained from the calibration.
These parameters are the slope and intercept of a straight line fit to Δ(I M /I E ) vs. externally applied strain.
For the calibration sample, Δ(I M /I E ) is calculated by subtracting the average value of I M /I E at an applied strain of 0% (i.e. I M,0 /I E,0 ) from I M /I E for all the strain-points. For the sample containing the glass beads, a similar approach was employed, but I M,0 /I E,0 was calculated by taking the average I M /I E on a part of the sample at 0% applied strain away from the beads in the top left-hand corner of the image. A first local strain map is then visualised for inspection (imagesc). Thresholding is used to identify the locations of the glass beads and the cavities around them. The green image is segmented into four levels of intensity (imquantize), and those parts of the image belonging to lowest level of intensity are defined as the defects (beads and cavities). A mask array is generated where the defects are defined as '0' and the surrounding matrix as '1'. White spaces within the black holes are filled in (imfill). The script removes holes with an area of less than 1500 pixels (bwareaopen), corresponding to approximately to a glass bead with a diameter of 6 µm (given a reported diameter of 9-13 µm), from the list of identified defects.
The number of identified defects is calculated (regionprops, numel) and the (x,y)-coordinates of the pixels in the boundaries of the areas corresponding to the defects are extracted (bwboundaries).
The local strain profile around each defect is then calculated and plotted on the local strain map in a for loop which runs over the set of identified defects. In this loop, duplicate points are first removed from the boundary. The centroid of the hole is calculated from the averages of the x-and y-coordinates of the points on the edge of the hole area. The path along which the strain profile is extracted is defined at a constant distance of 20 pixels away, corresponding to a distance of 2.6 µm, from the edge of this area (polybuffer), and plotted on the local strain map. The points from the profiles which are located beyond the edges of the micrograph are removed, and the local strain values are retrieved from the local strain array for the selected pixels in this path (also within a for loop). The (x,y)-coordinates are converted to polar coordinates in the manner described for the analysis of the widefield fluorescence micrographs.
The MATLAB scripts are included in the online repository of the source data.