Skip to content

Future Design Changes

jrjohansson edited this page Oct 7, 2014 · 1 revision

Discussion on future design changes in QuTiP

This page contains a list of design issues in the QuTiP code base that might require changes in future versions of the software. None of these changes are likely to happen anytime soon, but it would be important to start writing down know issues and short-comings and discuss various possible solutions at an early stage.

Qobj

The Qobj class is central in QuTiP.

  1. Qobj.dims is perhaps a too simple model for representing an increasing number of Qobj types. This issue was raised in #241, which contains some discussion related to this.
  2. It might be worth exploring if Qobj, or parts of it, would benefit from being rewritten in (ported to) Cython.

Possible solutions?

Time-dependent operators (Hamiltonian and collapse operators)

QuTiP current sports no less than four different ways of defining time-dependencies of Hamiltonians and collapse operators, which are used in the evolution solvers and the class method Qobj.evaluate. Each method has its own advantages and disadvantages (flexibility - performance trade off). However, this diversity greatly increases the complexity of implementing a new time-evolution solver since a wide variety of cases has to be covered. This has already led to fragmentation with respect to which time-dependence formats are supported in different solvers (and also, that a few solvers do not support time-dependencies at all).

Possible solutions ?

  1. All time-dependency formats should probably be represented by a class (or hierarchy of classes) so that each solver had to deal with only one API for evaluating an Qobj expression at some time t (regardless of whether the evaluation dispatches to a python function call or to a JIT compiled cython function).