UnitTests addPrototype: #Matrix derivedFrom: {TestCase}. "3x3 Matrices" UnitTests Matrix addSlot: #affineScale valued: (Matrix newFromArrayOfArrays: {{2 . 0 . 0} . {0 . 2 . 0} . {0 . 0 . 1}}). UnitTests Matrix addSlot: #affineTranslate valued: (Matrix newFromArrayOfArrays: {{1 . 0 . 0} . {0 . 1 . 0} . {2 . 2 . 1}}). UnitTests Matrix addSlot: #affineRotate valued: (Matrix newFromArrayOfArrays: {{2 . 2 . 0} . {-3 . 3 . 0} . {0 . 0 . 1}}). UnitTests Matrix addSlot: #affineReflect valued: (Matrix newFromArrayOfArrays: {{1 . 0 . 0} . {0 . -1 . 0} . {0 . 0 . 1}}). UnitTests Matrix addSlot: #affineShear valued: (Matrix newFromArrayOfArrays: {{1 . 2 . 0} . {0 . 1 . 0} . {0 . 0 . 1}}). UnitTests Matrix addSlot: #affineTransform valued: UnitTests Matrix affineScale * UnitTests Matrix affineTranslate * UnitTests Matrix affineRotate * UnitTests Matrix affineReflect * UnitTests Matrix affineShear. UnitTests Matrix addSlot: #zero valued: (Matrix newRows: 3 columns: 3). UnitTests Matrix addSlot: #identity valued: (Matrix newIdentitySize: 3). "2x3 Matrices" "Column Vectors" "Bezier Curves" UnitTests Matrix addSlot: #bezierPoints valued: (Matrix newFromArrayOfArrays: {{1} . {2} . {3} . {4}}). "From wikipedia http://en.wikipedia.org/wiki/B%E9zier_curve" UnitTests Matrix addSlot: #bezierMatrix valued: (Matrix newFromArrayOfArrays: {{1 . 0 . 0 . 0} . {(1 / 2) . (1 / 2) . 0 . 0} . {(1 / 4) . (2 / 4) . (1 / 4) . 0} . {(1 / 8) . (3 / 8) . (3 / 8) . (1 / 8)}}). t@(UnitTests Matrix traits) testAddition [ t assert: t affineScale + t affineRotate = (Matrix newFromArrayOfArrays: {{4 . 2 . 0} . {-3 . 5 . 0} . {0 . 0 . 2}}). ]. t@(UnitTests Matrix traits) testMultiplication [ t assert: t bezierMatrix * t bezierPoints = (Matrix newFromArrayOfArrays: {{1} . {(3 / 2)} . {2} . {(5 / 2)}}). ]. t@(UnitTests Matrix traits) suite [t suiteForSelectors: { #testAddition. #testMultiplication. }].