The calculation of the optical response of multilayer thin films

A little while ago (while avoiding my thesis), I wrote a small R package for the calculation of the optical response of multilayer thin films. It’s called mlfilms and is avaliable on github.

As a quick example, here is how you’d calculate and plot the reflection from a thin silver film through a prism. This is a standard experiment in our lab which results in a reflectivity minima associated with a surface plasmon excitation.

Firstly, load up the package.


I’ll also load up ggplot and photonMonkey for plotting.


Then we simply construct a stack with an appropriate refractive index and thickness (45 nm), and calculate the reflection (the default covers an angle between 0 and 90 degrees), with incident medium set to glass.

layers<-list(index=c(0.13+4i),thickness=c(45e-9),repetitions= 1)


Plotting the result using ggplot shows a critical edge related to the onset of total internal reflection in the prism, and the reflectivity minima resulting from a surface plasmon excitation on the silver/air interface.


plot of chunk unnamed-chunk-4

This package uses the transfer matrix method for this calculation, as outlined in Pedrotti, Pedrotti and Pedrotti. Currently it only does reflection, not trasnmission.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s