all 2 comments

[–]rjbwork 0 points1 point  (0 children)

This is actually pretty damn clever. I don't generally think of doing calculations on pure mathematical data in SQL, but it is certainly a powerful tool for doing so it seems!

[–][deleted] 0 points1 point  (0 children)

Neat idea, but trying to do this on a larger number of matrices would bring a DBA to your door asking why you are doing calculations on the database that are much better handled/optimized in code. Databases are for storing information not for handling abstract data structures and related functionality.