Second-Harmonic Generation

by Dmitrii Nabok for exciting neon

Purpose: In this tutorial you will learn how to initialize and perform calculations of the second order susceptibility tensor with exciting. As an example, we compute the second-harmonic generation (SHG) spectrum of GaAs.

Second-harmonic generation

Copy and paste the following exciting input data into input.xml.

   <title>GaAs SHG</title>
   <structure speciespath="$EXCITINGROOT/species">
         <basevect>5.3435 5.3435 0.0000</basevect>
         <basevect>5.3435 0.0000 5.3435</basevect>
         <basevect>0.0000 5.3435 5.3435</basevect>
      <species speciesfile="Ga.xml" rmt="2.0">
         <atom coord="0.00 0.00 0.00"/>
      <species speciesfile="As.xml" rmt="2.0">
         <atom coord="0.25 0.25 0.25"/>
      ngridk="8 8 8"
         <chicomp>1 2 3</chicomp>

Make sure to set $EXCITINGROOT to the correct exciting root directory in the speciespath attribute using the command


Please get first familiar with the input parameters related to the shg element. Note that all required components of the second-order susceptibility tensor $\chi_{abc}^{(2)}(-2\omega,\omega,\omega)$ can be specified by adding corresponding chicomp combinations where $a,b$, and $c$ stand for the Cartesian indices (1=x, 2=y, 3=z).

Run exciting in the usual way.

$ time exciting_smp &

As an example, we present results for $\chi_{xyz}^{(2)}(-2\omega,\omega,\omega)$ (which can be found in the output file CHI_123.OUT). Note that this file contains information about the frequency dependence of the real, imaginary, and absolute value of the corresponding tensor component given in the units of 10-7 esu. In the literature, one would often find the second-order susceptibility in the units of nm/V. Please notice the conversion factor: 1 nm/V = 23.86x10-7 esu. For tutorial purposes, the results could be visualized by executing

$ CHI_123.OUT

The resulting plot is saved in the files PLOT.png and PLOT.eps, which should look like the following image:

  • Converge the SHG spectrum with respect to ngridk.
  • Try different components of the SHG susceptibility tensor noting that many of them are actually zero due to crystal symmetry.


  • J. L. P. Hughes and J. E. Sipe, Phys. Rev. B 53, 10751 (2003)
  • S. Bergfeld and W. Daum, Phys. Rev. Lett. 90, 036801 (2003)
  • S. Sharma and C. Ambrosch-Draxl, Physica Scripta T109, 128 (2004)
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License