Discuss the theoretical principles of nonlinear optics, focusing on topics such as optical Kerr effect, harmonic generation, and soliton propagation, and their applications in nonlinear optical devices, optical communications, and laser spectroscopy.