We describe a spectrogram-based simulated annealing algorithm for designing quasi-phase-matched crystals capable of producing second harmonic generation pulses of any chosen amplitude and phase profile. The approach applies a new and rapid analytic method for calculating the amplitude and phase of the second harmonic generation pulses generated by a quasi-phase-matched crystal containing an arbitrary grating design. The performance of the algorithm is illustrated by examples of femtosecond second harmonic pulses designed according to various target shapes including single, double and triple Gaussian pulses, positive and negative linear chirp and square, triangular and stepped profiles.
©2005 Optical Society of America
For many applications involving ultra-short laser pulses it is attractive to have a degree of control over the intensity and phase profiles of the pulses. For this purpose, arbitrary pulse shaping strategies have been demonstrated in several different forms including adaptive optics [1,2], space-to-time converters  and by an acousto-optic programmable dispersive filter , and in this paper we introduce a new form of arbitrary pulse shaping based on second-harmonic generation (SHG) in quasi-phasematched (QPM) nonlinear crystals. In this context, by arbitrary pulse shaping we refer to the facility of the crystal designer to program any desired SHG output pulse shape and chirp. A particularly novel aspect of the method presented here is that it employs the pulse spectrogram (or frequency-resolved optical gating (FROG) trace) within the crystal design procedure to ensure close agreement between the design SHG pulse and the target pulse.
The initial progress towards arbitrary pulse shaping using QPM SHG crystals was in work by Arbore et al. , who theoretically demonstrated that by using a QPM crystal containing a linearly-chirped grating it was possible to generate a compressed SHG output pulse from a chirped input fundamental pulse (FP). This method was subsequently demonstrated experimentally in chirped-periodically-poled lithium niobate (PPLN) to achieve ~154 -fold compression of chirped 1560nm pulses from an Er:fibre oscillator . Subsequently, this method was further investigated both experimentally and theoretically for SHG [7,8], optical parametric oscillators [9,10] and optical parametric amplifiers . Linearly chirped QPM crystals were also successfully applied to generate ultra-short SHG pulses with durations of only 6 fs from 8.6 fs Ti:sapphire laser pulses [12,13]. Other work studying pulse shaping and compression by SHG QPM crystals was investigated under some more general conditions taking into account the group-velocity dispersion (GVD) and group-velocity mismatch (GVM) of the interacting pulses [14,15] and similar work was also reported dealing with pulse shaping by difference-frequency generation .
Despite the growing body of work in the topic, studies concerned with the conversion properties of truly arbitrary grating designs have been limited and mainly restricted to examining the effects of domain errors in SHG conversion efficiency . In all of the previous works the principal emphasis has been on pulse compression or bandwidth enhancement, rather than on the more general question of completely engineerable pulse shaping. In the original theoretical description of pulse compression during SHG  an analytic approach was presented for calculating the shapes of pulses produced by the simultaneous compression and SHG of an input pulse in a QPM crystals but this analysis restricted itself to the special case of linear chirp. Recently we reported  a new analytic approach for designing QPM crystals with an engineerable SHG spectral response and other parallel work described a related method for designing aperiodically poled lithium niobate crystals capable of supporting parametric amplification at multiple wavelengths . In a development of our earlier work we now describe a new and rapid analytical approach for exactly calculating the amplitude and phase of the SHG pulses generated from any arbitrary input fundamental pulses by an arbitrary QPM grating. By applying this method we show how it is possible to design a QPM crystal capable of producing SHG pulses of any chosen amplitude and phase profile. In all cases our results are compared with solutions obtained by carrying out a conventional numerical pulse propagation simulation based on solving the coupled-wave equations.
The outline of this paper is as follows: Section 2 describes the theoretical concepts and necessary formulas used in calculations. Section 3 presents the simulated designs and Section 4 presents some brief conclusions.
2. Transfer function description of SHG pulse shaping in QPM crystals
The SHG of ultrashort laser pulses is readily described by using a transfer-function formalism that relates the SHG spectrum to the spectrum of the fundamental pulses when the depletion of the FP is negligible. The transfer function depends only on material properties and on the QPM grating design and has been described for the cases of perfectly-phasematched crystals and an arbitrary fundamental spectrum [20, 21], a uniform QPM grating  and a linearly chirped QPM grating . The transfer function model is only valid for small (few percent) conversion efficiencies but we note that recently a new method was reported that correctly described the SHG of short laser pulses up to 90 % conversion efficiency  by using an approach related to the transfer-function method. Following our earlier work  the crystal response of an arbitrary SHG quasi-phase-matched crystal containing n alternately-inverted domains can be described as:
where κ=-ωSHG /cnSHG , dijk is the absolute value of the nonlinear coefficient, ωSHG and nSHG are, respectively, the carrier frequency and refractive index of the SHG pulse and Q=[q 1,q 1+q 2,q 1+q 2+q 3,…,q 1+…+qn ] is a vector containing the end position of every domain as shown in Fig. 1.
The frequency-dependence of the wave-vector mismatch is shown as Δk(Ω) where Ω is the difference between the carrier frequency of the pulse and the frequency of any given spectral component of the pulse. Arbore et al  showed that the Fourier transform of the second-harmonic pulse is given by:
where F is the Fourier-transform operator and E 1 (t) is the complex amplitude of the fundamental input pulse. By combining Eq. (1) and (2) it is therefore possible to accurately predict the exact amplitude and phase of the SHG pulse generated by combining any input pulse with any quasi-phasematched crystal simply by taking the inverse Fourier transform of Eq. (2):
In order to test the validity of this approach at low (few-percent) conversion efficiencies we combined a set of chirped and unchirped input fundamental pulses with different chirped, unchirped and randomly structured QPM gratings and compared the output SHG pulse shapes calculated according to our new method with those determined by a standard pulse propagation simulation. The conventional approach to predicting the SHG pulse shapes generated by quasi-phasematched crystals is to use a split-step Fourier-transform method  which simultaneously solves the two coupled equations :
where Δko =Δk Ω=0 and the coefficient σ(z) is the spatially changing polarity of the domain orientation. The group velocity of wave i is νi =1/k′i , where k′i =dki /dωi and the group velocity dispersion is k″i =d 2 ki / (here, i=1 represents the fundamental wave and i=2 represents the SHG wave). This approach is able to take account of the depletion of the fundamental pulse and the effect of GVM between the fundamental and second-harmonic pulses but is computationally intensive, typically taking several minutes to run on a fast personal computer if a reasonable resolution is required. By contrast, we note that the frequency-dependent wave-vector mismatch, Δk(Ω), present in the analytic model (Eq. (1)–(3)) implicitly ensures that GVM is included because ∂(Δk(Ω))/∂ωSHG =1/vSHG -1/vFP where vFP and vSHG are the group velocities of the fundamental and second-harmonic pulses respectively. In our numerical implementation of Eq. (4) we used a step size of typically 1/15th of the domain width used in the QPM grating design and this allowed us to exactly calculate change of the amplitude and phase of the SHG process during propagation through crystal under arbitrary QPM conditions. Numerical pulse propagation is necessarily computationally intensive but, by contrast, the new analytic method we describe here is highly efficient, running in a fraction of the time taken by the conventional calculation and consisting of no more than a summation followed by two fast Fourier transforms.
Five different cases were compared in order to test the ability of our alternative method to predict the shapes of the resulting SHG pulses. For the purposes of this study we chose to perform the simulations in QPM lithium niobate crystals and used fundamental Gaussian-profiled pulses with a wavelength of 1530nm and transform-limited durations of ~150fs. The simulations concentrated on crystals with a length of ~5mm containing 500 domains. The chirp on each crystal is represented in our results as the difference, Δqm , between the domain width at any position and the domain size for exact QPM, 9.11µm. Fig. 2 shows the full results obtained and is organised according to rows and columns. Each row represents a separate combination of crystal grating design and input pump chirp while the columns (from left to right) depict: (a) the SHG pulse temporal intensity and phase profile; (b) the intensity and phase of the crystal transfer function Ecrys (Ω) expressed in terms of the SHG wavelength; (c) the percentage converted power with propagation distance in the crystal, and; (d) the variation from the exact QPM period of the domain size distribution in the crystal. The cases studied (in row order of Fig. 2, beginning with the top row) were: (i) an unchirped grating and an unchirped fundamental pulse; (ii) a linearly positively chirped grating and an unchirped fundamental pulse; (iii) a randomly perturbed grating and an unchirped fundamental pulse; (iv) a linearly positively chirped grating and a positively chirped fundamental pulse, and; (v) a linearly positively chirped grating and a negatively chirped fundamental pulse. In all of the results, solid lines denote the new model and the symbols (‘*’) represent the results of a conventional pulse propagation model. In all cases the agreement between the two models is very close, demonstrating that the simple model is more than adequate for predicting the pulse shapes produced by QPM SHG. From these results, it is clear that the proposed analytic method can exactly describe the SHG process even in the case of a randomly structured grating design. It is also evident that the SHG pulse is compressed (Fig. 2(iv)) and stretched (Fig. 2(v)) by a chirped grating exactly as is expected. The results also show that the new method can exactly describe the SHG nonlinear frequency conversion process when the efficiency of conversion is less than a few percent.
3. Designing aperiodic QPM gratings to create target pulse profiles
The ability to rapidly calculate the output SHG pulse profile resulting from any QPM grating design naturally lends itself to an iterative strategy for determining the QPM grating design needed to achieve any target SHG pulse shape. Recent theoretical work in this area has applied an optimal control method to tailor the shape of ultrashort SHG pulses by using a spatially varying nonlinear coefficient, however only unchirped fundamental and SHG pulses were considered . We have implemented a different approach by using a variation of the well-known simulated annealing algorithm  to find the grating design needed to generate any chosen SHG target pulse from a pre-defined fundamental pulse. The simulated-annealing method is particularly appropriate because it allows a large number of parameters (in our case the set of domain positions, Q) to be simultaneously optimised. In our earlier work  we described how a simulated-annealing approach could be used to design a QPM crystal with any target crystal response, Ecrys (Ω), and we now extend this approach to the general case of finding the crystal design needed to yield a SHG pulse with any chosen intensity and phase profile.
The simulated-annealing algorithm is one of a group of stochastic optimization algorithms which is well-suited to finding a global minimum (or maximum) of some objective error function. It is normally sufficient to define the error function as a single number whose value indicates how close any solution is to the target. In the context of SHG pulse design, we require a means of capturing, in a single number, the agreement between a target SHG pulse design and the pulses produced by any QPM grating design under test. For this purpose we used a polarisation-gated frequency-resolved optical gating (PG-FROG) spectrogram  because this provided an objective function which is sensitive to the pulse intensity and phase profile and also to the polarity of the pulse chirp. A single objective error value is easily determined by taking the root-mean-squared (RMS) error between the PG-FROG traces of the target pulse and the pulse produced by any QPM grating. It should be mentioned that other methods of comparing two pulses are possible, for example taking the RMS error between their intensity profiles or their spectra, but in our experience these did not always yield satisfactory results. The PG-FROG spectrogram can be described by the following integral equation :
The size and position of every domain in a QPM crystal, together with the intensity and phase profile of the fundamental pulse, directly determine the characteristics of the SHG output pulse. To design a QPM crystal for generating an arbitrary target second-harmonic pulse we therefore begin by choosing an appropriate fundamental pulse and creating an initial guess for the crystal domain pattern. For convenience we typically chose a linearly chirped pattern containing 500 domains, corresponding to a crystal length of around 5mm. The target pulse was defined in the time-frequency domain as a PG-FROG spectrogram and a simulated-annealing strategy is used to minimise the root-mean-square error between the PG-FROG trace of the target pulse and that of the second-harmonic pulse predicted for the QPM crystal according to:
On each (k th) iteration of the algorithm, every crystal domain was randomly perturbed by up to 1% and the modified design accepted or rejected on the basis of the implied change to the error, ek . Fig. 3 illustrates the algorithm. The procedure was run iteratively until (typically) ek <0.005, at which point the QPM grating design obtained was assumed to represent the best possible for generating the target pulse. The domain sizes throughout the crystal are represented by the vector P=[q 1,q 2,q 3,…,qn ] and P o is the optimum QPM design for each case.
In order to test the performance of the method we used the same FP already described in Section 2 and chose nine different target SHG pulses in femtosecond range. The spectral bandwidth of the FP must be at least as large as the spectral bandwidth of the target pulses, otherwise convergence is only possible at very low efficiency. The targets are illustrated in Fig. 4 and were: (a) a 150fs Gaussian pulse; (b) a 200fs Gaussian pulse; (c) a 150fs Gaussian double-pulses with a separation of 150fs; (d) a 150fs Gaussian triple-pulses with separations of 150fs; (e) a positively chirped 300fs Gaussian pulse se (ϕ′~7000 fs2); (f) a negatively chirped 300fs Gaussian pulse (ϕ′~-7000 fs2); (g) a 400fs square pulse; (h) a 200fs triangular pulse, and; (i) a 400fs stepped square pulse. For each target case we have plotted in Fig. 5–8 the results of the simulated annealing algorithm. Each figure follows a similar format with the columns representing (from left to right): the PG-FROG spectrogram of the target pulse; the calculated PG-FROG spectrogram of the best SHG pulse; the SHG power evolution through the crystal calculated by numerical code (symbols) and the new analytic method (solid curve), and; the distribution of domain sizes throughout the crystal. The typical iteration time required for each design was around 25–45 minutes, depending which target was chosen.
The results in Fig. 5 compare the success of the algorithm in designing gratings that generate transform-limited SHG pulses with durations of 150fs and 200fs (Fig. 5(a) and 5(b) respectively). It is evident from the conversion efficiency results that the shorter target pulse duration cannot be produced as efficiently as the longer one. This result is explained by the need to create a wider full-width half-maximum bandwidth in order to produce a shorter SHG pulse and this need can only be satisfied by a QPM grating design that suppresses conversion of the most intense central wavelengths present in the fundamental pulse.
Figure 6 shows the results obtained when the algorithm was used to create double and triple pulses and the agreement between the target and generated PG-FROG traces is good in both cases. The plots of the power evolution through the crystal in both cases indicate that the optimum solution to the problem of multiple pulse creation is by a cascaded conversion process. This conclusion is further supported by the distribution of the domain sizes throughout the crystal which in the double-pulse case take the approximate form of two linearly chirped gratings and, in the triple-pulse case, of three such gratings.
The results described so far have tested the capacity of the algorithm to satisfy target intensity profiles but it is important that the algorithm can also be used to design gratings that produce SHG pulses with any chosen phase profiles. It is well known that linearly chirped gratings of opposite polarity will produce, from an unchirped input pulse, SHG pulses of opposite chirp. We tested this by comparing two target pulses that were identical except for the sign of their linear chirp. Figure 7 shows the results obtained when an unchirped QPM grating was used as the initial guess. An initially linearly chirped grating could also be used but took longer to reach convergence than the unchirped grating.
Finally the capacity of the algorithm for generating sharp-edged features in the SHG pulses was investigated by choosing targets of square, triangular and stepped pulses (see Fig. 8). The results show close agreement in all cases but the most difficult case was that of the stepped square pulse because of the high spectral frequencies needed to synthesise this shape. Sharp edged pulses imply substantial spectral wings/sidelobes and in the SHG process the bandwidth of the available frequencies is necessarily restricted by the bandwidth of the original input pulse.
A general observation arising from the results presented in Section 3 is that the optimum QPM crystal length varies depending on the target pulse required. This effect is already well known for the simple case of QPM-SHG pulse compression in which, given a FP of a fixed spectral bandwidth, compressing a more highly chirped FP requires a physically longer crystal so that the necessary GVM can be supplied. Thus, input pulses with identical spectra but possessing differing chirps can only be compressed to a common transform-limited target shape by using different lengths of QPM crystal. Turning this argument around, a common input pulse can only generate different SHG target pulses by using different lengths of QPM crystal. The less pulse-shaping required of the QPM crystal then the shorter is the crystal that is required until the crystal becomes short enough that its intrinsic bandwidth is sufficient to give conversion without any significant aperiodicity in the QPM grating. In all cases we ran the simulated annealing algorithm with a constant number of domains but found that for some designs there was a region at the end of the crystal over which little conversion or back-conversion occurred and, consequently, which did not contribute to the SHG. The optimised crystal design was therefore considered to be only the part of the crystal that contributes to conversion and, for the reasons already outlined above, this optimum length varied from one design to another.
A practical question arises over the potential of accurately realising any of the QPM crystal designs in an experiment and the limitations on the experimental realisation result from two main sources. The first is a random experimental error in the domain sizes in the sense that it is impossible to guarantee that the sizes of the experimentally poled domains will match those of the design. Fringing electric fields at the edges of the grating lines present on the poling electrode can lead to domain spreading in the poling process which causes random perturbations of the domain sizes but fortunately the QPM conversion result has been shown  to be robust to this kind of error because no net phase error can easily accumulate. The second is that the result of the computational design procedure is a QPM grating with the positions of domains specified with very high precision. In reality the lithographic mask used to pole a real crystal can only be fabricated with (at best) around 0.05µm precision and so it is necessary to first computationally test that when the domain positions in the initial design are represented to only this precision that the crystal still produces the target pulses as expected. We have confirmed this to be the case for designs with domain positions represented to a precision of 0.1µm and found that the crystal behaviour is remarkably robust.
In summary, we have described a new and practical method for modelling femtosecond SHG in QPM crystals and have found that the results of the method are in good agreement with a complete numerical nonlinear propagation procedure, where the group velocities and group velocity dispersions of the interaction pulses were taken into account. By applying the rapid calculation of the output SHG intensity we have shown that an iterative simulated annealing algorithm can be applied to design QPM crystals capable of producing any desired SHG pulse. The success of this approach is attributed to our use of a PG-FROG spectrogram that allows a more accurate calculation of the error between the guess and target pulses than would a comparison made only in the time or frequency domain. We believe that the results of this work may present new opportunities for engineering SHG crystals with unique properties that enable novel sources and pulse measurement techniques to be realised.
The authors are grateful to the Royal Society and NATO for U. K. Sapaev’s visiting research fellowship.
References and links
1. A. M. Weiner, D. E. Leaird, J.S. Patel, and J.R. Wullert, “Programmable shaping of femtosecond optical pulses by use of 128-element liquid crystal phase modulator,” IEEE J. Quantum Electron. QE-28908–920, (1992) [CrossRef]
2. E. Zeek, K. Maginnis, S. Backus, U. Russek, M. Murnane, G. Mourou, H. Kapteyn, and G. Vdovin, “Pulse compression by use of deformable mirrors,” Opt. Lett. 24, 493–495 (1999) [CrossRef]
3. A.M. Weiner and A.M. Kanan, “Femtosecond Pulse Shaping for Synthesis, Processing, and Time-to-Space Conversion of Ultrafast Optical Waveforms,” IEEE J. Quantum Electron. QE-4, 317–331 (1998).
4. F. Verluise, V. Laude, Z. Cheng, Ch. Spielmann, and P. Tournois, “Amplitude and phase control of ultrashort pulses by use of an acousto-optic programmable dispersive filter pulse compression and shaping,” Opt. Lett. 25575–577 (2000) [CrossRef]
6. M. A. Arbore, A. Galvanauskas, D. Harter, M. H. Chou, and M. M. Fejer, “Engineerable compressionof ultrashort pulses by use of second-harmonic generationin chirped-period-poled lithium niobate,” Opt. Lett. 22, 1341–1343 (1997). [CrossRef]
7. P. Loza-Alvarez, D. T. Reid, P. Faller, M. Ebrahimzadeh, and W. Sibbett, “Simultaneous second-harmonic generation and femtosecond-pulse compression in aperiodically poled KTiOPO 4 with a RbTiOAsO 4 -based optical parametric oscillator,” J. Opt. Soc. Am. B 16, 1553–1560 (1999). [CrossRef]
8. P. Loza-Alvarez, D. T. Reid, P. Faller, M. Ebrahimzadeh, W. Sibbett, H. Karlsson, and F. Laurell, “Simultaneous femtosecond-pulse compression and second-harmonic generation in aperiodically poled KTiOPO 4,” Opt. Lett. 24, 1071–1073 (1999). [CrossRef]
9. T. Beddard, M. Ebrahimzadeh, D. T. Reid, and W. Sibbett, “Five-optical-cycle pulse generation in the mid infrared from an optical parametric oscillator based on aperiodically poled lithium niobate” Opt. Lett. 25,1052–1054 (2000) [CrossRef]
10. D. Artigas and D.T. Reid, “Efficient femtosecond optical parametric oscillators based on aperiodically poled nonlinear crystals” Opt. Lett. 27851–853 (2002). [CrossRef]
11. D. Artigas, D. T. Reid, M. M. Fejer, and L. Torner, “Pulse compression and gain enhancement in a degenerate optical parametric amplifier based on aperiodically poled crystals “Opt. Lett. 27, 442–444 (2002) [CrossRef]
12. L. Gallmann, G. Steinmeyer, U. Keller, G. Imeshev, M. M. Fejer, and J. P. Meyn, “Generation of sub-6-fs blue pulses by frequency doubling with quasi-phase-matching gratings” Opt. Lett. 26, 614–616 (2001). [CrossRef]
13. L. Gallmann, G. Steinmeyer, G. Imeshev, J. P. Meyn, U. Keller, and M. M. Fejer. “Sub-6-fs blue pulses generated by quas-phase-matcheing second harmonic generation pulse compression” Appl. Phys. B 74S237–S243 (2002). [CrossRef]
14. G. Imeshev, M. A. Arbore, M. M. Fejer, A. Galvanauskas, M. Fermann, and D. Harter “Ultrashort-pulse second-harmonic generation with longitudinally nonuniform quasi-phase-matching gratings: pulse compression and shaping “J. Opt. Soc. Am. B 17, 304–318 (2000). [CrossRef]
15. G. Imeshev, M. A. Arbore, S. Kasriel, and M. M. Fejer “Pulse shaping and compression by second-harmonic generation with quasi-phase-matching gratings in the presence of arbitrary dispersion” J. Opt. Soc. Am. B 17, 1420–1437 (2000). [CrossRef]
16. G. Imeshev, M. M. Fejer, A. Galvanauskas, and D. Harter “Pulse shaping by difference-frequency mixing with quasi-phase-matching gratings” J. Opt. Soc. Am. B 18, 534–539 (2001) [CrossRef]
17. S. Helmfrid and G. Arvidsson “Influence of randomly varying domain lengths and nonuniform effective index on second-harmonic generation in quasi-phase-matching waveguides” J. Opt. Soc. Am. B 8797–805 (1991) [CrossRef]
18. D. T. Reid, “Engineered quasi-phase-matching for second-garmonic generation” J. Opt. A: Pure Appl. Opt. 5S97–S102 (2003) [CrossRef]
19. Y. Zang and B-Y Gu “Optimal design of aperiodically poled lithium niobate crystals for multiple wavelengths parametric amplification” Opt. Comm. 192, 417–425 (2001). [CrossRef]
20. W.H. Glenn, “Second harmonic generation by picosecond optical pulses” IEEE J. Quantum Electronics , QE-5284–290, (1969) [CrossRef]
21. E. Sidick, A. Knoesen, and A. Dienes. “Ultrashort-pulse second-harmonic generation. I. Transform-limited fundamental pulses” J. Opt. Soc. Am. B 121704–1078 (1995) [CrossRef]
22. E. Sidick, A. Knoesen, and A. Dienes “Ultra-short pulse second harmonic generation in quasi-phase matched structures” Pure Appl. Opt. 5709–722 (1996). [CrossRef]
23. G. P. Agrawal, “Nonlinear Fiber Optics”, 2nd Edn, (Academic Press)
24. A. Yariv “Quantum Electronics” 3rd end (New York: Wiley)
25. R. Buffa. “Transient second-harmonic generation with spatially non-uniform nonlinear coefficients”, Opt. Lett. 27, 1058–1060 (2002) [CrossRef]
26. W. H. Press, S. A Teukolsky, W. T. Vetterling, and B. P. Flannery “Numerical Recipes” 2nd end (Cambridge: Cambridge University Press)
27. D. J. Kane and R. Trebino, “Single-short measurement of the intensity and phase of an arbitrary ultrashort pulses by using frequency-resolved optical gating” Opt. Lett. 18, 823–825 (1993) [CrossRef] [PubMed]
28. M. M. Fejer, G. A. Magel, D. H. Jundt, and R. L. Byer, IEEE J. Quantum. Electron. 28, 2631 (1992) [CrossRef]