Escape from Film (Part A): Ray tracing from a rough surface
The Escape from film example models light emitted inside a rough semiconductor film and calculates how much of that light escapes through the top surface. This is relevant to many systems such as OLEDs, LEDs, and other light-emitting structures where outcoupling is limited by total internal reflection and surface roughness.
Step 1: Create a new ray-tracing simulation
Start OghmaNano and click New simulation. The New simulation window appears, as shown in ??. Double-click the Ray tracing entry, highlighted in ??.
Step 2: Inspect the initial structure
After opening the example, the main OghmaNano window shows the device structure, as in ??. The scene contains:
- A rough semiconductor layer (red) on top of
- A smooth oxide layer (grey), and
- A purple grid above the device. This grid is an optical detector; any ray passing through it is recorded in the detector output files.
Use the left mouse button to rotate and the mouse wheel to zoom until you obtain the view shown in ??.
Step 3: Reveal the embedded light sources
By default the semiconductor and oxide are drawn as solid objects. To see where the light sources are located:
- Right-click the Semiconductor object.
- From the context menu choose View → Show solid and untick it.
- Repeat for the Oxide object.
The menu path is illustrated in ??. Once both solids are turned off, you should see a cloud of small arrows inside the film, as in ??. These arrows are the ray-tracing light sources.
Each arrow represents a group of rays emitted from that point. By right-clicking the light source object you can later adjust the number of rays, emission angle, and XY size of the source. We will return to this in Part B.
Step 4: Run the ray-tracing simulation
Click Run simulation (blue play icon) to launch the ray tracer. After a short time, the window fills with rays as shown in ??. The rays scatter inside the rough semiconductor and either escape into the detector or are lost in the substrate.
To examine how ray paths depend on wavelength, switch to the Optical tab. Use the Wavelengths drop-down to select a specific wavelength, as in ??. The 3D view updates to show only rays at the chosen wavelength.
Step 5: View the detector output
Once the simulation finishes, open the Output tab to see all files produced by the ray tracer, as
shown in ??. The detector plane
at the top of the structure is numbered 0, so its results are stored in
detector0.
Double-click detector0 to open the detector viewer
(??). This plot shows how much
light escapes through the detector as a function of angle and, if multiple wavelengths were simulated, as a
function of wavelength.
detector0 contains
the results from the top detector plane.
Detector efficiency and rendered images
The detector output shown in ??
is obtained by double-clicking the file detector_efficiency0.csv in the
Output tab. This plot shows the fraction of internally generated light that reaches
the detector as a function of wavelength – effectively an outcoupling efficiency.
In this example, almost no light escapes below about 600 nm, while at longer wavelengths
the outcoupling efficiency rises to around 12%.
A value of order 10–15 % is entirely reasonable for a high-index film in air. For a simple estimate, consider a flat semiconductor / air interface with refractive indices \(n_{\text{film}}\) and \(n_{\text{air}}\). The normal-incidence Fresnel reflectance is
\( R = \left(\dfrac{n_{\text{film}} - n_{\text{air}}}{n_{\text{film}} + n_{\text{air}}}\right)^2. \)
Taking a typical semiconductor or oxide index \(n_{\text{film}} \approx 1.8\) and \(n_{\text{air}} = 1.0\), we obtain \( R \approx 0.08 \) (about 8 % reflection at normal incidence), so the transmission is \(1-R \approx 0.92\). However, light generated inside the film can only escape within the escape cone defined by the critical angle \( \theta_c = \arcsin\!\bigl(n_{\text{air}}/n_{\text{film}}\bigr) \approx 34^\circ \). For isotropic emission inside the film, the fraction of power that falls inside this cone is
\( f_{\text{cone}} = 1 - \cos\theta_c \approx 1 - \cos(34^\circ) \approx 0.17. \)
Multiplying the transmission and escape-cone factors gives a crude outcoupling estimate
\( \eta_{\text{out}} \approx (1-R)\,f_{\text{cone}} \approx 0.92 \times 0.17 \approx 0.16 \; (16\%). \)
Once additional losses and scattering are included, an outcoupling efficiency of around
12 % – as seen in detector_efficiency0.csv – is therefore quite reasonable
for this type of structure.
If you double-click RAY_image.csv in the same directory, OghmaNano opens a
rendered image of what your eye would see when looking at the film, shown in
??.
This is calculated using the 1931 CIE colour space: the wavelength-dependent detector signal
is converted into CIE XYZ tristimulus values using the standard colour-matching functions, and
then mapped to an sRGB image that approximates human visual perception. For more details on
this colour model, see for example the
CIE 1931 colour space.
detector_efficiency0.csv. This plot shows the
wavelength-dependent outcoupling efficiency – the fraction of internally generated light
that reaches the detector.
RAY_image.csv. The detector spectrum has been converted into
a true-colour image using the 1931 CIE colour space, approximating what the human eye would
see when viewing the emitting film.
👉 Next step: Continue to Part B to learn how to change the surface shape, adjust the light source, and import more complex structures into the Escape from film simulation.