refactored the math vector