in reply to solving linear equations

I haven't used PDL, but Math::Matrix might suit your needs. You mention that speed is important, so a couple of caveats: it's written purely in Perl (no optimised C code; I don't know if PDL or any other matrix module uses optimised C code), and the equation solver uses the Gauss Jordan elimination algorithm which has a run time of O(n^3). This last point is probably only important if you're using very large arrays... you didn't mention this, though, so I'm guessing you're using only relatively small arrays with fewer than (say) 30 unknowns. If that's the case, the Gauss-Jordan will most likely be fast enough.

As for your example of the sorts of systems you want to solve, I take it that each equation you gave represents a complete set of simultaneous equations? It wasn't clear, but I wondered whether you meant that all three matrix equations needed to be solved together rather than individually. If that is the case, can you rewrite the equations to involve only one matrix (the co-efficients) times a vector (of unknowns) = a vector (the result)?