pvTrace is an open-source Monte-Carlo ray-tracing software used to model luminescent materials -in particular LSCs -in which rays are created and followed from incidence to exit to generate a statistical distribution of ray outcomes. The original pvTrace code 81 , written in Python and developed by Daniel Farrell, 65 features a top-down architecture to compartmentalize material and optical properties. A schematic of the code architecture is shown in Figure . The ray-tracing occurs in a scene, which is a data structure consisting of nodes that can be designated as geometry or light. Within each geometry, general material properties such as refractive index can be defined, or more specific features such as surface characteristics, absorption/scattering coefficients for the waveguide, and absorption and emission spectra and/or emission direction for luminophores can be added. Each light source can be similarly tuned to have a specific direction, divergence, and wavelength spectrum. pvTrace conducts ray-tracing by tracking each generated ray through the defined geometries while displaying a 3D visualization of the simulation. Once ray tracing is complete, the predicted external photon efficiency (𝜂 !"# ) of the LSC for the defined parameters is calculated as: