move check_range to math/error_handling/matrix

#### Summary:
Addresses issue #828 

#### Intended Effect:
Move check_range out of math/matrix and into math/error_handling/matrix

#### How to Verify:
Check changed files.

#### Side Effects:
None. Error messages should still be the same as before.

#### Documentation:
None.

#### Reviewer Suggestions:
Anyone.