PreBasis constructor should produce a usable PreBasis
A PreBasis is not initialized completely after constructor call. We need to call initializeIndices()
before it can be used. (This is done in the DefaultGlobalBasis
in the constructor.)
Why not move the call to initializeIndices
into the constructor of the PreBasis, and maybe call it in the update()
method as well? This would mean that after construction and after update the PreBasis is in a valid state. Maybe there is a reason no to do this that I do not see, but it would simplify some code. Each PreBasis then should only initializes itself and not recursively call initializeIndices()
on all subBases.