I outline here my (Gabriel Landi) personal philosophy concerning melt.

Code should be simple


We should be able to understand the functions we are using.

Know your blackbox


Most Input > Output functions can be viewed as blackboxes: we don’t care what is inside, as long as it spits out the correct answer.

Not all blackboxes are equivalent, however. Specially when physics is involved. Sometimes it is very useful to use a blackbox. Sometimes it is not a good idea at all.

Here are two examples:

Eigenvalues/Eigenvectors Quantum master equation solver
Well defined Mathematical operation Different ways of doing it (solve an ODE, apply matrix exponential, Trotterization, &c)
Uses extremely sophisticated methods to be efficient. Different solutions already use well-established methods (ODE, MatrixExp, &c.)
We do not necessarily learn much from understanding the algorithm. We learn a lot from understanding the solution. Rich in physics.
✅ Use a blackbox! ❌ Do not use a blackbox! Read the code!

Melt is based on simple implementations of basic functions, which can be understood by anyone working in the field.

What is the cost?


Simplicity, of course, comes at the expense of two things: Speed and Generality.

Take QuTIP (which I am a huge fan of) as an example. Its source code is very hard to read. But it can be super fast and super general.

About speed: