yep, this is what I was hinting at in post #2 ( also, being the trasnformation matrix sparse, the inverse can be computed equally well by directly computing the base, it's a just a matter of paying attention to the matrix borders ).

Quote Originally Posted by OReubens View Post
It would surprise me however this is the kind of solution your teacher is looking for.
why ? this looks like a typical linear algebra exercise ( at least in my country, linear algebra teachers have a notoriously sadistic attitude )