Template the solve data structure on matrix type
This mr prepares for the duo solver, the full branch is in !1280 (merged) . It templates SolveBase on the matrix type: either full or diagonal. It turns out that this makes it possible to implement the duo solver with minimal changes to the algorithms. When DDECal or BdaDdeCal hands the data to SolveData, the templated SolveData will either store the full data (when it is of type FullSolveData) or throw away the off-diagonal elements (in case of DuoSolveData).
This should save a factor of 2 in memory during the solve, which is important for long and high-direction solves. The duo scalar solver is 1.6 times faster compared to the full scalar solver; the duo diagonal solver is even 1.9 times faster (when not using constraints).