Fix an overflow caused by multiplying two ints.
Fix more integer overflows in sparse matrix implementation.
Add a test case for very large sparse matrix
Fix up review comments.
Coding standards / whitespacing cleanup
Merge pull request #126 from globaldawn/fix_downcasting_errors

Fix downcasting errors