Implicit DAE Mass Matrix Python
Since the mass matrix is singular, this is a "differential-algebraic equation".  You can find off-the-shelf solvers for DAEs, such as the IDA solver from the SUNDIALS library.  SUNDIALS has python bindings in the scikit.odes package.
I have a problem M*y' = f(y) that are going to be solved in Python, where M is the mass matrix, y' the derivative and y is a vector, such that y1, y2 etc. refers to different points in r. 
Have anyone used a mass matrix on a similar problem in Python?   
The problem is a 2D-problem in r- and z-direction. The r-direction is discretized  to reduce the problem to a 1D-problem. The mass matrix is a diagonal matrix with ones and zeros on the diagonal.