Physics 0.01: Object-oriented programming for exact diagonalization
A new system of library code is proposed and initiated. It is emphasized that the same terminologies as we find in our textbooks should be used for class names in the library code. This proposal is inspired by .NET of Microsoft. Several rules of thumb are suggested in order to obtain easy-readable coherent codes. As a first step, we present the library code for exact diagonalization in physics. When we build codes, we distinguish between model independent and dependent parts. For the model independent parts, we use the familiar terminologies like Hamiltonian, HilbertSpace, GroundState, etc as class names. As an explicit example, we calculate ground state energy of a quantum dot, showing the triplet-singlet transition.
object-oriented programming exact diagonalization net c#