{'fraction_non_alphanumeric': 0.028639376612862418, 'fraction_numerical': 0.008804331326215655, 'mean_word_length': 4.883894016076213, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Nonlinear Spatial Focusing in Random Layered Media by Spectral Pulse Shaping

We demonstrate numerically a method of focusing two-photon field inside one-dimensional random media. The approach is based on coherent control of backscattering achieved by adaptive spectral pulse shaping. The spectral phases of a femtosecond laser pulse are adjusted for the constructive interference of its backward-traveling components, resulting in an enhanced reflection from within the random system. A delayed forward-propagating second pulse overlaps with the controlled reflection, increasing the inter-pulse multi-photon field at a location determined by the delay between the two pulses. The technique is shown to be robust against the variations of the disorder, and to work with realistic pulse shaping parameters, hence enabling applications in controlling random lasing and multi-photon imaging in scattering materials.


I. INTRODUCTION
Focusing of light in random media is of interest from both the fundamental and applied perspectives. One important application of light focusing in disordered materials relates to the controllability of coherent light amplification known as random lasing [1][2][3]. Lasing action in the presence of random light scattering has been theoretically analyzed and experimentally studied in multiple materials and spatial geometries [4][5][6][7][8][9][10][11]. The very nature of random lasing implies uncertainty in the characteristics of the lasing modes [12]. The ability to control the lasing frequency of a random laser has therefore been actively investigated and accomplished, for example, by changing the temperature of the scattering medium [13], its structure [3,14,15] and absorption properties [16], the wavelength [17] and the location of local pumping [9,[18][19][20]. The latter approach is particularly appealing in the regime of strong scattering, when the emission modes are localized in space and can be selectively excited by choosing the location of the pump which best overlaps the target lasing mode [21,22].
Local pumping requires optical access to different parts of the gain material. This can be achieved by applying an external pump laser to different areas on the surface of a three-dimensional sample [9]. However, for systems of lower dimensionality (especially one-dimensional (1D) random lasers [23,24], where the regime of light localization is most easily established), local pumping implies the ability to focus the pump light inside the scattering medium. It has recently been implemented by pumping a 1D random structure from the side, i.e. perpendicularly to the direction of the disorder [19,25]. Such pumping geometry, however, may not always be available, either because of the lack of optical access or due to the microscopic size of the sample.
Here, we propose an alternative approach, in which local pumping of a random layered medium is accomplished by means of spectral shaping of femtosecond pump pulses. The concept is similar to the spatiotemporal focusing of ultrashort laser pulses in three-dimensional scattering media [26][27][28]. There, controlling the spatial degrees of freedom of the incident wave has proven successful in simultaneous focusing of multiplyscattered light both in space and time. However, similarly to the pumping from the side of a sample, spatial shaping may not always be available for 1D structures with an optical access to their front layer only. In this situation, spectral shaping can be used as a powerful tool for controlling light propagation through, and interaction with, scattering materials [29]. The success of using the spectral degree of freedom has been recently demonstrated in the linear regime of spatio-temporal focusing [30]. Optical nonlinearity, such as two-photon absorption (TPA), offers higher degree of controllability in random media due to the process of multi-photon intra-pulse interference [31,32].
The one-dimensional photonic structure of our choice is illustrated in Fig. 1a. Known as a "random stack", it consists of a series of layers with alternating refractive indices n: here, 100 dielectric layers with n = 1.1 separated by air gaps (n = 1.0). The layers are of uniform but random thickness, distributed in the range [L(1− ), L(1+ )], where L is 10 microns for dielectric layers and 1 micron for air layers, and is the dimensionless disorder parameter. Random layer thickness results in the complete phase scrambling of multiply scattered waves, whereas their interference in one dimension brings about the well known effect of light localization [33]. Field intensity distributions inside two stacks, one with low and another with high degree of disorder are shown in Fig. 1 b and c, respectively, together with the corresponding transmission spectra (right panels).
The case of = 0.1% represents the photonic crystal limit with a stop band around 1500 nm. Localized edge modes can be seen around the boundaries between the pass and stop bands, but most of them are not sufficiently localized to be used in the proposed technique. When the degree of disorder is increased to = 20%, one can see the appearance of strongly localized modes associated with the randomly distributed transmission peaks. Illustration of the proposed strategy for multi-photon focusing inside a one-dimensional "random stack", consisting of alternating layers of random thickness (dielectric blue slabs and air gaps). Spectral shaping of the control pulse (blue) is used to initiate strong localized backscattering from within the stack. The focusing of a two-photon field occurs at the location, where the backscattered control pulse meets a forward-propagating pump (red, drawn off-axis from the control pulse for clarity) (b,c) Field distribution inside an almost periodic stack (b, = 0.1%) and a random stack (c, = 20%) at different wavelengths. Band-edge and localized modes are visible inside a periodic and disordered sample, respectively, and are reflected by the peaks in the corresponding transmission spectra shown in the right panels.
the average mode line width of about 1 nm, about ten times larger than the resolution of a typical spectral pulse shaper [34]. Together with the ability to cover a number of localized modes under the spectrum of a typical femtosecond pulse, individual control of the spectral phases within each excited mode is essential for the proposed focusing scheme described below. By inspecting the intensity distribution inside a random stack (Fig. 1c), one notes an obvious way of focusing light at different locations within the layered structure by means of narrowing the spectrum of a broadband excitation pulse and making it resonant with a single localized mode. However, such amplitude shaping implies much lower peak intensities and correspondingly higher average power required to cross the lasing threshold [35].
An alternative phase-only shaping is preferable from the standpoint of making use of the full bandwidth of an ultrashort pump pulse. Yet in the linear absorption regime, changing the spectral phases of the pulse amounts to altering its temporal profile but does not affect the total absorbed power [36]. We therefore turn to a nonlinear optical process, such as two-photon absorption, as the enabling mechanism for the controlled focused excitation. Similarly to the well known collidingpulse mode-locking scheme [37], we propose to create a local TPA centre inside a random stack by overlapping two counter-propagating pulses: a backscattered "control pulse" and a forward-propagating "pump pulse". The two pulses meet at the location easily controlled by the time delay between them. Backscattering is necessary due to the assumed restricted optical access to the random sample, limited to its front layer only (left most layer in Fig.1a). As we demonstrate below, spectral shaping is capable of creating the required strong backscattered pulse originating deep inside a disordered one-dimensional structure by controlling the phases of its localized modes. Furthermore, we show that the latter phases can be determined by means of an adaptive search algorithm which uses the energy of the pulse reflected from the front layer as the only feedback parameter.

II. TWO-PHOTON FIELD FOCUSING
The proposed technique achieves spatial focusing of the two-photon field in two steps. First, a control pulse, incident on the random stack along its axial direction, is spectrally shaped so as to backscatter from around the centre of the random sample. Then, a time-delayed pump pulse is injected along the same path. The central frequencies of the two pulses, ω c and ω p , are assumed to be separated by more than the pulse bandwidths, as shown by their combined spectrum in the wavelength domain in Fig. 2a. When the two pulses overlap in space and time, their two-photon field will acquire an inter-pulse sum-frequency component situated between the two individual second harmonics (shaded band in Fig. 2b). The spatial focusing of this sum-frequency component within the random stack is determined by the delay between the two pulses, and can be used for the two-photon pumping of a gain medium, provided the latter absorbs light at frequency ω c + ω p .

A. Controlled Backscattering
At any position z inside the stack, the field amplitude of the control pulse at frequency ω is a sum of the forward and backward-propagating components: E(ω, z) = a j (ω)e ikj z + b j (ω)e −ikj z , where k j = ωn j /c and j is the layer number. For a transform-limited control pulse incident on the stack, all spectral amplitudes a 0 (ω) are inphase, but multiple random scattering results in a significant phase scrambling between a j (ω) [and hence, b j (ω)] amplitudes at locations deep inside the stack, causing dispersed reflection. However, if one constructs a spectral phase mask to pre-shape a 0 (ω) before the control pulse enters the stack, such that the backward components acquire identical phases at a target location, a localized wave packet in the backward propagation direction can be generated.
To demonstrate the level of control over the backscattered pulse, we investigate one feedforward -based method and two feedback -based methods of finding the required pre-shaping mask. In the feedforward approach, the complex spectral amplitudes at the location of each layer are first calculated using the transfer matrix method [38] and a priori knowledge about the random stack parameters. The required phase mask is the one that flattens the phases of the backscattered amplitudes b j (ω)e −ikj z at a particular location z (e.g. midpoint of layer j). The ease of finding such a mask stems from the fact that all pairs of a j and b j amplitudes are linearly dependent on the incident amplitude a 0 , at any given frequency [39].
In practice, however, the the geometry of the stack structure, i.e. the exact layer thicknesses and refractive indices, is usually unknown. In this case, the preshaping mask can be found by means of an adaptive feedback loop optimizing the backscattered field intensity | ω b j (ω)e −iω(t−t0) e −ikj z dω| 2 either inside or outside the disordered sample. The internal field optimization may, again, be impractical. It will be analyzed below to serve as a reference for evaluating the performance of the second method based on optimizing the backward propagating field at the surface of the very front layer at a given time delay after the entrance of the control pulse.
In what follows, we demonstrate how the three shaping methods produce the desired focusing of the two-photon field and analyze its dependence on several key physical quantities: the degree of disorder, the location of the focus within the stack, and the resolution of the pulse shaper.
Note that the central frequency of the control field was deliberately chosen in the middle of the stop band (cf. Fig. 1 and 2) to analyze our focusing technique in the periodic limit. Pump and control pulses had the same bandwidth, with pump being 4 times more intense in order to compensate for the weakening amplitude of the backscattered control light. The initial resolution of the pulse shaper was set at 0.07 nm.

Dependence on the degree of disorder
The performance of the three focusing methods discussed above is illustrated in Figures 3, 4 and 5. In the upper row we plot the trajectory of a control pulse, i.e. the one-photon field intensity distribution as a function of the propagation time. Time zero corresponds to the arrival time of an unshaped control pulse at the front layer. The bottom row of plots shows the two-photon intensities for the shaded frequency band of Fig. 2b, as a function of the control-pump delay time. Pairs of such plots (different columns) are then compared across different degrees of randomness expressed as a relative variation of thickness ( ) of both the dielectric layers and the air gaps. Each plot is averaged over 10 realizations of the disorder.
In the feedforward shaping method, the phases of the backward propagating components are made equal at the midpoint of the 50th air layer. As can be seen in the upper row of Fig. 3, the pre-shaping is reflected by the smearing of the control pulse in time prior to its entrance to the stack. The successful generation of a backscattered pulse from the middle of the stack is clearly visible across moderate to large layer thickness variations ( =20%, 60%, 90%). The applied shaping also results in the temporal focusing, limited only by the bandwidth of the control pulse. The influence of the exact value of appears to be rather insignificant, except for the peri- odic limit ( = 0.1%) where the penetration of the control pulse inside the sample is largely prohibited. The calculated two-photon field intensities are shown in the lower plots of Fig. 3 for different arrival times of the pump pulse at the front layer, relative to the arrival time of the unshaped control pulse. For delay times earlier than around 2 ps, the two-photon intensity is not spatially localized, since the pump pulse overlaps largely with the forward traveling portion of the shaped control field. However, as soon as the pump is sufficiently delayed, its overlap with the backward propagating control results in a focused two-photon intensity (thin bright trace at the lower half of the plot). The lower limit of the spatial size of the focused two-photon intensity is again determined by the frequency bandwidth of the pump and control pulses. The focusing location can be tuned continuously across the front half of the sample. The target point of backscattering sets an upper limit for the position of the nonlinear focus. In the periodic limit, no control over the two-photon field can be achieved due to the inhibited light penetration into the stack.
Very similar one-photon control field trajectories and two-photon signal maps are plotted in Figures 4 and 5 using the two feedback-based shaping methods. In Fig. 4, we optimize the phase mask so as to maximize the intensity of the backward propagating control field at the location of the 50th air layer. In Fig. 5, the same adaptive optimization is then repeated with a more practical feedback parameter -the intensity of the backscattered control pulse as it exists the very front layer after a fixed delay of 6 ps, set in accordance with the results of the feed-forward scheme. Note that the exact value of this delay is of little importance since the arrival time is easily controlled by adding a linear spectral phase tilt to the adaptive shaping mask. For both optimization methods, we used the "minimize" algorithm from SciPy's "optimize" library. The results demonstrate that both methods are capable of generating the backscattered pulse and producing the desired two-photon focusing similarly to the feedforward-based procedure. Furthermore, the methods proved equally successful for many different realizations of the stack geometry, indicating their robustness with respect to the randomness of the system.

Depth of Focusing and Shaping Resolution
Since the enhanced backscattering, described above, is achieved via constructive interference of backward propagating waves at a target location, its efficiency should depend on the availability and strength of localized modes at that location. One would therefore expect the efficiency of our method to decrease when the reflection point of control pulses is pushed deeper into the stack (cf. Fig. 1c). This trend is apparent in Fig. 6 for a stack with = 90%: as we move the target location from 30th to 45th, 60th and finally 75th air layer, the reflection point follows along, but the backscattered intensity is dropping. Hence, the control range for the focused two-photon field can be extended only at the expense of its lower strength.
Arranging for constructive interference within local- ized modes also depends on the spectral resolution, with which individual spectral phases can be varied. To analyze this dependence, we implement our feedforward method and change the resolution of a numerical pulse shaper from 0.07 nm to 0.33, 0.67, 1 and 1.3 nm, the latter being of the order of the average wavelength separation of the localized modes. The results are shown in Fig. 7 for a random stack with = 20%. The detrimental effects of insufficient resolution to control individual spectral components within each single localized mode are clearly seen through the disappearance of the backscattered wave in the right most plot.

III. CONCLUSION
In conclusion, we have developed a systematic technique to achieve spatial focusing of a multi-photon field inside a 1D layered random medium. Our approach relies on creating a strong backscattered pulse originating from inside the random sample by means of the spectral pulse shaping. The method is demonstrated numerically for random stacks whose parameters are known a priori, as well as using adaptive optimization algorithms that maximize the backward-propagating light intensity, either internally or at the very front layer of samples with unknown geometry. By colliding the controlled backscattered pulse with a time-delayed forwardpropagating pump, spatially localized two-photon field is established in a range of target locations. We have demonstrated the robustness of the proposed technique with respect to the degree of disorder. It works well both on a single-realization level and when statistically averaged over many realizations of the random medium. The location of the focused two-photon field can be easily controlled within (but not much beyond) the first half of the sample, as determined by an optimum reflection point for the spectrally shaped control pulse. This limit originates from the fundamental phe-nomenon of light localization in one-dimensional random structures. We also show that the required resolution of the spectral pulse shaping is dictated by the average frequency bandwidth of the localized modes. When the shaping resolution falls below this limit, the ability to control the interference of backward-propagating components is lost, and the efficiency of the proposed focusing method deteriorates.
One direct application, which served as a motivation for this study, is to induce and control local pumping inside a 1D random laser by means of the spectral pulse shaping and with no optical access other than the front layer of the sample. This ability should allow selective excitation of different lasing modes at different spatial locations, and would therefore provide control over the lasing frequencies. Other potential applications may include two-photon fluorescence imaging in layered structures, and can be extended to other scenarios of multiphoton light-matter interaction in random media.