At TPC in Glasgow, I held two talks (slides and video stored or linked to my domain as linked on conference site) about my module, Perl6::Math::Matrix. To me, the most interesting parts of this talk were musings about how to write a good API in and for Perl 6. And since I already got a lot of good suggestions from the audience (which are all implemented by now [by the critic or me]), I will write here a series of posts about this topic and maybe get some more inspirations. Basic Properties As said during the talk, the basic design decisions were to see the Matrix as an array of arrays and a read-only data object. This allows me to cache all lazy evaluated, computation-heavy properties and not worry about them changing. It also forces me to create new Matrix objects when computing derivative matrices.