Matrix function contracts, equals contract, and fixed other contracts th...

...at were failing tests.
@isupeene 
`last_col.times`?  This is fine too though, really.