Unit tests for matrix.go - not completed.
Skeleton for future buffer functions