Guidance Needed for Understanding Codes in DEVSIM

Hi everyone,

I hope this message finds you well. I am a recent graduate who completed my undergraduate studies last month and will soon begin my Ph.D. program. My upcoming research will focus on semiconductor simulation, which is why I am currently learning to use DEVSIM, an impressive and powerful tool in this field. I find the Python scripting interface quite convenient and efficient.

However, I’ve encountered difficulties understanding the example Python scripts and the underlying C++ source code. I have been grappling with these issues for about two weeks now.

Firstly, I am trying to grasp the meaning behind the Python scripts. Despite reading the entire manual twice, I still struggle to comprehend the concepts of the “node model” and the “edge model.” I am familiar with the basic steps of the finite volume method, but these specific models are not mentioned in that context. Additionally, I am unsure about the exact equation that the solve() function addresses. Although I suspect that it involves the drift diffusion equation, I would like to know its precise form. I have similar questions about other scripts.

To address these challenges, I have decided to delve into the C++ source code. However, this has proven to be even more challenging due to the sheer number of code files, leaving me uncertain about where to begin. I’ve attempted a method where I trace a Python script function, such as solve(), to its corresponding entry in CommandsTable.cc and then examine the related C++ functions it calls. Despite these efforts, I find myself overwhelmed by the numerous classes and the extensive use of class pointers, making it difficult to keep track of everything.

I am feeling quite frustrated at this point, but I am determined not to give up. That’s why I’m reaching out for help. Could you please guide me on how to effectively read and understand the code? Are there specific textbooks I should refer to, or additional knowledge I need to acquire?

I would like to express my sincere gratitude to the author, Juan, and all the developers for your significant contributions. This is my first time writing a letter in English, so I apologize if any of my wording is inappropriate.

Thank you for taking the time to read my message. I hope you have a wonderful day!

Warm regards,

Wong

Hello Wong,

Thank you for your interest in the software. The equations are implemented through the Python interface.

A good starting point is:
https://doi.org/10.1109/TED.2021.3094776

or its preprint:
https://doi.org/10.36227/techrxiv.14129081

It explains how the equations are composed of node and edge models. The edge model comes from the divergence theorem:
https://en.wikipedia.org/wiki/Divergence_theorem

This makes it possible to convert the volume integral of divergence quantity to the surface integral of a flux. So for the electric field:

\int \left( \nabla \cdot {\bf E} \right)~{\partial V} = \int {\bf E} ~ \partial S

You can them specify the electric field as an edge model.

Another important concept is Scharfetter Gummel method which is used to properly treat the drift diffusion equations in a numerically stable way.

https://github.com/devsim/devsim_misc/blob/main/devsim_docs/TCADdocs.pdf

A very important reference book is:

Analysis and Simulation of Semiconductor Devices by Siegfried Selberherr

An extended example for a bipolar transistor is presented here:

https://github.com/devsim/devsim_bjt_example

https://zenodo.org/records/4582739

Please let me know if this is helpful and if you have any additional questions.

Thank you for your reply. I will thoroughly review the materials you provided. Wishing you a good day!