Skip to main content

Substrate raytracer

What this tool does​

The substrate raytracer takes the particle flux that a DSMC or PIC-MC simulation delivers on a sampling plane and computes where that flux lands on a real part. Instead of a flat membrane it works with actual substrate geometries (lenses, disks, bent or slanted plates), with the motion of the part through the flux, and with masks that block part of the flux on purpose. The result is the local deposition rate on every patch of the part, which is what you compare against a measured thickness profile or feed into a mask optimisation.

It is a separate program from PICMC, distributed by Fraunhofer IST (version 0.2.0) and kept outside the PICMC source tree. It is written in C++ with a Python module, so a scenario is a normal Python script: you define geometry, trajectory, histograms and masks, run the loop, and evaluate the result with Python. That is also what makes the optimisation loop in the fitting section possible — the raytracer is a function you can call from a fitting routine.

Where this fits in the chain​

The raytracer is the deposition stage of the simulation pipeline: DSMC and PICMC deliver the flux, the raytracer puts it on the part, and the optimisation loop closes around it. What it does not do is the plasma physics, the sputter transport or the optical evaluation — those stay with PICMC, DSMC and the measurement.

Two ways to compute the deposition​

The matrix deposition described on the matrix deposition page and this raytracer solve the same problem and read the same histogram files. They are not the same code, and they are not interchangeable number for number.

Matrix deposition (in-framework)Substrate raytracer (this tool)
Where it runsInside the RVM run (MPROJECTOR module, .r script)Separate program, driven by a Python script
InputHistogram matrix from the sampling membraneThe same histogram files, loaded per batch
SubstrateMembranes from the GMSH geometry of the caseParametrised shapes (lens, disk, rectangle, torus, parabolic, custom mesh)
MotionTurntable trajectory from the scriptArbitrary circular, linear or custom trajectories, also per mask
MasksShielding in the case geometryFree mask polygons from nodes and circular arcs, mirrorable, movable
Concave substratesDepends on the geometryExplicit support, with precomputed self-intersections
OutputFields in the simulation, POS filesPython list, CSV, POS, plus GEO files for masks and trajectory
OptimisationNot built inMask parameters can be fitted with SciPy

Use the in-framework matrix deposition when the deposition is the last step of an existing RVM case and the substrate is a flat membrane or a simple shape. Use the raytracer when the part has a real shape, when the mask has to be designed or optimised, when the substrate or the mask moves in a way the script cannot express, or when you want to run the same deposition thousands of times inside a fitting loop.

Both start from the same histogram matrix, so the practical workflow is: run DSMC/PICMC, export the histogram files as described on the matrix deposition page, then decide which of the two consumers to use.

In this section​

PageContent
Getting startedBuild the tool, make the module importable, check an existing installation, run on a cluster
UsageCoordinate system, substrate, trajectory, histograms, masks, running the loop, output
Fitting with SciPyTurn a scenario into a goal function and optimise mask parameters
SubstratesAll parametrised shapes with their parameters and the exact parametrisation
Helper moduleTrajectories from RPM and speed, uniformity metrics, mesh import
AlgorithmHow a ray is cast, how masks and concave parts are handled

Limits​

  • The mask is a closed polygon of circular arcs. Straight lines are approximated by a very large arc radius, which is fine visually but is still an arc.
  • Only the substrate and the masks move. Gas, target and field are static during a raytracer run — that is exactly why the inner optimisation loop is cheap and the outer one is not.
  • A histogram file has to carry all angle combinations for all slabs in one file, and the number of columns has to match size_x * size_y.