MATLAB-based mlSNLO software​

mlSNLO is a MATLAB-based version of the SNLO software (see the SNLO product page) with many upgrades.

mlSNLO comes in two flavors: a standalone version and a MATLAB-App version. The standalone version is compiled to run in the Windows or MacOS operating systems and does not require a current MATLAB license, while the MATLAB -App version does.

One notable difference between the two flavors of mlSNLO is that the MATLAB-App can be called from batch scripts while the standalone cannot. Batch scripts allow you to call any of the SNLO functions repeatedly with changing input parameters to automate parametric studies. The batch scripts are in the form of MATLAB .m-file scripts so they are very flexible. Twenty four examples are included to get you up and running quickly.

More information about how to use SNLO can be found in the short article SNLO_Introduction.pdf. SNLO has some examples and exercises provided in the Crystal Nonlinear Optics: with SNLO examples (second edition). A list of them is in SNLO Exercises and Examples.pdf. A prettier PDF of SNLO’s help function can be found in SNLO_help.pdf. Information on properties and applications of 150+ nonlinear crystals in 1000+ papers may be found in the bibliography Crystals.pdf.

License agreement for mlSNLO software

The current version of mlSNLO is V79.5.11 from June 25, 2024. See the changelog for more information.

Feature comparison chart

 Classic (free) SNLOmlSNLO MATLAB AppStandalone mlSNLO
Runs in Windowschecked[1]checkedchecked
Runs in Mac OSuncheckedcheckedchecked
Runs in Linuxuncheckedcheckedunchecked
Requires MATLAB installation & licenseuncheckedcheckedunchecked
Requires the free MATLAB compiler runtime [2]uncheckeduncheckedchecked
Includes fast and accurate thermal model for thermal lensing & tilt calculationsuncheckedcheckedchecked
Includes an optical parametric generator (OPG) modeluncheckedcheckedchecked
Includes d-effective surface plot with overlaid phasematch curve in the Bmix function (example screen shot below)uncheckedcheckedchecked
Offers batch runs of SNLO functions[3]uncheckedcheckedunchecked
Takes advantage of highly optimized numerical libraries for low execution times[4]uncheckedcheckedchecked
Takes advantage of hardware graphics acceleration for fast & attractive plottinguncheckedcheckedchecked
Allows for interactive zoom, pan, and rotation of 3D plotsuncheckedcheckedchecked
Labels the axes in 3D plots, and includes tick marks to enable quantitative interpretion of 3D plotsuncheckedcheckedchecked
Lets you save publication-quality plotsuncheckedcheckedchecked
Download it!
Buy it!
Buy it!

[1] Versions of Windows past Windows XP require the user to ensure that Data Execution Prevention is disabled for the executable file in the SNLO installation, but the end user might not have security privileges to modify this system setting. Additionally, some users report trouble printing from SNLO in Windows 10.

[2] The MATLAB Compiler runtime can be downloaded from, and will be automatically installed by the standalone mlSNLO installer.

[3] “Batch processing” here means generating SNLO results from a range of input parameters. In the MATLAB App version of mlSNLO, you can call each of the SNLO model functions from the MATLAB commandline with a full set of input parameters – the same input parameters which are visible on the SNLO input form. You can also run a command to simulate pressing the SNLO function’s buttons. This combination lets you create a program to automate the optimization of a nonlinear optical device. At least one batch processing example MATLAB script is included for each of the SNLO functions. One limitation of the standalone version of mlSNLO is that user-generated MATLAB scripts cannot be executed, meaning batch processing is not available in that version.

[4] Execution times are similar for both versions of MATLAB-based mlSNLO. In our comparisons, on a modern computer it takes roughly one fifth as long for complex 2D modeling (with an Intel Core i5 and 8 GB of memory). However, for the standalone version, the startup time for mlSNLO can be longer than that of the free SNLO version, and the memory used by the MATLAB Compiler Runtime itself is much larger than the free SNLO uses. We recommend computers have at least 8 GB RAM to use mlSNLO.

mlSNLO example screen shots