Extending diodes_1D example to multi-layer structure

For the Potential only case, you should be able to use:
simple_physics.CreateSiliconOxideInterface
for setting continuity in the Poisson equation.

For the Drift-Diffusion case, you would use these functions to set continuity in the Potential, Electrons, and Holes across the interface:

simple_physics.CreateSiliconOxideInterface
simple_physics.CreateSiliconSiliconInterace

Note that the 2nd function sets the boundary condition that the electron and hole densities across the interface are continuous. Once this is working, you can explore the possibility of different boundary conditions, such as continuity in the quasi fermi levels.

Unfortunately, there is not an example for a diode, but you can see similar boundary conditions in testing/res2.py which solves for continuous Potential and Electrons across a resistor with 2 layers.

There are a few discussions in this forum concerning the setup of interface conditions, so you may want to refer to them to understand how the different interface types are supposed to work. For example:
Interface equation for tunneling current